mirror of
https://github.com/pocoproject/poco.git
synced 2025-10-30 21:50:47 +01:00
#3309: optimize parsing from stream (no copying of entire JSON to memory); limit maximum depth to avoid stack overflow with malicious documents (fuzzing - #3285); code cleanup
This commit is contained in:
@@ -1921,13 +1921,6 @@ void JSONTest::testUnicode()
|
||||
}
|
||||
|
||||
|
||||
void JSONTest::testSmallBuffer()
|
||||
{
|
||||
Poco::JSON::Parser parser(new Poco::JSON::ParseHandler(), 4);
|
||||
std::string jsonStr = "{ \"x\" : \"123456789012345678901234567890123456789012345678901234567890\" }";
|
||||
parser.parse(jsonStr);
|
||||
}
|
||||
|
||||
void JSONTest::testEscape0()
|
||||
{
|
||||
Poco::JSON::Object::Ptr json = new Poco::JSON::Object();
|
||||
@@ -2261,7 +2254,6 @@ CppUnit::Test* JSONTest::suite()
|
||||
CppUnit_addTest(pSuite, JSONTest, testInvalidUnicodeJanssonFiles);
|
||||
CppUnit_addTest(pSuite, JSONTest, testTemplate);
|
||||
CppUnit_addTest(pSuite, JSONTest, testUnicode);
|
||||
CppUnit_addTest(pSuite, JSONTest, testSmallBuffer);
|
||||
CppUnit_addTest(pSuite, JSONTest, testEscape0);
|
||||
CppUnit_addTest(pSuite, JSONTest, testNonEscapeUnicode);
|
||||
CppUnit_addTest(pSuite, JSONTest, testEscapeUnicode);
|
||||
|
||||
Reference in New Issue
Block a user