@hellocoop/web-identity
Version:
Functions for generating and verifying JWT tokens used in the Verified Email Autocomplete protocol
21 lines • 1.66 kB
TypeScript
/**
* @fileoverview Web Identity Package - JWT token generation and verification for Verified Email Autocomplete
*
* This package provides TypeScript functions for generating and verifying JWT tokens used in the
* Verified Email Autocomplete protocol as defined in the web-identity specification.
*
* @author Hello Identity Co-op
* @version 1.0.0
* @license MIT
*/
export { generateRequestToken, verifyRequestToken, } from './tokens/request-token.js';
export { generateIssuanceToken, verifyIssuanceToken, } from './tokens/issuance-token.js';
export { generatePresentationToken, verifyPresentationToken, } from './tokens/presentation-token.js';
export type { KeyResolver, RequestTokenPayload, IssuanceTokenPayload, PresentationTokenPayload, TokenGenerationOptions, RequestTokenHeader, IssuanceTokenHeader, KeyBindingHeader, } from './types.js';
export { WebIdentityError, MissingClaimError, InvalidSignatureError, TimeValidationError, TokenFormatError, JWKValidationError, EmailValidationError, DNSDiscoveryError, JWKSFetchError, } from './errors.js';
export { validateJWK, extractPublicKeyParameters, calculateSHA256Hash, isValidEmail, } from './utils/crypto.js';
export { getCurrentTimestamp, validateIatClaim, TIME_VALIDATION_WINDOW, } from './utils/time.js';
export { parseJWT, validateRequiredClaims, validateEmailClaim, validateEmailVerifiedClaim, parsePresentationToken, } from './utils/validation.js';
export { discoverIssuer, fetchWebIdentityMetadata, fetchJWKS, clearCaches, } from './utils/dns-discovery.js';
export type { WebIdentityMetadata, JWKSResponse, RequestOptions, } from './utils/dns-discovery.js';
//# sourceMappingURL=index.d.ts.map