Expand description
ASN.1 DER typed input (ADR-023 amended by ADR-060).
DER is the canonical form by construction (ITU-T X.690 §10): a
well-formed DER byte sequence is its own canonical representative, so
the ψ₉ canonicalizer is the identity on it. The realization
therefore validates the input is valid DER at the host boundary and
flows the input bytes themselves through the pipeline as a
zero-copy [TermValue::Borrowed] carrier — no transformation, no
buffer, no width / element-count ceiling. The only retained bound is
MAX_ASN1_DEPTH, a native-stack-overflow guard on the recursive
TLV validator.
Asn1Value (the owned DER builder, alloc-gated) constructs
canonical DER programmatically (boolean, integer, sequence,
set, …) for reference and testing; Asn1Carrier is the borrowed
model-input handle the pipeline binds.
§Supported universal-tag cases
Boolean, Integer, BitString, OctetString, Null,
ObjectIdentifier, Utf8String, PrintableString, IA5String,
UTCTime, GeneralizedTime, Sequence, Set.
Structs§
- Asn1
Carrier - Borrowed validated-DER input handle (ADR-060 borrowed carrier). DER is
canonical, so the handle borrows the input bytes directly and
as_binding_valuereturns them as a zero-copyBorrowedcarrier. - Asn1
Value - Owned DER value + builder. Constructs canonical X.690 DER
programmatically for reference and testing.
alloc-gated — the pipeline binds the borrowedAsn1Carrierhandle, which needs no allocator. There is no width or element-count ceiling.
Functions§
- canonicalize
- Canonical-bytes accessor — DER is the canonical form per X.690 §10, so canonicalization is the identity on validated input.
- validate_
der - Validate that
rawis a single well-formed DER value per X.690 §§ 8 / 10 / 11 (not merely valid BER — long-form lengths below the short-form threshold and indefinite lengths are rejected).