fix up some iface stuff

This commit is contained in:
brent s. 2020-05-11 17:11:12 -04:00
parent b303231cfd
commit e7ca17b24a
Signed by: bts
GPG Key ID: 8C004C2F93481F6B
2 changed files with 11 additions and 2 deletions

View File

@ -4,6 +4,7 @@
attributeFormDefault="unqualified"> attributeFormDefault="unqualified">


<xs:include schemaLocation="../types/net.xsd"/> <xs:include schemaLocation="../types/net.xsd"/>
<xs:include schemaLocation="../types/linux.xsd"/>
<xs:include schemaLocation="../types/he_ipv6.xsd"/> <xs:include schemaLocation="../types/he_ipv6.xsd"/>


<xs:complexType name="e_he_ipv6_cred"> <xs:complexType name="e_he_ipv6_cred">
@ -27,6 +28,7 @@
<xs:extension base="t_net_addr_ip6"> <xs:extension base="t_net_addr_ip6">
<!-- VERY most likely "64" but we can't define a default with required. --> <!-- VERY most likely "64" but we can't define a default with required. -->
<xs:attribute name="prefix" type="t_he_ipv6_prefix" use="required"/> <xs:attribute name="prefix" type="t_he_ipv6_prefix" use="required"/>
<xs:attribute name="iface" type="t_linux_iface_name" use="required"/>
</xs:extension> </xs:extension>
</xs:simpleContent> </xs:simpleContent>
</xs:complexType> </xs:complexType>

View File

@ -83,10 +83,17 @@


<xs:simpleType name="t_linux_iface_name"> <xs:simpleType name="t_linux_iface_name">
<xs:restriction base="xs:token"> <xs:restriction base="xs:token">
<!-- https://github.com/systemd/systemd/blob/master/src/udev/udev-builtin-net_id.c. <!-- I have no idea if this will work. TODO: simplify, validate in-code. -->
I have no idea if this will work. TODO: simplify, validate in-code. --> <!--
"New" predictable iface naming.
https://github.com/systemd/systemd/blob/master/src/udev/udev-builtin-net_id.c.
-->
<xs:pattern <xs:pattern
value="((en|sl|wl|ww)(b[0-9]+|c[a-z0-9]|o[0-9]+(n.*(d.*)?)?|s[0-9]+(f.*)?([nd].*)?|x([A-Fa-f0-9]:){5}[A-Fa-f0-9]|(P.*)?p[0-9]+s[0-9]+(([fnd].*)|u.*)?))"/> value="((en|sl|wl|ww)(b[0-9]+|c[a-z0-9]|o[0-9]+(n.*(d.*)?)?|s[0-9]+(f.*)?([nd].*)?|x([A-Fa-f0-9]:){5}[A-Fa-f0-9]|(P.*)?p[0-9]+s[0-9]+(([fnd].*)|u.*)?))"/>
<!--
Legacy naming.
-->
<xs:pattern value="(eth|wl(an)?)[0-9]*"/>
<xs:whiteSpace value="collapse"/> <xs:whiteSpace value="collapse"/>
</xs:restriction> </xs:restriction>
</xs:simpleType> </xs:simpleType>