identity/der library
Properties
- canisterCOSEDer → Uint8List
-
final
- oidEd25519 → Uint8List
-
A DER encoded
SEQUENCE(OID)
for the Ed25519 algorithm.final - oidP256 → Uint8List
-
final
- oidSecp256k1 → Uint8List
-
final
- oisCOSEDer → Uint8List
-
A DER encoded
SEQUENCE(OID)
for DER-encoded-COSE.final
Functions
-
bufEquals(
ByteBuffer b1, ByteBuffer b2) → bool -
bytesUnwrapDer(
Uint8List derEncoded, Uint8List oid) → Uint8List -
Extracts a payload from the given
derEncoded
data, and checks that it was tagged with the givenoid
. -
bytesUnwrapDerSignature(
Uint8List derEncoded) → Uint8List - ECDSA DER Signature 0x30|b1|0x02|b2|r|0x02|b3|s b1 = Length of remaining data b2 = Length of r b3 = Length of s
-
bytesWrapDer(
Uint8List payload, Uint8List oid) → Uint8List -
Wraps the given
payload
in a DER encoding tagged with the given encodedoid
like so:SEQUENCE(oid, BITSTRING(payload))
-
bytesWrapDerSignature(
Uint8List rawSignature) → Uint8List -
decodeLenBytes(
Uint8List buf, int offset) → int -
encodeLen(
Uint8List buf, int offset, int len) → int -
encodeLenBytes(
int len) → int -
isDerPublicKey(
Uint8List pub, Uint8List oid) → bool -
isDerSignature(
Uint8List sig) → bool