Expand description
§pretty-good overview
pretty-good is an implementation of RFC4880 (OpenPGP Message Format), capable of reading OpenPGP packets into usable Rust structures, and creating and writing OpenPGP packets programmatically in Rust.
The primary structure of pretty-good is the Packet enum, which contains a variant for each
possible type of OpenPGP packet. Each variant that has been implemented contains a single
field, which is a structure representing the contents of that packet type. For example,
Packet::Signature contains a SignaturePacket, which can be used to read and write OpenPGP
signatures.
Packets are read by calling Packet::from_bytes, and can be serialized by calling
Packet::to_bytes.
Structs§
- DsaPrivate
Key - DsaPublic
Key - Elgamal
Private Key - Elgamal
Public Key - Key
- Literal
Packet - A Literal data packet as specified in RFC4880 §5.9.
- RsaPrivate
Key - RsaPublic
Key - Signature
Packet - The contents of a PGP signature packet.
Enums§
- Algorithm
Error - Error type for
PublicKeyAlgorithmandHashAlgorithm-related operations. - Compressed
Data Packet - Compression
Error - Hash
Algorithm - Type for hash algorithms supported by OpenPGP.
- KeyEncryption
Method - KeyError
- KeyMaterial
- Literal
Data - The contents of a
LiteralPacket. - Literal
Error - Error type for
LiteralPacket-level errors. - Packet
- An OpenPGP packet.
- Packet
Error - Error type for
Packet-level errors. - Public
KeyAlgorithm - Type for public key algorithms supported by OpenPGP.
- S2kError
- Signature
- Actual multiprecision integer signature contents.
- Signature
Error - Error type for
SignaturePacket-level errors. - Signature
Type - The type of content a signature covers. See RFC4880 §5.2.1.
- String
ToKey - Subpacket
- Type for
SignaturePacketsubpackets. See RFC4880 §5.2.3.1. - Symmetric
KeyAlgorithm - Type for symmetric key algorithms supported by OpenPGP.