netfilter
firewalling, NAT, and packet mangling for linux
 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Modules Pages
nftables.h File Reference
#include <stdbool.h>
#include <stdarg.h>
#include <utils.h>
Include dependency graph for nftables.h:
This graph shows which files directly or indirectly include this file:

Data Structures

struct  location
 
struct  input_descriptor
 

Macros

#define INCLUDE_PATHS_MAX   16
 

Enumerations

enum  numeric_level {
  NUMERIC_NONE,
  NUMERIC_ADDR,
  NUMERIC_PORT,
  NUMERIC_ALL
}
 
enum  debug_level {
  DEBUG_SCANNER = 0x1,
  DEBUG_PARSER = 0x2,
  DEBUG_EVALUATION = 0x4,
  DEBUG_NETLINK = 0x8,
  DEBUG_MNL = 0x10,
  DEBUG_PROTO_CTX = 0x20,
  DEBUG_SEGTREE = 0x40
}
 
enum  nftables_exit_codes {
  NFT_EXIT_SUCCESS = 0,
  NFT_EXIT_FAILURE = 1,
  NFT_EXIT_NOMEM = 2,
  NFT_EXIT_NONL = 3
}
 
enum  input_descriptor_types {
  INDESC_INVALID,
  INDESC_INTERNAL,
  INDESC_BUFFER,
  INDESC_FILE,
  INDESC_CLI,
  INDESC_NETLINK
}
 enum input_descriptor_types More...
 

Functions

: name describing the input

struct input_descriptor

: location, used for include statements : input descriptor type

int nft_run (void *scanner, struct parser_state *state, struct list_head *msgs)
 

Variables

unsigned int max_errors
 
unsigned int numeric_output
 
unsigned int ip2name_output
 
unsigned int handle_output
 
unsigned int debug_level
 
const char * include_paths [INCLUDE_PATHS_MAX]
 
const struct location internal_location
 

Macro Definition Documentation

#define INCLUDE_PATHS_MAX   16

Referenced by main().

Enumeration Type Documentation

Enumerator
DEBUG_SCANNER 
DEBUG_PARSER 
DEBUG_EVALUATION 
DEBUG_NETLINK 
DEBUG_MNL 
DEBUG_PROTO_CTX 
DEBUG_SEGTREE 

enum input_descriptor_types

: invalid : dummy type for internally generated messages : buffer (command line arguments) : file : command line interface : received from netlink

Enumerator
INDESC_INVALID 
INDESC_INTERNAL 
INDESC_BUFFER 
INDESC_FILE 
INDESC_CLI 
INDESC_NETLINK 
Enumerator
NFT_EXIT_SUCCESS 
NFT_EXIT_FAILURE 
NFT_EXIT_NOMEM 
NFT_EXIT_NONL 
Enumerator
NUMERIC_NONE 
NUMERIC_ADDR 
NUMERIC_PORT 
NUMERIC_ALL 

Function Documentation

int nft_run ( void *  scanner,
struct parser_state state,
struct list_head msgs 
)

References cmd_free(), parser_state::cmds, cmd::list, list_for_each_entry_safe, parser_state::nerrs, netlink_restart(), and nft_parse().

Referenced by main().

Here is the call graph for this function:

Here is the caller graph for this function:

Variable Documentation

unsigned int handle_output

Referenced by main(), and rule_print().

const char* include_paths[INCLUDE_PATHS_MAX]

Referenced by main().

const struct location internal_location

Referenced by main(), and payload_expr_join().

unsigned int ip2name_output

Referenced by main().

unsigned int max_errors
unsigned int numeric_output

Referenced by main().