netfilter
firewalling, NAT, and packet mangling for linux
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
Conntrack labels

Functions

const char * nfct_labelmap_get_name (struct nfct_labelmap *m, unsigned int bit)
 nfct_labelmap_get_name - get name of the label bit More...
 
int nfct_labelmap_get_bit (struct nfct_labelmap *m, const char *name)
 nfct_labelmap_get_bit - get bit associated with the name More...
 
struct nfct_labelmapnfct_labelmap_new (const char *mapfile)
 nfct_labelmap_new - create a new label map More...
 
void nfct_labelmap_destroy (struct nfct_labelmap *map)
 nfct_labelmap_destroy - destroy nfct_labelmap object More...
 

Detailed Description

Function Documentation

void nfct_labelmap_destroy ( struct nfct_labelmap map)

nfct_labelmap_destroy - destroy nfct_labelmap object

Parameters
mapthe label object to destroy.

This function releases the memory that is used by the labelmap object.

References __labelmap_destroy().

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

int nfct_labelmap_get_bit ( struct nfct_labelmap m,
const char *  name 
)

nfct_labelmap_get_bit - get bit associated with the name

Parameters
hlabel handle obtained from nfct_labelmap_new
namename of the label

returns the bit associated with the name, or negative value on error.

References __labelmap_get_bit().

Here is the call graph for this function:

const char* nfct_labelmap_get_name ( struct nfct_labelmap m,
unsigned int  bit 
)

nfct_labelmap_get_name - get name of the label bit

Parameters
mlabel map obtained from nfct_label_open
bitwhose name should be returned

returns a pointer to the name associated with the label. If no name has been configured, the empty string is returned. If bit is out of range, NULL is returned.

References __labelmap_get_name().

Referenced by __snprintf_connlabels().

Here is the call graph for this function:

Here is the caller graph for this function:

struct nfct_labelmap* nfct_labelmap_new ( const char *  mapfile)

nfct_labelmap_new - create a new label map

Parameters
mapfilethe file containing the bit <-> name mapping

If mapfile is NULL, the default mapping file is used. returns a new label map, or NULL on error.

References __labelmap_new().

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function: