40 #define PGP_KEYID_LEN 8
927 #define PGPARMOR_ERROR PGPARMOR_ERR_NO_BEGIN_PGP
976 unsigned int pgpGrab(
const uint8_t *s,
size_t nbytes)
979 size_t nb = (nbytes <=
sizeof(i) ? nbytes :
sizeof(i));
994 uint8_t **fp,
size_t *fplen);
struct DIGEST_CTX_s * DIGEST_CTX
enum pgpHashAlgo_e pgpHashAlgo
9.4.
rpmRC pgpVerifySignature(pgpDigParams key, pgpDigParams sig, DIGEST_CTX hashctx)
Verify a PGP signature.
int pgpPrtParams(const uint8_t *pkts, size_t pktlen, unsigned int pkttype, pgpDigParams *ret)
Parse a OpenPGP packet(s).
enum pgpPubkeyAlgo_e pgpPubkeyAlgo
9.1.
enum pgpSigType_e pgpSigType
5.2.1.
pgpDig pgpNewDig(void)
Create a container for parsed OpenPGP packet(s).
struct pgpPktKeyV4_s * pgpPktKeyV4
The version 4 format is similar to the version 3 format except for the absence of a validity period.
struct pgpPktSigV3_s * pgpPktSigV3
5.2.2.
uint32_t pgpDigParamsCreationTime(pgpDigParams digp)
Retrieve the object's creation time.
pgpDig pgpFreeDig(pgpDig dig)
Destroy a container for parsed OpenPGP packet(s).
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...
int pgpSignatureType(pgpDigParams sig)
Return the type of a PGP signature.
struct pgpPktTrust_s pgpPktTrust
5.10.
struct pgpPktKeyV3_s * pgpPktKeyV3
5.5.1.
void pgpCleanDig(pgpDig dig)
Release (malloc'd) data from container.
int pgpDigParamsVersion(pgpDigParams digp)
Retrieve the object's version.
struct pgpPktOnepass_s * pgpPktOnepass
5.4.
pgpArmor pgpParsePkts(const char *armor, uint8_t **pkt, size_t *pktlen)
Parse armored OpenPGP packets from memory.
const char * pgpDigParamsUserID(pgpDigParams digp)
Retrieve the primary User ID, if any.
pgpArmor pgpReadPkts(const char *fn, uint8_t **pkt, size_t *pktlen)
Parse armored OpenPGP packets from a file.
const char * pgpValString(pgpValType type, uint8_t val)
Return string representation of am OpenPGP value.
struct pgpPktCdata_s pgpPktCdata
5.6.
rpmRC pgpPubKeyLint(const uint8_t *pkts, size_t pktslen, char **explanation)
Lints the certificate.
enum pgpCompressAlgo_e pgpCompressAlgo
9.3.
union pgpPktKey_u pgpPktKey
5.5.3.
int pgpDigParamsCmp(pgpDigParams p1, pgpDigParams p2)
Compare OpenPGP packet parameters param p1 1st parameter container param p2 2nd parameter container r...
enum pgpArmorKey_e pgpArmorKey
struct pgpDigParams_s * pgpDigParams
const uint8_t * pgpDigParamsSignID(pgpDigParams digp)
Returns the issuer or the object's Key ID.
union pgpPktSig_u * pgpPktSig
5.2.
unsigned int pgpDigParamsAlgo(pgpDigParams digp, unsigned int algotype)
Retrieve OpenPGP algorithm parameters param digp parameter container param algotype PGPVAL_HASHALGO /...
#define PGP_KEYID_LEN
The length (in bytes) of a binary (not hex encoded) key ID.
enum pgpSymkeyAlgo_e pgpSymkeyAlgo
9.2.
struct pgpPktLdata_s pgpPktLdata
5.8.
pgpDigParams pgpDigParamsFree(pgpDigParams digp)
Destroy parsed OpenPGP packet parameter(s).
int pgpPubkeyKeyID(const uint8_t *pkt, size_t pktlen, pgpKeyID_t keyid)
Calculate OpenPGP public key Key ID.
int pgpPrtPkts(const uint8_t *pkts, size_t pktlen, pgpDig dig, int printing)
Print/parse a OpenPGP packet(s).
enum pgpSubType_e pgpSubType
5.2.3.1.
struct pgpPktEdata_s pgpPktEdata
5.7.
char * pgpArmorWrap(int atype, const unsigned char *s, size_t ns)
Wrap a OpenPGP packets in ascii armor for transport.
pgpDigParams pgpDigGetParams(pgpDig dig, unsigned int pkttype)
Retrieve parameters for parsed OpenPGP packet(s).
struct pgpPktUid_s pgpPktUid
5.11.
int pgpPrtParamsSubkeys(const uint8_t *pkts, size_t pktlen, pgpDigParams mainkey, pgpDigParams **subkeys, int *subkeysCount)
Parse subkey parameters from OpenPGP packet(s).
char * pgpIdentItem(pgpDigParams digp)
Return a string identification of a PGP signature/pubkey.
rpmRC pgpVerifySig(pgpDig dig, DIGEST_CTX hashctx)
Verify a PGP signature.
static unsigned int pgpGrab(const uint8_t *s, size_t nbytes)
Return (native-endian) integer from big-endian representation.
int pgpPubkeyFingerprint(const uint8_t *pkt, size_t pktlen, uint8_t **fp, size_t *fplen)
Calculate OpenPGP public key fingerprint.
struct pgpPktPubkey_s pgpPktPubkey
5.1.
struct pgpPktSigV4_s * pgpPktSigV4
5.2.3.
enum pgpCurveId_e pgpCurveId
ECC Curves.
@ PGPPUBKEYALGO_RSA_ENCRYPT
@ PGPPUBKEYALGO_ELGAMAL_ENCRYPT
@ PGPCURVE_BRAINPOOL_P256R1
@ PGPCURVE_BRAINPOOL_P512R1
@ PGPARMOR_ERR_CRC_DECODE
@ PGPARMOR_ERR_BODY_DECODE
@ PGPARMOR_SIGNED_MESSAGE
@ PGPARMOR_ERR_UNKNOWN_ARMOR_TYPE
@ PGPARMOR_ERR_NO_BEGIN_PGP
@ PGPARMOR_ERR_NO_END_PGP
@ PGPARMOR_ERR_UNKNOWN_PREAMBLE_TAG
@ PGPHASHALGO_HAVAL_5_160
@ PGPSIGTYPE_GENERIC_CERT
@ PGPSIGTYPE_SUBKEY_BINDING
@ PGPSIGTYPE_PERSONA_CERT
@ PGPSIGTYPE_SUBKEY_REVOKE
@ PGPSIGTYPE_POSITIVE_CERT
@ PGPTAG_ONEPASS_SIGNATURE
@ PGPTAG_PUBLIC_SESSION_KEY
@ PGPTAG_SYMMETRIC_SESSION_KEY
@ PGPSYMKEYALGO_PLAINTEXT
@ PGPSYMKEYALGO_NOENCRYPT
@ PGPSYMKEYALGO_TRIPLE_DES
@ PGPSUBTYPE_EMBEDDED_SIG
@ PGPSUBTYPE_EXPORTABLE_CERT
@ PGPSUBTYPE_ISSUER_KEYID
@ PGPSUBTYPE_PREFER_SYMKEY
@ PGPSUBTYPE_SIG_EXPIRE_TIME
@ PGPSUBTYPE_INTERNAL_104
@ PGPSUBTYPE_SIGNER_USERID
@ PGPSUBTYPE_PREFER_COMPRESS
@ PGPSUBTYPE_KEY_EXPIRE_TIME
@ PGPSUBTYPE_INTERNAL_101
@ PGPSUBTYPE_SIG_CREATE_TIME
@ PGPSUBTYPE_REVOKE_REASON
@ PGPSUBTYPE_KEYSERVER_PREFERS
@ PGPSUBTYPE_INTERNAL_110
@ PGPSUBTYPE_INTERNAL_109
@ PGPSUBTYPE_INTERNAL_108
@ PGPSUBTYPE_INTERNAL_105
@ PGPSUBTYPE_INTERNAL_100
@ PGPSUBTYPE_PREFER_KEYSERVER
@ PGPSUBTYPE_INTERNAL_107
@ PGPSUBTYPE_PRIMARY_USERID
@ PGPSUBTYPE_INTERNAL_102
@ PGPSUBTYPE_INTERNAL_103
@ PGPSUBTYPE_INTERNAL_106
enum rpmRC_e rpmRC
Package read return codes.
enum pgpValType_e pgpValType
struct pgpPktSymkey_s pgpPktSymkey
5.3.
String manipulation helper functions.
Typedefs for RPM abstract data types.
The version 4 format is similar to the version 3 format except for the absence of a validity period.