#include <rpmpgp.h>
Go to the source code of this file.
Functions | |
| rpmRC | headerCheck (pgpDig dig, const void *uh, size_t uc, const char **msg) |
| Check header consistency, performing headerGetEntry() the hard way. | |
| size_t | rpmpkgSizeof (const char *fn, const void *ptr) |
| Return size of item in bytes. | |
| rpmRC | rpmpkgWrite (const char *fn, FD_t fd, void *ptr, const char **msg) |
| Write item onto file descriptor. | |
| rpmRC | rpmpkgRead (const char *fn, FD_t fd, void *ptr, const char **msg) |
| Read item from file descriptor. | |
| rpmRC | rpmpkgCheck (const char *fn, FD_t fd, const void *ptr, const char **msg) |
| Verify item integrity. | |
Definition in file pkgio.h.
Check header consistency, performing headerGetEntry() the hard way.
Sanity checks on the header are performed while looking for a header-only digest or signature to verify the blob. If found, the digest or signature is verified.
| dig | signature parameters container | |
| uh | unloaded header blob | |
| uc | no. of bytes in blob (or 0 to disable) |
| *msg | verification error message (or NULL) |
Sanity checks on the header are performed while looking for a header-only digest or signature to verify the blob. If found, the digest or signature is verified.
| ts | transaction set | |
| uh | unloaded header blob | |
| uc | no. of bytes in blob (or 0 to disable) |
| *msg | signature verification msg |
Definition at line 880 of file pkgio.c.
References _, _free(), _pkgio_debug, _print_pkts, alloca(), entryInfo_s::count, headerGetMagic(), headerVerifyInfo(), indexEntry_s::info, entryInfo_s::offset, pgpDigVSFlags, pgpGetSig(), PGPHASHALGO_SHA1, pgpPrtPkts(), pgpSetSig(), pgpStatsAccumulator(), REGION_TAG_COUNT, RPM_BIN_TYPE, RPM_STRING_TYPE, RPMDIGEST_NONE, rpmDigestInit(), rpmDigestUpdate(), rpmIsDebug, rpmlog(), RPMLOG_ERR, RPMRC_FAIL, RPMRC_NOTFOUND, RPMRC_OK, rpmswEnter(), rpmswExit(), RPMTAG_DSAHEADER, RPMTAG_HEADERIMMUTABLE, RPMTAG_RSAHEADER, RPMTAG_SHA1HEADER, rpmVerifySignature(), RPMVSF_NODSAHEADER, RPMVSF_NORSAHEADER, RPMVSF_NOSHA1HEADER, snprintf(), entryInfo_s::tag, entryInfo_s::type, xmalloc(), and xstrdup().
Referenced by miFreeHeader(), rpmdbAdd(), rpmdbNextIterator(), rpmReadHeader(), and rpmts_HdrCheck().
Verify item integrity.
| fn | item name | |
| fd | file handle | |
| ptr | item buffer |
| *msg | item check failure message |
Definition at line 1402 of file pkgio.c.
References ckHeader(), and RPMRC_FAIL.
Read item from file descriptor.
| fn | item name | |
| fd | file handle |
| *ptr | item buffer | |
| *msg | item check failure message |
Definition at line 1414 of file pkgio.c.
References rdHeader(), rdLead(), rdSignature(), and RPMRC_FAIL.
Referenced by makeHDRSignature(), readFile(), rpmgiNext(), rpmReadHeaders(), rpmReadPackageFile(), rpmReSign(), rpmSingleHeaderFromFD(), rpmVerifySignatures(), and writeRPM().
| size_t rpmpkgSizeof | ( | const char * | fn, | |
| const void * | ptr | |||
| ) |
Return size of item in bytes.
| fn | item name | |
| ptr | item buffer |
Definition at line 1386 of file pkgio.c.
References szHeader().
Referenced by printSize(), rpmpsmStage(), and writeRPM().
Write item onto file descriptor.
| fn | item name | |
| fd | file handle | |
| ptr | item buffer |
| *msg | item check failure message |
Definition at line 1432 of file pkgio.c.
References RPMRC_FAIL, wrHeader(), wrLead(), and wrSignature().
Referenced by makeHDRSignature(), rpmpsmStage(), rpmReSign(), and writeRPM().
1.5.6