On Tue 26/Mar/2024 21:57:46 +0100 Matthäus Wander wrote:
Alessandro Vesely wrote on 2024-03-26 19:30:
No.  To take several years and come up with a syntax which does not cover all valid addresses is a sign of incompetence that this WG doesn't deserve, IMHO. What do others think?

Let's rather switch to /[0-9a-fA-F.:]+/.  Terse and correct.

I'm in favor of a brief and coarse regex, which is suitable for detecting obvious junk. The above proposal looks good enough to me. I wouldn't mind adding an outer bounds check, e.g.: [0-9a-fA-F.:]{3,45}


I changed that to /[0-9a-fA-F.:]{2,45}/, to allow "::", and inserted it in 
dmarc-xml-0.2-short.xsd[*].  At the same time, I added a pattern for "::1.2.3.4" in 
dmarc-xml-0.2.xsd[†].  I tested both against the list of IP that I attach.  (xmllint allows 
breaking a pattern by backslash+newline, svalidate and xmlstarlet don't.  However, publishing on 
IETF XML Registry shouldn't have line length limitations.)


If an implementer sees merit in a comprehensive syntax check, they can add one to their software.


I'm not clear what will that schema be used for, if at all.  Personally, the 
only reason why I'd prefer the long regex is because it might have some value 
by itself.  The short one is cleaner and more grokkable.  The wrong one has 
none of those qualities.


Best
Ale

--
[*] 
https://github.com/alevesely/draft-ietf-dmarc-aggregate-reporting/blob/main/dmarc-xml-0.2-short.xsd
[†] 
https://github.com/alevesely/draft-ietf-dmarc-aggregate-reporting/blob/main/dmarc-xml-0.2.xsd







2001:db8:0:0:1:0:0:1
2001:0db8:0:0:1:0:0:1
2001:db8::1:0:0:1
2001:db8::0:1:0:0:1
2001:0db8::1:0:0:1
2001:db8:0:0:1::1
2001:db8:0000:0:1::1
2001:DB8:0:0:1::1
2001:db8:aaaa:bbbb:cccc:dddd:eeee:0001
2001:db8:aaaa:bbbb:cccc:dddd:eeee:001
2001:db8:aaaa:bbbb:cccc:dddd:eeee:01
2001:db8:aaaa:bbbb:cccc:dddd:eeee:1
2001:db8:aaaa:bbbb:cccc:dddd::1
2001:db8:aaaa:bbbb:cccc:dddd:0:1
2001:db8:0:0:0::1
2001:db8:0:0::1
2001:db8:0::1
2001:db8::1
2001:db8::aaaa:0:0:1
2001:db8:0:0:aaaa::1
2001:db8:aaaa:bbbb:cccc:dddd:eeee:aaaa
2001:db8:aaaa:bbbb:cccc:dddd:eeee:AAAA
2001:db8:aaaa:bbbb:cccc:dddd:eeee:AaAa

ABCD:EF01:2345:6789:ABCD:EF01:2345:6789
2001:DB8:0:0:8:800:200C:417A
2001:DB8:0:0:8:800:200C:417A
FF01:0:0:0:0:0:0:101        
0:0:0:0:0:0:0:1             
0:0:0:0:0:0:0:0             
2001:DB8::8:800:200C:417A   
FF01::101                   
::1                         
::                          
0:0:0:0:0:0:13.1.68.3
0:0:0:0:0:FFFF:129.144.52.38
::13.1.68.3
::FFFF:129.144.52.38

::ffff:12.34.56.78
::0:ffff:12.34.56.78
::00:ffff:12.34.56.78
::000:ffff:12.34.56.78
::0000:ffff:12.34.56.78
::0:00:ffff:12.34.56.78
::00:00:ffff:12.34.56.78
::000:00:ffff:12.34.56.78
::0000:00:ffff:12.34.56.78
::0:0:0:ffff:12.34.56.78
::0:0:00:ffff:12.34.56.78
::0:00:00:ffff:12.34.56.78
::0:0:000:ffff:12.34.56.78
::0:0000:0:ffff:12.34.56.78
::00:0:0:ffff:012.034.056.078
::0:00:0:ffff:012.034.056.078
::0:0:00:ffff:012.034.056.078
::000:0:0:ffff:012.034.056.078
::0:000:0:ffff:012.034.056.078
::0:0:000:ffff:012.034.056.078
::0000:0:0000:ffff:012.034.056.078

::
::1

1::
0::
0.0.0.0
1.0.0.0
0.1.0.0
0.0.1.0
0.0.0.1

a::b
0:a:b::
0:0:a::b
_______________________________________________
dmarc mailing list
[email protected]
https://www.ietf.org/mailman/listinfo/dmarc

Reply via email to