diff options
-rw-r--r-- | lib/OpenPGP.hs | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/lib/OpenPGP.hs b/lib/OpenPGP.hs index e5b70cd..51e1c1f 100644 --- a/lib/OpenPGP.hs +++ b/lib/OpenPGP.hs | |||
@@ -25,7 +25,8 @@ data Packet = | |||
25 | hashed_subpackets::[SignatureSubpacket], | 25 | hashed_subpackets::[SignatureSubpacket], |
26 | unhashed_subpackets::[SignatureSubpacket], | 26 | unhashed_subpackets::[SignatureSubpacket], |
27 | hash_head::Word16, | 27 | hash_head::Word16, |
28 | signature::MPI | 28 | signature::MPI, |
29 | trailer::LZ.ByteString | ||
29 | } | | 30 | } | |
30 | OnePassSignaturePacket { | 31 | OnePassSignaturePacket { |
31 | version::Word8, | 32 | version::Word8, |
@@ -152,7 +153,8 @@ parse_packet 2 = do | |||
152 | hashed_subpackets = hashed, | 153 | hashed_subpackets = hashed, |
153 | unhashed_subpackets = unhashed, | 154 | unhashed_subpackets = unhashed, |
154 | hash_head = hash_head, | 155 | hash_head = hash_head, |
155 | signature = signature | 156 | signature = signature, |
157 | trailer = LZ.concat [encode version, encode signature_type, encode key_algorithm, encode hash_algorithm, encode (fromIntegral hashed_size :: Word16), hashed_data, LZ.pack [4, 0xff], encode ((6 + (fromIntegral hashed_size)) :: Word32)] | ||
156 | }) | 158 | }) |
157 | -- OnePassSignaturePacket, http://tools.ietf.org/html/rfc4880#section-5.4 | 159 | -- OnePassSignaturePacket, http://tools.ietf.org/html/rfc4880#section-5.4 |
158 | parse_packet 4 = do | 160 | parse_packet 4 = do |