Files
jose/docs/interfaces/jws_general_sign.Signature.md
2023-04-12 18:54:17 +02:00

2.5 KiB

Interface: Signature

💗 Help the project

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.


Table of contents

Methods

Methods

addSignature

â–¸ addSignature(...args): Signature

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

Parameters

Name Type
...args [key: Uint8Array | KeyLike, options?: 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

Name Type Description
protectedHeader JWSHeaderParameters JWS Protected Header.

Returns

Signature


setUnprotectedHeader

â–¸ setUnprotectedHeader(unprotectedHeader): Signature

Sets the JWS Unprotected Header on the Signature object.

Parameters

Name 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

Name Type
...args []

Returns

Promise<GeneralJWS>