digital-covid-certificate-lib
Version:
A library to parse and verify Digital Covid Certificates (DCC)
18 lines (17 loc) • 606 B
TypeScript
import { Jwt } from "../Jwt";
import { IKeyStore } from "./IKeyStore";
export declare type ChKeyStoreIdentifier = string;
export declare type ChKeyStoreLoadingArgs = {
jwt: Jwt;
verifySignature: boolean;
rootCertificate?: string;
};
export declare class ChKeyStore implements IKeyStore<ChKeyStoreLoadingArgs, ChKeyStoreIdentifier> {
private keys;
constructor();
private verifyCertificateChain;
getKey(keyId: ChKeyStoreIdentifier): Promise<CryptoKey>;
loadKeys(loadingArgs: ChKeyStoreLoadingArgs): Promise<void>;
private mapToCryptoKey;
private verifyJwtSignature;
}