Expand description
OpenPGP helper module using rPGP facilities.
Structsยง
- KeyPair
- A PGP keypair.
Constantsยง
- HASH_
ALGORITHM ๐ - Preferred cryptographic hash.
- HEADER_
SETUPCODE ๐ - SYMMETRIC_
KEY_ ๐ALGORITHM - Preferred symmetric encryption algorithm.
Functionsยง
- check_
symmetric_ ๐encryption - Returns Ok(()) if we want to try symmetrically decrypting the message, and Err with a reason if symmetric decryption should not be tried.
- create_
keypair ๐ - Create a new key pair.
- decrypt
- Decrypts the message:
- pk_
calc_ signature - Produces a detached signature for
plaintext usingprivate_key_for_signing. - pk_
encrypt - Encrypts
plaintextย usingpublic_keys_for_encryptionand signs it usingprivate_key_for_signing. - pk_
validate - Validates detached signature.
- select_
pk_ ๐for_ encryption - Selects a subkey of the public key to use for encryption.
- split_
armored_ data - Split data from PGP Armored Data as defined in https://tools.ietf.org/html/rfc4880#section-6.2.
- symm_
decrypt - Symmetric decryption.
- symm_
encrypt_ autocrypt_ setup - Symmetric encryption for the autocrypt setup message (ASM).
- symm_
encrypt_ message - Symmetrically encrypt the message.
This is used for broadcast channels and for version 2 of the Securejoin protocol.
shared secretis the secret that will be used for symmetric encryption. - valid_
signature_ fingerprints - Returns fingerprints
of all keys from the
public_keys_for_validationkeyring that have valid signatures there.