masque_capsule (masque v0.7.0)
View SourceMASQUE capsule registry.
Capsules are reliable framed units carried on the CONNECT-UDP request/response stream body. The wire codec is the one from quic_h3_capsule (RFC 9297 section 3.2); this module adds a small registry identifying which capsule types MASQUE handles natively.
RFC 9297 section 3.3 requires unknown capsule types to be silently ignored by the receiver, so the default set below is intentionally empty - RFC 9298 does not define any mandatory capsules. Extension RFCs (compressed datagrams, QUIC-aware proxying) can be added here as the library grows.
Summary
Functions
Decode a single capsule from the head of Bin.
Encode a single capsule.
Returns true for capsule types MASQUE handles natively, and false for extension / unknown types (which must be silently ignored per RFC 9297 section 3.3).
Types
-type type() :: non_neg_integer().
-type value() :: binary().
Functions
-spec decode(binary()) -> {ok, {type(), value(), binary()}} | {more, non_neg_integer()} | {error, term()}.
Decode a single capsule from the head of Bin.
Encode a single capsule.
Returns true for capsule types MASQUE handles natively, and false for extension / unknown types (which must be silently ignored per RFC 9297 section 3.3).