diff options
Diffstat (limited to 'scripts/up-down-tighter-schema.pl')
-rw-r--r-- | scripts/up-down-tighter-schema.pl | 18 |
1 files changed, 12 insertions, 6 deletions
diff --git a/scripts/up-down-tighter-schema.pl b/scripts/up-down-tighter-schema.pl index a243b1f8..e31a62d9 100644 --- a/scripts/up-down-tighter-schema.pl +++ b/scripts/up-down-tighter-schema.pl @@ -14,11 +14,17 @@ my $as_set = '[0-9]+(,[0-9]+)?'; -my $ipv4 = '([0-9]+\.){3}[0-9]+'; -my $ipv4p = "${ipv4}/[0-9]+"; +my $octet = '[0-9]|1[0-9]|2[0-4]|25[0-5]'; +my $ipv4 = "(${octet}\.){3}${octet}"; +my $ipv4p = "${ipv4}/([0-9]|[12][0-9]|3[0-2])"; my $ipv4r = "${ipv4}-${ipv4}"; my $ipv4_set = "${ipv4p}|${ipv4r}"; +my $nibble = '0|[1-9a-fA-F][0-9a-fA-F]{0,3}'; +my $ipv6 = "::|(${nibble}:){0,7}(:|${nibble})"; +my $ipv6p = "${ipv6}/([0-9]|[1-9][0-9]|1[0-1][0-9]|12[0-8])"; +my $ipv6r = "${ipv6}-${ipv6}"; +my $ipv6_set = "${ipv6r}|${ipv6p}"; my $rnc = qq{# \$Id\$ # Automatically generated from $0 @@ -51,7 +57,7 @@ my $rnc = qq{# \$Id\$ attribute cert_ski { xsd:token { maxLength="1024" } }, attribute resource_set_as { xsd:string { maxLength="512000" pattern="${as_set}" } }, attribute resource_set_ipv4 { xsd:string { maxLength="512000" pattern="${ipv4_set}" } }, - attribute resource_set_ipv6 { xsd:string { maxLength="512000" } }, + attribute resource_set_ipv6 { xsd:string { maxLength="512000" pattern="${ipv6_set}" } }, attribute suggested_sia_head { xsd:string { maxLength="1024" } }?, element certificate { attribute cert_url { xsd:anyURI { maxLength="1024" } }, @@ -60,10 +66,10 @@ my $rnc = qq{# \$Id\$ attribute cert_serial { xsd:positiveInteger }, attribute resource_set_as { xsd:string { maxLength="512000" pattern="${as_set}" } }, attribute resource_set_ipv4 { xsd:string { maxLength="512000" pattern="${ipv4_set}" } }, - attribute resource_set_ipv6 { xsd:string { maxLength="512000" } }, + attribute resource_set_ipv6 { xsd:string { maxLength="512000" pattern="${ipv6_set}" } }, attribute req_resource_set_as { xsd:string { maxLength="512000" pattern="${as_set}" } }?, attribute req_resource_set_ipv4 { xsd:string { maxLength="512000" pattern="${ipv4_set}" } }?, - attribute req_resource_set_ipv6 { xsd:string { maxLength="512000" } }?, + attribute req_resource_set_ipv6 { xsd:string { maxLength="512000" pattern="${ipv6_set}" } }?, attribute status { "undersize" | "match" | "oversize" }, xsd:base64Binary { maxLength="512000" } }*, @@ -74,7 +80,7 @@ my $rnc = qq{# \$Id\$ attribute class_name { xsd:token { maxLength="1024" } }, attribute req_resource_set_as { xsd:string { maxLength="512000" pattern="${as_set}" } }?, attribute req_resource_set_ipv4 { xsd:string { maxLength="512000" pattern="${ipv4_set}" } }?, - attribute req_resource_set_ipv6 { xsd:string { maxLength="512000" } }?, + attribute req_resource_set_ipv6 { xsd:string { maxLength="512000" pattern="${ipv6_set}" } }?, xsd:base64Binary { maxLength="512000" } } issue_response = class |