lib/rpmns.h File Reference

Structure(s) and routine(s) used for classifying and parsing names. More...

This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Typedefs

typedef struct rpmns_s * rpmns
typedef enum nsType_e nsType
 Dependency types.

Enumerations

enum  nsType_e {
  RPMNS_TYPE_UNKNOWN = 0, RPMNS_TYPE_STRING = (1 << 0), RPMNS_TYPE_PATH = (1 << 1), RPMNS_TYPE_DSO = (1 << 2),
  RPMNS_TYPE_FUNCTION = (1 << 3), RPMNS_TYPE_ARCH = (1 << 4), RPMNS_TYPE_VERSION = (1 << 5), RPMNS_TYPE_COMPOUND = (1 << 6),
  RPMNS_TYPE_NAMESPACE = (1 << 8), RPMNS_TYPE_RPMLIB = (1 << 9), RPMNS_TYPE_CPUINFO = (1 << 10), RPMNS_TYPE_GETCONF = (1 << 11),
  RPMNS_TYPE_UNAME = (1 << 12), RPMNS_TYPE_SONAME = (1 << 13), RPMNS_TYPE_ACCESS = (1 << 14), RPMNS_TYPE_TAG = (1 << 15),
  RPMNS_TYPE_USER = (1 << 16), RPMNS_TYPE_GROUP = (1 << 17), RPMNS_TYPE_MOUNTED = (1 << 18), RPMNS_TYPE_DISKSPACE = (1 << 19),
  RPMNS_TYPE_DIGEST = (1 << 20), RPMNS_TYPE_GNUPG = (1 << 21), RPMNS_TYPE_MACRO = (1 << 22), RPMNS_TYPE_ENVVAR = (1 << 23),
  RPMNS_TYPE_RUNNING = (1 << 24), RPMNS_TYPE_SANITY = (1 << 25), RPMNS_TYPE_VCHECK = (1 << 26), RPMNS_TYPE_SIGNATURE = (1 << 27)
}
 Dependency types. More...

Functions

nsType rpmnsArch (const char *str)
 Is string a known arch suffix?
nsType rpmnsProbe (const char *str)
 Is string a known probe namespace?
nsType rpmnsClassify (const char *str)
 Classify a string as a dependency type.
int rpmnsParse (const char *str, rpmns ns)
 Split NS string into namespace, name and arch components.
void rpmnsClean (void)
 Clean global name space dependency sets.
rpmRC rpmnsProbeSignature (void *_ts, const char *fn, const char *sigfn, const char *pubfn, const char *pubid, int flags)
 Verify OpenPGP signature on a file.

Variables

int _rpmns_debug
const char * _rpmns_N_at_A


Detailed Description

Structure(s) and routine(s) used for classifying and parsing names.

Definition in file rpmns.h.


Typedef Documentation

typedef enum nsType_e nsType

Dependency types.

typedef struct rpmns_s* rpmns

Definition at line 19 of file rpmns.h.


Enumeration Type Documentation

enum nsType_e

Dependency types.

Enumerator:
RPMNS_TYPE_UNKNOWN 
RPMNS_TYPE_STRING  unclassified string
RPMNS_TYPE_PATH  /bin
RPMNS_TYPE_DSO  libc.so.6
RPMNS_TYPE_FUNCTION  %{foo}
RPMNS_TYPE_ARCH  foo.arch
RPMNS_TYPE_VERSION  foo-1.2.3-bar
RPMNS_TYPE_COMPOUND  foo.bar
RPMNS_TYPE_NAMESPACE  foo(bar)
RPMNS_TYPE_RPMLIB  rpmlib(bar)
RPMNS_TYPE_CPUINFO  cpuinfo(bar)
RPMNS_TYPE_GETCONF  getconf(bar)
RPMNS_TYPE_UNAME  uname(bar)
RPMNS_TYPE_SONAME  soname(bar)
RPMNS_TYPE_ACCESS  exists(bar)
RPMNS_TYPE_TAG  Tag(bar)
RPMNS_TYPE_USER  user(bar)
RPMNS_TYPE_GROUP  group(bar)
RPMNS_TYPE_MOUNTED  mounted(/path)
RPMNS_TYPE_DISKSPACE  diskspace(/path)
RPMNS_TYPE_DIGEST  digest(/path) = hex
RPMNS_TYPE_GNUPG  gnupg(/path/file.asc)
RPMNS_TYPE_MACRO  macro(foo)
RPMNS_TYPE_ENVVAR  envvar(foo)
RPMNS_TYPE_RUNNING  running(foo)
RPMNS_TYPE_SANITY  sanitycheck(foo)
RPMNS_TYPE_VCHECK  vcheck(foo)
RPMNS_TYPE_SIGNATURE  signature(/text:/sig) = /pub:id

Definition at line 24 of file rpmns.h.


Function Documentation

void rpmnsClean ( void   ) 

Clean global name space dependency sets.

Definition at line 553 of file depends.c.

References _free(), _sysinfo_path, cpuinfoP, getconfP, rpmdsFree(), rpmlibP, sysinfo_path, and unameP.

Referenced by rpmcliFini().

rpmRC rpmnsProbeSignature ( void *  _ts,
const char *  fn,
const char *  sigfn,
const char *  pubfn,
const char *  pubid,
int  flags 
)

Verify OpenPGP signature on a file.

Parameters:
_ts transaction set
fn plaintext (or clearsign) file
sigfn binary/pem encoded signature file (NULL iff clearsign)
pubfn binary/pem encoded pubkey file (NULL uses rpmdb keyring)
pubid pubkey fingerprint hex string (NULL disables check)
flags (unused)
Returns:
RPMRC_OK if verified, RPMRC_FAIL if not verified

Definition at line 259 of file rpmns.c.

References _free(), _rpmns_debug, alloca(), nibble(), pgpFindPubkey(), pgpGetPubkey(), pgpGetSignature(), pgpGrab(), pgpImplSetDSA(), pgpImplSetRSA(), pgpImplVerifyDSA(), pgpImplVerifyRSA(), pgpPrtPkts(), PGPPUBKEYALGO_DSA, PGPPUBKEYALGO_RSA, pgpReadPkts(), RPMDIGEST_NONE, rpmDigestInit(), rpmDigestUpdate(), rpmExpand(), rpmioSlurp(), RPMRC_FAIL, RPMRC_NOKEY, RPMRC_OK, rpmtsCleanDig(), and rpmtsDig().

Referenced by unsatisfiedDepend().


Variable Documentation

Definition at line 27 of file rpmns.c.

Referenced by rpmnsProbeSignature().

const char* _rpmns_N_at_A

Definition at line 30 of file rpmns.c.

Referenced by rpmdsNewDNEVR(), rpmnsClassify(), and rpmnsParse().


Generated on Mon Sep 28 13:41:57 2009 for rpm by  doxygen 1.5.9