Documentation
¶
Overview ¶
Package jsonlimit validates untrusted JSON structure before application decoders allocate recursive values. Byte limits alone do not prevent deeply nested or highly fragmented documents from consuming disproportionate CPU and stack space.
Index ¶
Constants ¶
View Source
const ( // DefaultMaxDepth leaves room for Ridu's bounded rich-text documents and // their request envelope while rejecting pathological JSON nesting. DefaultMaxDepth = 128 // DefaultMaxTokens is deliberately well above an ordinary one-megabyte // document, but provides a stable ceiling when callers raise byte limits. DefaultMaxTokens = 100_000 )
Variables ¶
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.