Skip to content

Latest commit

 

History

History
89 lines (49 loc) · 2.34 KB

Signature.md

File metadata and controls

89 lines (49 loc) · 2.34 KB

Interface: Signature

Support from the community to continue maintaining and improving this module is welcome. If you find the module useful, please consider supporting the project by becoming a sponsor.

Methods

addSignature()

addSignature(...args): Signature

A shorthand for calling addSignature() on the enclosing GeneralSign instance

Parameters

Parameter Type
...args [Uint8Array | KeyLike | JWK, SignOptions]

Returns

Signature


done()

done(): GeneralSign

Returns the enclosing GeneralSign

Returns

GeneralSign


setProtectedHeader()

setProtectedHeader(protectedHeader): Signature

Sets the JWS Protected Header on the Signature object.

Parameters

Parameter Type Description
protectedHeader JWSHeaderParameters JWS Protected Header.

Returns

Signature


setUnprotectedHeader()

setUnprotectedHeader(unprotectedHeader): Signature

Sets the JWS Unprotected Header on the Signature object.

Parameters

Parameter Type Description
unprotectedHeader JWSHeaderParameters JWS Unprotected Header.

Returns

Signature


sign()

sign(...args): Promise<GeneralJWS>

A shorthand for calling encrypt() on the enclosing GeneralSign instance

Parameters

Parameter Type
...args []

Returns

Promise<GeneralJWS>