@@ -41,21 +41,21 @@ public void testTagDecoding50339() throws Exception
41
41
}
42
42
43
43
// https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=50407
44
- public void testNumberdecoding50407 () throws Exception
44
+ public void testNumberDecoding50407 () throws Exception
45
45
{
46
46
// int, octal
47
- _testNumberdecoding50407 ("- !!int 0111-" );
48
- _testNumberdecoding50407 ("- !!int 01 11" );
49
- _testNumberdecoding50407 ("- !!int 01245zf" );
47
+ _testNumberDecoding50407 ("- !!int 0111-" );
48
+ _testNumberDecoding50407 ("- !!int 01 11" );
49
+ _testNumberDecoding50407 ("- !!int 01245zf" );
50
50
// long, octal
51
- _testNumberdecoding50407 ("- !!int 0123456789012345-" );
52
- _testNumberdecoding50407 ("- !!int 01234567 890123" );
53
- _testNumberdecoding50407 ("- !!int 0123456789012ab34" );
51
+ _testNumberDecoding50407 ("- !!int 0123456789012345-" );
52
+ _testNumberDecoding50407 ("- !!int 01234567 890123" );
53
+ _testNumberDecoding50407 ("- !!int 0123456789012ab34" );
54
54
// BigInteger, octal
55
- _testNumberdecoding50407 ("- !!int 0111 - -" );
55
+ _testNumberDecoding50407 ("- !!int 0111 - -" );
56
56
}
57
57
58
- private void _testNumberdecoding50407 (String doc ) {
58
+ private void _testNumberDecoding50407 (String doc ) {
59
59
try {
60
60
YAML_MAPPER .readTree (doc );
61
61
fail ("Should not pass" );
@@ -65,12 +65,23 @@ private void _testNumberdecoding50407(String doc) {
65
65
}
66
66
67
67
// https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=50407
68
- public void testNumberdecoding50052 () throws Exception
68
+ public void testNumberDecoding50052 () throws Exception
69
69
{
70
70
// 17-Sep-2022, tatu: Could produce an exception but for now type
71
71
// tag basically ignored, returned as empty String otken
72
72
JsonNode n = YAML_MAPPER .readTree ("!!int" );
73
73
assertEquals (JsonToken .VALUE_STRING , n .asToken ());
74
74
assertEquals ("" , n .textValue ());
75
75
}
76
+
77
+ // https://bugs.chromium.org/p/oss-fuzz/issues/detail?id=61823
78
+ public void testNumberDecoding61823 () throws Exception
79
+ {
80
+ try {
81
+ YAML_MAPPER .readTree ("!!int _ " );
82
+ fail ("Should not pass" );
83
+ } catch (JacksonException e ) {
84
+ verifyException (e , "Invalid base-" );
85
+ }
86
+ }
76
87
}
0 commit comments