qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH 0/4] json-streamer: Fix up code to limit nesting and size
@ 2015-10-29 12:44 Markus Armbruster
  2015-10-29 12:44 ` [Qemu-devel] [PATCH 1/4] json-streamer: Apply nesting limit more sanely Markus Armbruster
                   ` (3 more replies)
  0 siblings, 4 replies; 15+ messages in thread
From: Markus Armbruster @ 2015-10-29 12:44 UTC (permalink / raw)
  To: qemu-devel; +Cc: lcapitulino

We limit nesting depth and input size to defend against input
triggering excessive heap or stack memory use (commit 29c75dd
json-streamer: limit the maximum recursion depth and maximum token
count).  This limiting is flawed in multiple ways.  Fix it up some.

Not yet fixed: this JSON parser is an absurd memory hog; see last
patch.

Markus Armbruster (4):
  json-streamer: Apply nesting limit more sanely
  json-streamer: Don't crash when input exceeds nesting limit
  check-qjson: Add test for JSON nesting depth limit
  json-streamer: Limit number of tokens in addition to total size

 qobject/json-streamer.c |  7 ++++---
 tests/check-qjson.c     | 29 +++++++++++++++++++++++++++++
 2 files changed, 33 insertions(+), 3 deletions(-)

-- 
2.4.3

^ permalink raw reply	[flat|nested] 15+ messages in thread

end of thread, other threads:[~2015-11-23 17:21 UTC | newest]

Thread overview: 15+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-10-29 12:44 [Qemu-devel] [PATCH 0/4] json-streamer: Fix up code to limit nesting and size Markus Armbruster
2015-10-29 12:44 ` [Qemu-devel] [PATCH 1/4] json-streamer: Apply nesting limit more sanely Markus Armbruster
2015-10-29 16:22   ` Eric Blake
2015-10-29 12:44 ` [Qemu-devel] [PATCH 2/4] json-streamer: Don't crash when input exceeds nesting limit Markus Armbruster
2015-10-29 16:25   ` Eric Blake
2015-11-23 17:21     ` Markus Armbruster
2015-10-29 12:44 ` [Qemu-devel] [PATCH 3/4] check-qjson: Add test for JSON nesting depth limit Markus Armbruster
2015-10-29 16:36   ` Eric Blake
2015-10-29 18:33     ` Markus Armbruster
2015-10-29 12:44 ` [Qemu-devel] [PATCH 4/4] json-streamer: Limit number of tokens in addition to total size Markus Armbruster
2015-10-29 16:43   ` Eric Blake
2015-10-29 18:27     ` Markus Armbruster
2015-10-29 23:35       ` Eric Blake
2015-10-30  7:52         ` Markus Armbruster
2015-10-30 15:22           ` Eric Blake

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).