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
Describe the bug
When an IPv4 address contains a leading 0, many tools treat it as octal representation (e.g. https://superuser.com/a/857618). However, when extracting IP addresses using CyberChef, some octal IP addresses are extracted (e.g. 011.012.013.014), but some are not (e.g. 0377.0377.0377.0377).
To Reproduce
Steps to reproduce the behaviour or a link to the recipe / input used to cause the bug:
Addresses bug report #2008
Added explicit support for octal IP addresses.
Changed approach to IPv4 regex to be string manipulation generated.
Added some unit tests for IP address parsing - probably not full coverage.
Added lookahead and lookbehind tricks to resolve warned issue that 1.2.3.256 would still be extracted as 1.2.3.25. Now only accepts valid IP addresses. Warning replaced with clause about infinite length dotted decimal forms.
Describe the bug
When an IPv4 address contains a leading 0, many tools treat it as octal representation (e.g. https://superuser.com/a/857618). However, when extracting IP addresses using CyberChef, some octal IP addresses are extracted (e.g.
011.012.013.014
), but some are not (e.g.0377.0377.0377.0377
).To Reproduce
Steps to reproduce the behaviour or a link to the recipe / input used to cause the bug:
011.012.013.014
appears in the Output, but not0377.0377.0377.0377
.Expected behaviour
Either both
011.012.013.014
and0377.0377.0377.0377
appear in the Output, or neither.Screenshots

Desktop (if relevant, please complete the following information):
Additional context
The root cause is likely this regular expression:
CyberChef/src/core/operations/ExtractIPAddresses.mjs
Line 68 in d3357d2
The text was updated successfully, but these errors were encountered: