FromBerOptions
Encoding, input ownership, and resource limits for ASN.1 decoding.
Properties
Section titled “Properties”copyInput?
Section titled “copyInput?”
optionalcopyInput?:boolean
Copy the input bytes before decoding. Defaults to true for fromBER/fromDER and false for verifySchema in both BER and DER.
encodingRules?
Section titled “encodingRules?”
optionalencodingRules?:EncodingRules
Encoding rules to validate.
Default Value
Section titled “Default Value”"BER"maxContentLength?
Section titled “maxContentLength?”
optionalmaxContentLength?:number
Maximum content length of one element in bytes.
Default Value
Section titled “Default Value”16777216maxDepth?
Section titled “maxDepth?”
optionalmaxDepth?:number
Maximum nesting depth, with the root at depth zero.
Default Value
Section titled “Default Value”100maxNodes?
Section titled “maxNodes?”
optionalmaxNodes?:number
Maximum number of decoded nodes.
Default Value
Section titled “Default Value”10000parseEmbedded?
Section titled “parseEmbedded?”
optionalparseEmbedded?:boolean
Try decoding embedded OCTET STRING and BIT STRING content. Defaults to true for BER and false for DER.
requireFullInput?
Section titled “requireFullInput?”
optionalrequireFullInput?:boolean
Require exactly one input element. Always true for DER; explicitly setting false with DER throws TypeError.
Default Value
Section titled “Default Value”false