Signature generated by signing data with Private Key.

### Hierarchy

- Signature

## Index

### Constructors

- constructor

### Properties

- algorithm
- publicKeyId
- value

### Methods

- serializeHex
- serializeJWT
- serializePgp
- deserializeHex
- deserializeJWT
- deserializePgp

## Constructors

### constructor

- new Signature(algorithm: SignatureScheme, value: string, publicKeyId?: undefined | string): Signature

- - Defined in crypto/Signature.ts:73

  #### Parameters

  - ##### algorithm: SignatureScheme

  - ##### value: string

  - ##### Optional publicKeyId: undefined | string

  #### Returns Signature

## Properties

### algorithm

algorithm: SignatureScheme

- Defined in crypto/Signature.ts:66

### Optional publicKeyId

publicKeyId: undefined | string

- Defined in crypto/Signature.ts:73

Public key Id used for create this signature.

### value

value: string

- Defined in crypto/Signature.ts:67

## Methods

### serializeHex

- serializeHex(): string

- - Defined in crypto/Signature.ts:85

  Serializes signature to Hex representation. For transfer to java backend and verify it.

  #### Returns string

### serializeJWT

- serializeJWT(): string

- - Defined in crypto/Signature.ts:111

  Serializes signature to base64url format.

  #### Returns string

### serializePgp

- serializePgp(keyId?: undefined | string): PgpSignature

- - Defined in crypto/Signature.ts:98

  Serializes signature to PGP representation with optional PublicKeyId.

  #### Parameters

  - ##### Optional keyId: undefined | string

    Whole Public Key Id in the form <ONTID>#keys-<id>

  #### Returns PgpSignature

### Static deserializeHex

- deserializeHex(data: string): Signature

- - Defined in crypto/Signature.ts:54

  Deserializes hex representation to Signature

  #### Parameters

  - ##### data: string

    hex string

  #### Returns Signature

### Static deserializeJWT

- deserializeJWT(encoded: string, algorithm: SignatureScheme, publicKeyId: string): Signature

- - Defined in crypto/Signature.ts:27

  #### Parameters

  - ##### encoded: string

  - ##### algorithm: SignatureScheme

  - ##### publicKeyId: string

  #### Returns Signature

### Static deserializePgp

- deserializePgp(pgpSignature: PgpSignature): Signature

- - Defined in crypto/Signature.ts:41

  Deserializes PgpSignature to Signature.

  #### Parameters

  - ##### pgpSignature: PgpSignature

    PgpSignature

  #### Returns Signature

Generated using TypeDoc