@ldclabs/cose-ts
Version:
Implemented Keys, Algorithms (RFC9053), COSE (RFC9052) and CWT (RFC8392) in TypeScript.
13 lines (12 loc) • 541 B
TypeScript
import { Header } from './header';
import { Key, type MACer } from './key';
export declare class Mac0Message {
payload: Uint8Array;
protected: Header | null;
unprotected: Header | null;
private static macBytes;
static fromBytes(key: Key & MACer, coseData: Uint8Array, externalData?: Uint8Array): Mac0Message;
static withTag(coseData: Uint8Array): Uint8Array;
constructor(payload: Uint8Array, protectedHeader?: Header, unprotected?: Header);
toBytes(key: Key & MACer, externalData?: Uint8Array): Uint8Array;
}