Skip to main content
Version: 1.4

Interface: IJwsVerifier

identity_wasm.IJwsVerifier

Interface for cryptographically verifying a JWS signature.

Implementers are expected to provide a procedure for step 8 of RFC 7515 section 5.2 for the JWS signature algorithms they want to support.

Table of contents

Properties

Properties

verify

verify: (alg: JwsAlgorithm, signingInput: Uint8Array, decodedSignature: Uint8Array, publicKey: Jwk) => void

Type declaration

▸ (alg, signingInput, decodedSignature, publicKey): void

Validate the decodedSignature against the signingInput in the manner defined by alg using the publicKey.

See RFC 7515: section 5.2 part 8. and RFC 7797 section 3.

Failures

Upon verification failure an error must be thrown.

Parameters
NameType
algJwsAlgorithm
signingInputUint8Array
decodedSignatureUint8Array
publicKeyJwk
Returns

void