Skip to content

UnwrapDER

const unwrapDER: (derEncoded, oid) => Uint8Array

Defined in: packages/agent/lib/esm/der.d.ts:33

Extracts a payload from the given derEncoded data, and checks that it was tagged with the given oid.

derEncoded = SEQUENCE(oid, BITSTRING(payload))

Uint8Array

The DER encoded and tagged data

Uint8Array

The DER encoded (and SEQUENCE wrapped!) expected OID

Uint8Array

The unwrapped payload