Extends
Members
body :Object.<string, string>|string
Key-value pairs given for the message.
Type:
- Object.<string, string> |
string
- Inherited From
head :module:rise~RiseMessage~Head
Default message headers, plus any custom ones supplied.
- Inherited From
Methods
decrypt(privateKey) → {module:rise~RiseMessage}
Decrypts the message using the supplied private key.
Parameters:
Name | Type | Description |
---|---|---|
privateKey | Uint8Array | | Private key to use. |
- Inherited From
Returns:
- Type:
- module:rise~RiseMessage
encrypt(publicKey) → {module:rise~EncryptedRiseMessage}
Encrypts the message state for the public key provided.
Parameters:
Name | Type | Description |
---|---|---|
publicKey | Uint8Array | | Recipient public key. |
- Inherited From
Returns:
sign(privateKey) → {module:rise~SignedRiseMessage}
Signs the message state using the private key provided.
Parameters:
Name | Type | Description |
---|---|---|
privateKey | Uint8Array | | Identity to use for signature. |
- Inherited From
Returns:
toBuffer() → {buffer}
Serializes the message to wire format.
- Inherited From
Returns:
- Type:
- buffer
unwrap() → {Object.<string, (string|module:rise~RiseMessage|module:rise~EncryptedRiseMessage|module:rise~SignedRiseMessage|string)>}
Returns only the body of this message.
- Inherited From
Returns:
- Type:
- Object.<string, (string|module:rise~RiseMessage|module:rise~EncryptedRiseMessage|module:rise~SignedRiseMessage|string)>
validate() → {boolean}
Ensures the solution header is valid.
- Inherited From
Returns:
- Type:
- boolean
verify() → {boolean}
Ensures that the digita signature is valid.
Returns:
- Type:
- boolean