rpm  4.13.90
rpmpgp.h
Go to the documentation of this file.
1 #ifndef H_RPMPGP
2 #define H_RPMPGP
3 
13 #include <string.h>
14 #include <stdio.h>
15 #include <stdlib.h>
16 #include <rpm/rpmtypes.h>
17 #include <rpm/rpmstring.h>
18 
19 #ifdef __cplusplus
20 extern "C" {
21 #endif
22 
25 typedef struct DIGEST_CTX_s * DIGEST_CTX;
26 typedef struct rpmDigestBundle_s * rpmDigestBundle;
27 
30 typedef struct pgpDig_s * pgpDig;
31 
34 typedef struct pgpDigParams_s * pgpDigParams;
35 
36 typedef uint8_t pgpKeyID_t[8];
37 typedef uint8_t pgpTime_t[4];
38 
46 typedef enum pgpTag_e {
59  PGPTAG_TRUST = 12,
65  PGPTAG_MDC = 19,
70 } pgpTag;
71 
106 typedef struct pgpPktPubkey_s {
107  uint8_t version;
108  pgpKeyID_t keyid;
109  uint8_t algo;
110 } pgpPktPubkey;
111 
112 
119 typedef enum pgpSigType_e {
137 } pgpSigType;
138 
162 typedef enum pgpPubkeyAlgo_e {
172 } pgpPubkeyAlgo;
173 
198 typedef enum pgpSymkeyAlgo_e {
211 } pgpSymkeyAlgo;
212 
228 typedef enum pgpCompressAlgo_e {
234 
255 typedef enum pgpHashAlgo_e {
266 } pgpHashAlgo;
267 
289 typedef struct pgpPktSigV3_s {
290  uint8_t version;
291  uint8_t hashlen;
292  uint8_t sigtype;
293  pgpTime_t time;
294  pgpKeyID_t signid;
295  uint8_t pubkey_algo;
296  uint8_t hash_algo;
297  uint8_t signhash16[2];
298 } * pgpPktSigV3;
299 
321 typedef struct pgpPktSigV4_s {
322  uint8_t version;
323  uint8_t sigtype;
324  uint8_t pubkey_algo;
325  uint8_t hash_algo;
326  uint8_t hashlen[2];
327 } * pgpPktSigV4;
328 
395 typedef enum pgpSubType_e {
434 } pgpSubType;
435 
456 typedef union pgpPktSig_u {
457  struct pgpPktSigV3_s v3;
458  struct pgpPktSigV4_s v4;
459 } * pgpPktSig;
460 
489 typedef struct pgpPktSymkey_s {
490  uint8_t version;
491  uint8_t symkey_algo;
492  uint8_t s2k[1];
493 } pgpPktSymkey;
494 
524 typedef struct pgpPktOnepass_s {
525  uint8_t version;
526  uint8_t sigtype;
527  uint8_t hash_algo;
528  uint8_t pubkey_algo;
529  pgpKeyID_t signid;
530  uint8_t nested;
531 } * pgpPktOnepass;
532 
605 typedef struct pgpPktKeyV3_s {
606  uint8_t version;
607  pgpTime_t time;
608  uint8_t valid[2];
609  uint8_t pubkey_algo;
610 } * pgpPktKeyV3;
611 
643 typedef struct pgpPktKeyV4_s {
644  uint8_t version;
645  pgpTime_t time;
646  uint8_t pubkey_algo;
647 } * pgpPktKeyV4;
648 
713 typedef union pgpPktKey_u {
714  struct pgpPktKeyV3_s v3;
715  struct pgpPktKeyV4_s v4;
716 } pgpPktKey;
717 
718 /* \ingroup rpmpgp
719  * 5.6. Compressed Data Packet (Tag 8)
720  *
721  * The Compressed Data packet contains compressed data. Typically, this
722  * packet is found as the contents of an encrypted packet, or following
723  * a Signature or One-Pass Signature packet, and contains literal data
724  * packets.
725  *
726  * The body of this packet consists of:
727  * - One octet that gives the algorithm used to compress the packet.
728  * - The remainder of the packet is compressed data.
729  *
730  * A Compressed Data Packet's body contains an block that compresses
731  * some set of packets. See section "Packet Composition" for details on
732  * how messages are formed.
733  *
734  * ZIP-compressed packets are compressed with raw RFC 1951 DEFLATE
735  * blocks. Note that PGP V2.6 uses 13 bits of compression. If an
736  * implementation uses more bits of compression, PGP V2.6 cannot
737  * decompress it.
738  *
739  * ZLIB-compressed packets are compressed with RFC 1950 ZLIB-style
740  * blocks.
741  */
742 typedef struct pgpPktCdata_s {
743  uint8_t compressalgo;
744  uint8_t data[1];
745 } pgpPktCdata;
746 
747 /* \ingroup rpmpgp
748  * 5.7. Symmetrically Encrypted Data Packet (Tag 9)
749  *
750  * The Symmetrically Encrypted Data packet contains data encrypted with
751  * a symmetric-key algorithm. When it has been decrypted, it will
752  * typically contain other packets (often literal data packets or
753  * compressed data packets).
754  *
755  * The body of this packet consists of:
756  * - Encrypted data, the output of the selected symmetric-key cipher
757  * operating in PGP's variant of Cipher Feedback (CFB) mode.
758  *
759  * The symmetric cipher used may be specified in an Public-Key or
760  * Symmetric-Key Encrypted Session Key packet that precedes the
761  * Symmetrically Encrypted Data Packet. In that case, the cipher
762  * algorithm octet is prefixed to the session key before it is
763  * encrypted. If no packets of these types precede the encrypted data,
764  * the IDEA algorithm is used with the session key calculated as the MD5
765  * hash of the passphrase.
766  *
767  * The data is encrypted in CFB mode, with a CFB shift size equal to the
768  * cipher's block size. The Initial Vector (IV) is specified as all
769  * zeros. Instead of using an IV, OpenPGP prefixes a 10-octet string to
770  * the data before it is encrypted. The first eight octets are random,
771  * and the 9th and 10th octets are copies of the 7th and 8th octets,
772  * respectively. After encrypting the first 10 octets, the CFB state is
773  * resynchronized if the cipher block size is 8 octets or less. The
774  * last 8 octets of ciphertext are passed through the cipher and the
775  * block boundary is reset.
776  *
777  * The repetition of 16 bits in the 80 bits of random data prefixed to
778  * the message allows the receiver to immediately check whether the
779  * session key is incorrect.
780  */
781 typedef struct pgpPktEdata_s {
782  uint8_t data[1];
783 } pgpPktEdata;
784 
785 /* \ingroup rpmpgp
786  * 5.8. Marker Packet (Obsolete Literal Packet) (Tag 10)
787  *
788  * An experimental version of PGP used this packet as the Literal
789  * packet, but no released version of PGP generated Literal packets with
790  * this tag. With PGP 5.x, this packet has been re-assigned and is
791  * reserved for use as the Marker packet.
792  *
793  * The body of this packet consists of:
794  * - The three octets 0x50, 0x47, 0x50 (which spell "PGP" in UTF-8).
795  *
796  * Such a packet MUST be ignored when received. It may be placed at the
797  * beginning of a message that uses features not available in PGP 2.6.x
798  * in order to cause that version to report that newer software is
799  * necessary to process the message.
800  */
801 /* \ingroup rpmpgp
802  * 5.9. Literal Data Packet (Tag 11)
803  *
804  * A Literal Data packet contains the body of a message; data that is
805  * not to be further interpreted.
806  *
807  * The body of this packet consists of:
808  * - A one-octet field that describes how the data is formatted.
809  *
810  * If it is a 'b' (0x62), then the literal packet contains binary data.
811  * If it is a 't' (0x74), then it contains text data, and thus may need
812  * line ends converted to local form, or other text-mode changes. RFC
813  * 1991 also defined a value of 'l' as a 'local' mode for machine-local
814  * conversions. This use is now deprecated.
815  * - File name as a string (one-octet length, followed by file name),
816  * if the encrypted data should be saved as a file.
817  *
818  * If the special name "_CONSOLE" is used, the message is considered to
819  * be "for your eyes only". This advises that the message data is
820  * unusually sensitive, and the receiving program should process it more
821  * carefully, perhaps avoiding storing the received data to disk, for
822  * example.
823  * - A four-octet number that indicates the modification date of the
824  * file, or the creation time of the packet, or a zero that
825  * indicates the present time.
826  * - The remainder of the packet is literal data.
827  *
828  * Text data is stored with <CR><LF> text endings (i.e. network-normal
829  * line endings). These should be converted to native line endings by
830  * the receiving software.
831  */
832 typedef struct pgpPktLdata_s {
833  uint8_t format;
834  uint8_t filenamelen;
835  uint8_t filename[1];
836 } pgpPktLdata;
837 
838 /* \ingroup rpmpgp
839  * 5.10. Trust Packet (Tag 12)
840  *
841  * The Trust packet is used only within keyrings and is not normally
842  * exported. Trust packets contain data that record the user's
843  * specifications of which key holders are trustworthy introducers,
844  * along with other information that implementing software uses for
845  * trust information.
846  *
847  * Trust packets SHOULD NOT be emitted to output streams that are
848  * transferred to other users, and they SHOULD be ignored on any input
849  * other than local keyring files.
850  */
851 typedef struct pgpPktTrust_s {
852  uint8_t flag;
853 } pgpPktTrust;
854 
855 /* \ingroup rpmpgp
856  * 5.11. User ID Packet (Tag 13)
857  *
858  * A User ID packet consists of data that is intended to represent the
859  * name and email address of the key holder. By convention, it includes
860  * an RFC 822 mail name, but there are no restrictions on its content.
861  * The packet length in the header specifies the length of the user id.
862  * If it is text, it is encoded in UTF-8.
863  *
864  */
865 typedef struct pgpPktUid_s {
866  uint8_t userid[1];
867 } pgpPktUid;
868 
871 union pgpPktPre_u {
873  pgpPktSig sig;
876  pgpPktKey key;
883 };
884 
887 typedef enum pgpArmor_e {
895 #define PGPARMOR_ERROR PGPARMOR_ERR_NO_BEGIN_PGP
904 } pgpArmor;
905 
908 typedef enum pgpArmorKey_e {
914 } pgpArmorKey;
915 
916 typedef enum pgpValType_e {
927 } pgpValType;
928 
934 };
935 
937 
944 const char * pgpValString(pgpValType type, uint8_t val);
945 
952 static inline
953 unsigned int pgpGrab(const uint8_t *s, size_t nbytes)
954 {
955  size_t i = 0;
956  size_t nb = (nbytes <= sizeof(i) ? nbytes : sizeof(i));
957  while (nb--)
958  i = (i << 8) | *s++;
959  return i;
960 }
961 
968 char * pgpHexStr(const uint8_t *p, size_t plen);
969 
978 int pgpPubkeyFingerprint(const uint8_t * pkt, size_t pktlen,
979  uint8_t **fp, size_t *fplen);
980 
988 int pgpPubkeyKeyID(const uint8_t * pkt, size_t pktlen, pgpKeyID_t keyid);
989 
998 int pgpPrtParams(const uint8_t *pkts, size_t pktlen, unsigned int pkttype,
999  pgpDigParams * ret);
1000 
1010 int pgpPrtParamsSubkeys(const uint8_t *pkts, size_t pktlen,
1011  pgpDigParams mainkey, pgpDigParams **subkeys,
1012  int *subkeysCount);
1021 int pgpPrtPkts(const uint8_t *pkts, size_t pktlen, pgpDig dig, int printing);
1022 
1030 pgpArmor pgpReadPkts(const char * fn, uint8_t ** pkt, size_t * pktlen);
1031 
1039 pgpArmor pgpParsePkts(const char *armor, uint8_t ** pkt, size_t * pktlen);
1040 
1053 int pgpPubKeyCertLen(const uint8_t *pkts, size_t pktslen, size_t *certlen);
1054 
1062 char * pgpArmorWrap(int atype, const unsigned char * s, size_t ns);
1063 
1068 pgpDig pgpNewDig(void);
1069 
1074 void pgpCleanDig(pgpDig dig);
1075 
1081 pgpDig pgpFreeDig(pgpDig dig);
1082 
1089 pgpDigParams pgpDigGetParams(pgpDig dig, unsigned int pkttype);
1090 
1097 int pgpDigParamsCmp(pgpDigParams p1, pgpDigParams p2);
1098 
1105 unsigned int pgpDigParamsAlgo(pgpDigParams digp, unsigned int algotype);
1106 
1112 pgpDigParams pgpDigParamsFree(pgpDigParams digp);
1113 
1121 rpmRC pgpVerifySignature(pgpDigParams key, pgpDigParams sig, DIGEST_CTX hashctx);
1122 
1131 rpmRC pgpVerifySig(pgpDig dig, DIGEST_CTX hashctx);
1132 
1138 char *pgpIdentItem(pgpDigParams digp);
1139 
1147 int rpmInitCrypto(void);
1148 
1152 int rpmFreeCrypto(void);
1153 
1159 DIGEST_CTX rpmDigestDup(DIGEST_CTX octx);
1160 
1166 size_t rpmDigestLength(int hashalgo);
1167 
1175 DIGEST_CTX rpmDigestInit(int hashalgo, rpmDigestFlags flags);
1176 
1184 int rpmDigestUpdate(DIGEST_CTX ctx, const void * data, size_t len);
1185 
1197 int rpmDigestFinal(DIGEST_CTX ctx,
1198  void ** datap,
1199  size_t * lenp, int asAscii);
1200 
1205 rpmDigestBundle rpmDigestBundleNew(void);
1206 
1212 rpmDigestBundle rpmDigestBundleFree(rpmDigestBundle bundle);
1213 
1222 int rpmDigestBundleAdd(rpmDigestBundle bundle, int algo,
1223  rpmDigestFlags flags);
1224 
1233 int rpmDigestBundleAddID(rpmDigestBundle bundle, int algo, int id,
1234  rpmDigestFlags flags);
1235 
1243 int rpmDigestBundleUpdate(rpmDigestBundle bundle, const void *data, size_t len);
1244 
1255 int rpmDigestBundleFinal(rpmDigestBundle bundle, int id,
1256  void ** datap, size_t * lenp, int asAscii);
1257 
1264 DIGEST_CTX rpmDigestBundleDupCtx(rpmDigestBundle bundle, int id);
1265 
1266 #ifdef __cplusplus
1267 }
1268 #endif
1269 
1270 #endif /* H_RPMPGP */
5.5.1.
Definition: rpmpgp.h:605
uint8_t hash_algo
Definition: rpmpgp.h:325
pgpArmor pgpParsePkts(const char *armor, uint8_t **pkt, size_t *pktlen)
Parse armored OpenPGP packets from memory.
enum pgpPubkeyAlgo_e pgpPubkeyAlgo
9.1.
pgpDig pgpNewDig(void)
Create a container for parsed OpenPGP packet(s).
uint8_t hash_algo
Definition: rpmpgp.h:527
struct pgpPktSigV4_s * pgpPktSigV4
5.2.3.
struct pgpPktPubkey_s pgpPktPubkey
5.1.
pgpPktCdata cdata
Definition: rpmpgp.h:877
uint8_t pubkey_algo
Definition: rpmpgp.h:646
struct pgpPktKeyV3_s * pgpPktKeyV3
5.5.1.
pgpValType_e
Definition: rpmpgp.h:916
enum pgpSymkeyAlgo_e pgpSymkeyAlgo
9.2.
pgpPktOnepass onepass
Definition: rpmpgp.h:875
pgpTime_t time
Definition: rpmpgp.h:645
int pgpDigParamsCmp(pgpDigParams p1, pgpDigParams p2)
Compare OpenPGP packet parameters param p1 1st parameter container param p2 2nd parameter container r...
pgpTag_e
4.3.
Definition: rpmpgp.h:46
pgpArmor pgpReadPkts(const char *fn, uint8_t **pkt, size_t *pktlen)
Parse armored OpenPGP packets from a file.
uint8_t version
Definition: rpmpgp.h:290
uint8_t version
Definition: rpmpgp.h:606
rpmDigestBundle rpmDigestBundleFree(rpmDigestBundle bundle)
Free a digest bundle and all contained digest contexts.
pgpPubkeyAlgo_e
9.1.
Definition: rpmpgp.h:162
uint8_t version
Definition: rpmpgp.h:525
struct pgpPktKeyV4_s * pgpPktKeyV4
The version 4 format is similar to the version 3 format except for the absence of a validity period...
int rpmDigestFinal(DIGEST_CTX ctx, void **datap, size_t *lenp, int asAscii)
Return digest and destroy context.
struct DIGEST_CTX_s * DIGEST_CTX
Definition: rpmpgp.h:25
5.2.3.
Definition: rpmpgp.h:321
enum pgpCompressAlgo_e pgpCompressAlgo
9.3.
DIGEST_CTX rpmDigestBundleDupCtx(rpmDigestBundle bundle, int id)
Duplicate a digest context from a bundle.
DIGEST_CTX rpmDigestInit(int hashalgo, rpmDigestFlags flags)
Initialize digest.
uint8_t version
Definition: rpmpgp.h:107
pgpPktSig sig
Definition: rpmpgp.h:873
enum pgpArmorKey_e pgpArmorKey
uint8_t version
Definition: rpmpgp.h:322
pgpArmorKey_e
Definition: rpmpgp.h:908
uint8_t pubkey_algo
Definition: rpmpgp.h:528
pgpDig pgpFreeDig(pgpDig dig)
Destroy a container for parsed OpenPGP packet(s).
uint8_t flag
Definition: rpmpgp.h:852
struct pgpDig_s * pgpDig
Definition: rpmpgp.h:30
rpmRC pgpVerifySignature(pgpDigParams key, pgpDigParams sig, DIGEST_CTX hashctx)
Verify a PGP signature.
5.2.2.
Definition: rpmpgp.h:289
int pgpPubkeyKeyID(const uint8_t *pkt, size_t pktlen, pgpKeyID_t keyid)
Calculate OpenPGP public key Key ID.
5.5.3.
Definition: rpmpgp.h:713
struct pgpPktTrust_s pgpPktTrust
struct pgpPktEdata_s pgpPktEdata
uint8_t pgpKeyID_t[8]
Definition: rpmpgp.h:36
int rpmDigestBundleFinal(rpmDigestBundle bundle, int id, void **datap, size_t *lenp, int asAscii)
Return digest from a bundle and destroy context, see rpmDigestFinal().
static unsigned int pgpGrab(const uint8_t *s, size_t nbytes)
Return (native-endian) integer from big-endian representation.
Definition: rpmpgp.h:953
struct rpmDigestBundle_s * rpmDigestBundle
Definition: rpmpgp.h:26
uint8_t pubkey_algo
Definition: rpmpgp.h:324
rpmFlags rpmDigestFlags
Definition: rpmpgp.h:936
uint32_t rpmFlags
Definition: rpmtypes.h:42
pgpArmor_e
Definition: rpmpgp.h:887
struct pgpPktLdata_s pgpPktLdata
pgpPktPubkey pubkey
Definition: rpmpgp.h:872
enum pgpHashAlgo_e pgpHashAlgo
9.4.
enum pgpValType_e pgpValType
uint8_t version
Definition: rpmpgp.h:490
struct pgpPktUid_s pgpPktUid
uint8_t symkey_algo
Definition: rpmpgp.h:491
int rpmDigestUpdate(DIGEST_CTX ctx, const void *data, size_t len)
Update context with next plain text buffer.
DIGEST_CTX rpmDigestDup(DIGEST_CTX octx)
Duplicate a digest context.
uint8_t format
Definition: rpmpgp.h:833
uint8_t sigtype
Definition: rpmpgp.h:323
uint8_t hash_algo
Definition: rpmpgp.h:296
char * pgpHexStr(const uint8_t *p, size_t plen)
Return hex formatted representation of bytes.
pgpPktKey key
Definition: rpmpgp.h:876
pgpDigParams pgpDigParamsFree(pgpDigParams digp)
Destroy parsed OpenPGP packet parameter(s).
rpmDigestFlags_e
Bit(s) to control digest operation.
Definition: rpmpgp.h:932
pgpDigParams pgpDigGetParams(pgpDig dig, unsigned int pkttype)
Retrieve parameters for parsed OpenPGP packet(s).
union pgpPktKey_u pgpPktKey
5.5.3.
struct pgpPktCdata_s pgpPktCdata
rpmRC pgpVerifySig(pgpDig dig, DIGEST_CTX hashctx)
Verify a PGP signature.
int rpmDigestBundleUpdate(rpmDigestBundle bundle, const void *data, size_t len)
Update contexts within bundle with next plain text buffer.
rpmDigestBundle rpmDigestBundleNew(void)
Create a new digest bundle.
int pgpPubkeyFingerprint(const uint8_t *pkt, size_t pktlen, uint8_t **fp, size_t *fplen)
Calculate OpenPGP public key fingerprint.
enum pgpSubType_e pgpSubType
5.2.3.1.
uint8_t algo
Definition: rpmpgp.h:109
pgpTime_t time
Definition: rpmpgp.h:607
pgpSubType_e
5.2.3.1.
Definition: rpmpgp.h:395
pgpPktLdata ldata
Definition: rpmpgp.h:880
char * pgpArmorWrap(int atype, const unsigned char *s, size_t ns)
Wrap a OpenPGP packets in ascii armor for transport.
uint8_t nested
Definition: rpmpgp.h:530
uint8_t compressalgo
Definition: rpmpgp.h:743
pgpHashAlgo_e
9.4.
Definition: rpmpgp.h:255
pgpTime_t time
Definition: rpmpgp.h:293
struct pgpPktSigV3_s * pgpPktSigV3
5.2.2.
pgpKeyID_t signid
Definition: rpmpgp.h:294
pgpPktUid uid
Definition: rpmpgp.h:882
enum pgpTag_e pgpTag
4.3.
uint8_t pgpTime_t[4]
Definition: rpmpgp.h:37
unsigned int pgpDigParamsAlgo(pgpDigParams digp, unsigned int algotype)
Retrieve OpenPGP algorithm parameters param digp parameter container param algotype PGPVAL_HASHALGO /...
uint8_t version
Definition: rpmpgp.h:644
uint8_t pubkey_algo
Definition: rpmpgp.h:609
int rpmDigestBundleAddID(rpmDigestBundle bundle, int algo, int id, rpmDigestFlags flags)
Add a new type of digest to a bundle.
int rpmInitCrypto(void)
Perform cryptography initialization.
char * pgpIdentItem(pgpDigParams digp)
Return a string identification of a PGP signature/pubkey.
pgpPktEdata edata
Definition: rpmpgp.h:878
pgpSigType_e
5.2.1.
Definition: rpmpgp.h:119
uint8_t hashlen
Definition: rpmpgp.h:291
pgpPktTrust tdata
Definition: rpmpgp.h:881
uint8_t pubkey_algo
Definition: rpmpgp.h:295
5.2.
Definition: rpmpgp.h:456
pgpKeyID_t keyid
Definition: rpmpgp.h:108
struct pgpDigParams_s * pgpDigParams
Definition: rpmpgp.h:34
int rpmFreeCrypto(void)
Shutdown cryptography.
int pgpPubKeyCertLen(const uint8_t *pkts, size_t pktslen, size_t *certlen)
Return a length of the first public key certificate in a buffer given by pkts that contains one or mo...
struct pgpPktSymkey_s pgpPktSymkey
5.3.
pgpSymkeyAlgo_e
9.2.
Definition: rpmpgp.h:198
int pgpPrtParamsSubkeys(const uint8_t *pkts, size_t pktlen, pgpDigParams mainkey, pgpDigParams **subkeys, int *subkeysCount)
Parse subkey parameters from OpenPGP packet(s).
const char * pgpValString(pgpValType type, uint8_t val)
Return string representation of am OpenPGP value.
enum pgpSigType_e pgpSigType
5.2.1.
int pgpPrtParams(const uint8_t *pkts, size_t pktlen, unsigned int pkttype, pgpDigParams *ret)
Parse a OpenPGP packet(s).
union pgpPktSig_u * pgpPktSig
5.2.
uint8_t sigtype
Definition: rpmpgp.h:292
int rpmDigestBundleAdd(rpmDigestBundle bundle, int algo, rpmDigestFlags flags)
Add a new type of digest to a bundle.
void pgpCleanDig(pgpDig dig)
Release (malloc&#39;d) data from container.
pgpCompressAlgo_e
9.3.
Definition: rpmpgp.h:228
int pgpPrtPkts(const uint8_t *pkts, size_t pktlen, pgpDig dig, int printing)
Print/parse a OpenPGP packet(s).
The version 4 format is similar to the version 3 format except for the absence of a validity period...
Definition: rpmpgp.h:643
uint8_t sigtype
Definition: rpmpgp.h:526
pgpKeyID_t signid
Definition: rpmpgp.h:529
enum pgpArmor_e pgpArmor
uint8_t filenamelen
Definition: rpmpgp.h:834
enum rpmRC_e rpmRC
Package read return codes.
size_t rpmDigestLength(int hashalgo)
Obtain digest length in bytes.
pgpPktSymkey symkey
Definition: rpmpgp.h:874
struct pgpPktOnepass_s * pgpPktOnepass
5.4.