You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
inet.ipaddr.AddressStringException: 1.2.0.1 IP Address error: segment value starts with zero
at inet.ipaddr.format.validate.Validator.validateAddress(scratch_198:622)
at inet.ipaddr.format.validate.Validator.validateIPAddress(scratch_198:166)
at inet.ipaddr.format.validate.Validator.validateAddress(scratch_198:134)
at inet.ipaddr.IPAddressString.validate(scratch_198:453)
at inet.ipaddr.IPAddressString.validate(scratch_198:402)
at inet.ipaddr.IPAddressString.toAddress(scratch_198:765)
at #worksheet#.get$$instance$$res0(scratch_198:46)
at #worksheet#.#worksheet#(scratch_198:70)
I believe that there is a problem with allowLeadingZeros option because when it is set to true this example no longer throws. However, this has a side-effect of allowing addresses like 01.02.0.01 which I do not want.
The text was updated successfully, but these errors were encountered:
Yes, your test case confirms a bug in the leading zeros validation for IPv4, it was introduced with this commit: 646220c
and so the bug is in master, v5 branch v5.0.0 and up, v4 branch v4.2.0 and up.
I expected this to work but it throws
I believe that there is a problem with
allowLeadingZeros
option because when it is set totrue
this example no longer throws. However, this has a side-effect of allowing addresses like01.02.0.01
which I do not want.The text was updated successfully, but these errors were encountered: