Am 2024-10-08 um 11:43 schrieb Alessandro Vesely:
Let me repeat the point. Currently there is a dozen alternative regular
expressions (that is, OR joined) which allow various styles of IP
addresses, and we've been wondering whether 01.02.03.04 is valid (rather
than 1.2.3.4) and similar trivialities.
However clever, then, those expressions will never exclude RFC 1918 and
other addresses which are not valid or not useful in an aggregate
report. And maybe there are still bugs that exclude valid ones. So,
why don't we replace all that toilsome stuff with an easy one-liner:
<xs:pattern value="[0-9a-fA-F.:]{2,45}"/>
(string of two to forty five hexadecimal numbers, dots and columns)?
We have seen a few attempts at formulating precise regexps for syntax
checking IP addresses, which turned out to be faulty in rare corner
cases. Aiming for perfection has not worked here, so yes, let's replace
it with Ale's simple and lax suggestion.
I also wouldn't mind dropping the pattern altogether and just allowing
any xs:string in the schema definition, with an informative comment that
this field is expected to be an IP address. Implementations are free to
implement a strict input validation if they need it.
Regards,
Matt
_______________________________________________
dmarc mailing list -- [email protected]
To unsubscribe send an email to [email protected]