rpmverifypackage probe
More...
#include <stdio.h>
#include <string.h>
#include <errno.h>
#include <assert.h>
#include <limits.h>
#include <sys/types.h>
#include <sys/stat.h>
#include <fcntl.h>
#include <pcre.h>
#include <rpm/rpmdb.h>
#include <rpm/rpmlib.h>
#include <rpm/rpmts.h>
#include <rpm/rpmmacro.h>
#include <rpm/rpmlog.h>
#include <rpm/rpmfi.h>
#include <rpm/header.h>
#include <rpm/rpmcli.h>
#include <popt.h>
#include <probe-api.h>
#include <alloc.h>
#include <common/assume.h>
#include "debug_priv.h"
#include "probe/entcmp.h"
|
#define | HAVE_LIBRPM44 1 /* hack */ |
|
#define | headerFormat(_h, _fmt, _emsg) headerSprintf((_h),( _fmt), rpmTagTable, rpmHeaderFormats, (_emsg)) |
|
#define | rpmFreeCrypto() while(0) |
|
#define | rpmFreeFilesystems() while(0) |
|
#define | RPMVERIFY_SKIP_CONFIG 0x1000000000000000 |
|
#define | RPMVERIFY_SKIP_GHOST 0x2000000000000000 |
|
#define | RPMVERIFY_RPMATTRMASK 0x00000000ffffffff |
|
#define | RPMVERIFY_LOCK |
|
#define | RPMVERIFY_UNLOCK |
|
#define | COMPARE_ENT(XXX) |
|
|
void * | probe_init (void) |
| Dummy probe_fini function.
|
|
void | probe_fini (void *ptr) |
| Dummy probe_fini function.
|
|
int | probe_main (probe_ctx *ctx, void *arg) |
|
#define COMPARE_ENT |
( |
|
XXX | ) |
|
Value:if (XXX ## _ent != NULL) { \
ent = probe_entval_from_cstr( \
); \
SEXP_free(ent); \
continue; \
} \
SEXP_free(ent); \
}
oval_datatype_t probe_ent_getdatatype(const SEXP_t *ent)
Get the OVAL data type of an entity.
Definition: probe-api.c:1141
oval_result_t probe_entobj_cmp(SEXP_t *ent_obj, SEXP_t *val)
Compare object entity's content with a value.
Definition: entcmp.c:421
Characteristics being evaluated match the information represented in the system characteristic.
Definition: oval_types.h:325
Value:do { \
int prev_cancel_state = -1; \
if (pthread_mutex_lock(&g_rpm.mutex) != 0) { \
dE("Can't lock mutex\n"); \
return (-1); \
} \
pthread_setcancelstate(PTHREAD_CANCEL_DISABLE, &prev_cancel_state); \
} while(0)
Value:do { \
int prev_cancel_state = -1; \
if (pthread_mutex_unlock(&g_rpm.mutex) != 0) { \
dE("Can't unlock mutex. Aborting...\n"); \
abort(); \
} \
pthread_setcancelstate(PTHREAD_CANCEL_ENABLE, &prev_cancel_state); \
} while(0)
Initial value:= {
{ "nodeps", (uint64_t)VERIFY_DEPS , "--nodeps"},
{ "nodigest", (uint64_t)VERIFY_DIGEST , "--nodigest"},
{ "noscripts", (uint64_t)VERIFY_SCRIPT , "--noscript"},
{ "nosignature", (uint64_t)VERIFY_SIGNATURE , "--nosignature"}
}