-
Notifications
You must be signed in to change notification settings - Fork 164
Description
We were doing some fuzzing internally, and the fuzzer happened upon a String that gets a StringIndexOutOfBoundsException when our code calls Pattern.compile
. I managed to extract and escape the String and it's:
"i\u9b47$ \u55ed54@\u864e\ub117\ua575\uad27\uc80cv^\u9fe8\u15ab\u6e2de\u67a5X+\u2d09\u649fn%\ua91e[Y\u6d7da\u9586\ua2bb\u7170nZ\u1476\u2a9eA\u4720\u1edb.\ua0603\u1754\u4915n\u2b90"\u0fe5pC4\u117c\uc94bt\u580d\uad90\u3930\u1b92u\ub00e\u7361/\u234b\u8e5f\uaac6\u0647y\u9ca5\u0092\u3396\u1775@[q:\u3abb\p"
Adding it to the test suite (PR incoming) gives:
java.lang.StringIndexOutOfBoundsException: String index out of range: 80
at java.lang.String.codePointAt(String.java:689)
at com.google.re2j.Parser$StringIterator.pop(Parser.java:747)
at com.google.re2j.Parser.parseUnicodeClass(Parser.java:1542)
at com.google.re2j.Parser.parseClass(Parser.java:1637)
at com.google.re2j.Parser.parseInternal(Parser.java:852)
at com.google.re2j.Parser.parse(Parser.java:784)
at com.google.re2j.RE2.compileImpl(RE2.java:179)
at com.google.re2j.RE2.compile(RE2.java:152)