hOpenPGP-3.0.1.1: native Haskell implementation of OpenPGP (RFC9580)
Safe HaskellNone
LanguageHaskell2010

Codec.Encryption.OpenPGP.Serialize

Synopsis

Serialization functions

putPktEither :: Pkt -> Either String Put Source #

Serialize a packet with explicit validation and error handling. Validates constraints before calling putPkt to ensure errors are caught early.

Utilities

parsePkts :: ByteString -> [Pkt] Source #

Parse the packets from a ByteString, with no error reporting

parsePktsEither :: ByteString -> Either PktParseError [Pkt] Source #

Parse packets from a ByteString and report the first parse failure.

parsePktsWithWireRep :: WireRepRef -> ByteString -> [PktWithWireRep] Source #

Parse packets from a source bytestream, preserving packet provenance.

Orphan instances

Binary CompressionAlgorithm Source # 
Instance details

Binary HashAlgorithm Source # 
Instance details

Binary MPI Source # 
Instance details

Methods

put :: MPI -> Put Source #

get :: Get MPI Source #

putList :: [MPI] -> Put Source #

Binary PubKeyAlgorithm Source # 
Instance details

Binary S2K Source # 
Instance details

Methods

put :: S2K -> Put Source #

get :: Get S2K Source #

putList :: [S2K] -> Put Source #

Binary SigSubPacket Source # 
Instance details

Binary SigType Source # 
Instance details

Binary SignaturePayload Source # 
Instance details

Binary SymmetricAlgorithm Source # 
Instance details

Binary UserAttrSubPacket Source # 
Instance details

Binary SomePKPayload Source # 
Instance details

Binary CompressedData Source # 
Instance details

Binary LiteralData Source # 
Instance details

Binary Marker Source # 
Instance details

Binary ModificationDetectionCode Source # 
Instance details

Binary OtherPacket Source # 
Instance details

Binary PublicKey Source # 
Instance details

Binary PublicSubkey Source # 
Instance details

Binary SecretKey Source # 
Instance details

Binary SecretSubkey Source # 
Instance details

Binary Signature Source # 
Instance details

Binary SymEncData Source # 
Instance details

Binary SymEncIntegrityProtectedData Source # 
Instance details

Binary Trust Source # 
Instance details

Binary UserAttribute Source # 
Instance details

Binary UserId Source # 
Instance details

Binary Pkt Source # 
Instance details

Methods

put :: Pkt -> Put Source #

get :: Get Pkt Source #

putList :: [Pkt] -> Put Source #

Binary TKUnknown Source # 
Instance details

Binary a => Binary (Block a) Source # 
Instance details

Methods

put :: Block a -> Put Source #

get :: Get (Block a) Source #

putList :: [Block a] -> Put Source #

Binary (OnePassSignature 'OPSV3) Source # 
Instance details

Binary (OnePassSignature 'OPSV6) Source # 
Instance details

Binary (PKESK 'PKESKV3) Source # 
Instance details

Binary (PKESK 'PKESKV6) Source # 
Instance details

Binary (SKESK 'SKESKV4) Source # 
Instance details

Binary (SKESK 'SKESKV6) Source # 
Instance details