The Netsukuku Project  0.0.9
An Alternative routing method
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Macros
iptables.h File Reference
#include "iptables_common.h"
#include "libiptc/libiptc.h"
Include dependency graph for iptables.h:

Go to the source code of this file.

Data Structures

struct  ipt_get_revision
 
struct  iptables_rule_match
 
struct  iptables_match
 
struct  iptables_target
 

Macros

#define IPT_LIB_DIR   "/usr/local/lib/iptables"
 
#define IPPROTO_SCTP   132
 
#define IPT_SO_GET_REVISION_MATCH   (IPT_BASE_CTL + 2)
 
#define IPT_SO_GET_REVISION_TARGET   (IPT_BASE_CTL + 3)
 
#define LINUX_VERSION(x, y, z)   (0x10000*(x) + 0x100*(y) + z)
 
#define LINUX_VERSION_MAJOR(x)   (((x)>>16) & 0xFF)
 
#define LINUX_VERSION_MINOR(x)   (((x)>> 8) & 0xFF)
 
#define LINUX_VERSION_PATCH(x)   ( (x) & 0xFF)
 

Enumerations

enum  ipt_tryload { DONT_LOAD, TRY_LOAD, LOAD_MUST_SUCCEED }
 

Functions

void register_match (struct iptables_match *me)
 
void register_target (struct iptables_target *me)
 
struct in_addr * dotted_to_addr (const char *dotted)
 
char * addr_to_dotted (const struct in_addr *addrp)
 
char * addr_to_anyname (const struct in_addr *addr)
 
char * mask_to_dotted (const struct in_addr *mask)
 
void parse_hostnetworkmask (const char *name, struct in_addr **addrpp, struct in_addr *maskp, unsigned int *naddrs)
 
u_int16_t parse_protocol (const char *s)
 
void parse_interface (const char *arg, char *vianame, unsigned char *mask)
 
int do_command (int argc, char *argv[], char **table, iptc_handle_t *handle)
 
struct iptables_targetfind_target (const char *name, enum ipt_tryload)
 
struct iptables_matchfind_match (const char *name, enum ipt_tryload, struct iptables_rule_match **match)
 
int delete_chain (const ipt_chainlabel chain, int verbose, iptc_handle_t *handle)
 
int flush_entries (const ipt_chainlabel chain, int verbose, iptc_handle_t *handle)
 
int for_each_chain (int(*fn)(const ipt_chainlabel, int, iptc_handle_t *), int verbose, int builtinstoo, iptc_handle_t *handle)
 
void get_kernel_version (void)
 

Variables

int line
 
struct iptables_matchiptables_matches
 
struct iptables_targetiptables_targets
 
int kernel_version
 

Macro Definition Documentation

#define IPPROTO_SCTP   132
#define IPT_LIB_DIR   "/usr/local/lib/iptables"
#define IPT_SO_GET_REVISION_MATCH   (IPT_BASE_CTL + 2)
#define IPT_SO_GET_REVISION_TARGET   (IPT_BASE_CTL + 3)
#define LINUX_VERSION (   x,
  y,
 
)    (0x10000*(x) + 0x100*(y) + z)
#define LINUX_VERSION_MAJOR (   x)    (((x)>>16) & 0xFF)
#define LINUX_VERSION_MINOR (   x)    (((x)>> 8) & 0xFF)
#define LINUX_VERSION_PATCH (   x)    ( (x) & 0xFF)

Enumeration Type Documentation

Enumerator
DONT_LOAD 
TRY_LOAD 
LOAD_MUST_SUCCEED 

Function Documentation

char* addr_to_anyname ( const struct in_addr *  addr)
char* addr_to_dotted ( const struct in_addr *  addrp)
int delete_chain ( const ipt_chainlabel  chain,
int  verbose,
iptc_handle_t handle 
)
int do_command ( int  argc,
char *  argv[],
char **  table,
iptc_handle_t handle 
)
struct in_addr* dotted_to_addr ( const char *  dotted)
struct iptables_match* find_match ( const char *  name,
enum  ipt_tryload,
struct iptables_rule_match **  match 
)
struct iptables_target* find_target ( const char *  name,
enum  ipt_tryload 
)
int flush_entries ( const ipt_chainlabel  chain,
int  verbose,
iptc_handle_t handle 
)
int for_each_chain ( int(*)(const ipt_chainlabel, int, iptc_handle_t *)  fn,
int  verbose,
int  builtinstoo,
iptc_handle_t handle 
)
void get_kernel_version ( void  )
char* mask_to_dotted ( const struct in_addr *  mask)
void parse_hostnetworkmask ( const char *  name,
struct in_addr **  addrpp,
struct in_addr *  maskp,
unsigned int *  naddrs 
)
void parse_interface ( const char *  arg,
char *  vianame,
unsigned char *  mask 
)
u_int16_t parse_protocol ( const char *  s)
void register_match ( struct iptables_match me)
void register_target ( struct iptables_target me)

Variable Documentation

struct iptables_match* iptables_matches
struct iptables_target* iptables_targets
int kernel_version
int line