CPE Language
[CPE]

Data Structures

struct  cpe_platformspec
 CPE platform specification. More...
struct  cpe_platform
 Single platform representation in CPE language. More...
struct  cpe_platform_iterator
 Iterator over CPE dictionary items. More...

Files

file  cpelang.h
 

Interface to Common Platform Enumeration (CPE) Language.


Enumerations

enum  cpe_lang_oper_t {
  CPE_LANG_OPER_HALT = 0x00, CPE_LANG_OPER_AND = 0x01, CPE_LANG_OPER_OR = 0x02, CPE_LANG_OPER_MATCH = 0x03,
  CPE_LANG_OPER_MASK = 0xFF, CPE_LANG_OPER_NOT = 0x100, CPE_LANG_OPER_NAND = CPE_LANG_OPER_AND | CPE_LANG_OPER_NOT, CPE_LANG_OPER_NOR = CPE_LANG_OPER_OR | CPE_LANG_OPER_NOT
}
 

CPE language operators.

More...

Functions

struct cpe_platformcpe_platform_iterator::cpe_platform_iterator_next (struct cpe_platform_iterator *it)
bool cpe_platform_iterator::cpe_platform_iterator_has_more (struct cpe_platform_iterator *it)
void cpe_platform_iterator::cpe_platform_iterator_free (struct cpe_platform_iterator *it)
struct cpe_platformspeccpe_platformspec::cpe_platformspec_new (const char *fname)
 New platform specification from file.
void cpe_platformspec::cpe_platformspec_free (struct cpe_platformspec *platformspec)
 Free specified platform specification list.
struct cpe_platform_iteratorcpe_platformspec::cpe_platformspec_get_items (const struct cpe_platformspec *platformspec)
 Get an iterator to platforms contained in this specification.
struct cpe_platformcpe_platformspec::cpe_platformspec_get_item (const struct cpe_platformspec *platformspec, const char *id)
 Get platform with given ID.
bool cpe_platform::cpe_platform_match_cpe (struct cpe_name **cpe, size_t n, const struct cpe_platform *platform)
 Match list of CPEs against CPE language platform specification.
const char * cpe_platform::cpe_platform_get_id (const struct cpe_platform *platform)
 Get CPE paltform ID.
const char * cpe_platform::cpe_platform_get_title (const struct cpe_platform *platform)
 Get CPE paltform title.
const char * cpe_platform::cpe_platform_get_remark (const struct cpe_platform *platform)
 Get CPE paltform remark.

Enumeration Type Documentation

CPE language operators.

Enumerator:
CPE_LANG_OPER_HALT 

end of instruction list

CPE_LANG_OPER_AND 

logical AND

CPE_LANG_OPER_OR 

logical OR

CPE_LANG_OPER_MATCH 

match against specified CPE

CPE_LANG_OPER_MASK 

mask to extract the operator w/o possible negation

CPE_LANG_OPER_NOT 

negate


Function Documentation

void cpe_platform_iterator_free ( struct cpe_platform_iterator it  )  [related, inherited]
bool cpe_platform_iterator_has_more ( struct cpe_platform_iterator it  )  [related, inherited]
struct cpe_platform * cpe_platform_iterator_next ( struct cpe_platform_iterator it  )  [related, inherited]
bool cpe_platform_match_cpe ( struct cpe_name **  cpe,
size_t  n,
const struct cpe_platform platform 
) [related, inherited]

Match list of CPEs against CPE language platform specification.

Parameters:
cpe List of CPEs describing tested platform as a list of pointers
n number of CPEs
platform CPE language platform, that is expected (not) to match given list of CPEs
Returns:
result of expression evaluation
void cpe_platformspec_free ( struct cpe_platformspec platformspec  )  [related, inherited]

Free specified platform specification list.

Parameters:
platformspec pointer to list to be deleted
struct cpe_platform * cpe_platformspec_get_item ( const struct cpe_platformspec platformspec,
const char *  id 
) [related, inherited]

Get platform with given ID.

Parameters:
platformspec Used platform specfication.
id Desired platform ID. Platform with given ID.
Return values:
NULL on failure (e.g. no such platform exists)
struct cpe_platformspec * cpe_platformspec_new ( const char *  fname  )  [related, inherited]

New platform specification from file.

Parameters:
fname file name to load
Returns:
new platform specification list
Return values:
NULL on failure

Generated on 29 Sep 2009 for Open SCAP Library by  doxygen 1.6.1