#include <getopt.h>
#include <string.h>
#include <netdb.h>
#include <errno.h>
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <ctype.h>
#include <stdarg.h>
#include <limits.h>
#include <unistd.h>
#include <iptables.h>
#include <xtables.h>
#include <fcntl.h>
#include "xshared.h"
#include "nft-shared.h"
#include "nft.h"
Macros | |
#define | TRUE 1 |
#define | FALSE 0 |
#define | NUMBER_OF_CMD 16 |
#define | OPT_FRAGMENT 0x00800U |
#define | NUMBER_OF_OPT ARRAY_SIZE(optflags) |
#define | opts xtables_globals.opts |
#define | prog_name xtables_globals.program_name |
#define | prog_vers xtables_globals.program_version |
Functions | |
void | xtables_exit_error (enum xtables_exittype status, const char *msg,...) __attribute__((noreturn |
void | format (printf, 2, 3))) |
int | do_commandx (struct nft_handle *h, int argc, char *argv[], char **table, bool restore) |
Variables | |
struct xtables_globals | xtables_globals |
#define FALSE 0 |
Referenced by do_commandx().
#define NUMBER_OF_CMD 16 |
#define NUMBER_OF_OPT ARRAY_SIZE(optflags) |
#define OPT_FRAGMENT 0x00800U |
Referenced by do_commandx().
#define opts xtables_globals.opts |
Referenced by do_commandx().
#define prog_name xtables_globals.program_name |
Referenced by do_commandx(), and xtables_exit_error().
#define prog_vers xtables_globals.program_version |
Referenced by do_commandx(), and xtables_exit_error().
#define TRUE 1 |
Referenced by do_commandx().
int do_commandx | ( | struct nft_handle * | h, |
int | argc, | ||
char * | argv[], | ||
char ** | table, | ||
bool | restore | ||
) |
References addr_mask::addr, iptables_command_state::argv, xtables_args::bcnt, xtables_args::bcnt_cnt, iptables_command_state::c, CMD_APPEND, CMD_CHECK, CMD_DELETE, CMD_DELETE_CHAIN, CMD_DELETE_NUM, CMD_FLUSH, CMD_INSERT, CMD_LIST, CMD_LIST_RULES, CMD_NEW_CHAIN, CMD_NONE, CMD_RENAME_CHAIN, CMD_REPLACE, CMD_SET_POLICY, CMD_ZERO, CMD_ZERO_NUM, command_default(), xtables_args::d, xtables_args::dhostnetworkmask, exit_printhelp(), exit_tryhelp(), FALSE, nft_handle::family, xtables_args::family, xtables_args::flags, generic_opt_check(), xtables_args::goto_set, xtables_args::iniface, xtables_args::iniface_mask, iptables_command_state::invert, xtables_args::invflags, IPT_F_FRAG, iptables_command_state::jumpto, xtables_match::m, addr_mask::mask, xtables_rule_match::match, iptables_command_state::matches, xtables_match::mflags, addr_mask::naddrs, xtables_match::next, xtables_target::next, xtables_rule_match::next, nft_chain_set(), nft_chain_user_add(), nft_chain_user_del(), nft_chain_user_rename(), nft_chain_zero_counters(), nft_family_ops_lookup(), nft_rule_delete_num(), nft_rule_flush(), nft_rule_zero_counters(), NULL, nft_handle::ops, OPT_COUNTERS, OPT_DESTINATION, OPT_EXPANDED, OPT_FRAGMENT, OPT_JUMP, OPT_LINENUMBERS, OPT_NUMERIC, OPT_PROTOCOL, OPT_SOURCE, OPT_VERBOSE, OPT_VIANAMEIN, OPT_VIANAMEOUT, iptables_command_state::options, opts, xtables_globals::orig_opts, xtables_args::outiface, xtables_args::outiface_mask, PARAMETER_PROBLEM, xtables_args::pcnt, xtables_args::pcnt_cnt, nft_family_ops::post_parse, prog_name, prog_vers, xtables_args::proto, nft_family_ops::proto_parse, iptables_command_state::protocol, xtables_args::shostnetworkmask, xtables_target::t, iptables_command_state::target, xtables_target::tflags, TRUE, xtables_target::used, addr_mask::v4, addr_mask::v6, XT_EXTENSION_MAXNAMELEN, XT_INV_PROTO, xt_params, xtables_error, xtables_find_match(), xtables_find_target(), xtables_free_opts(), xtables_matches, xtables_modprobe_program, xtables_option_mfcall(), xtables_option_tfcall(), xtables_parse_interface(), xtables_parse_protocol(), xtables_rule_matches_free(), xtables_set_nfproto(), xtables_targets, and XTF_TRY_LOAD.
void format | ( | printf | , |
2 | , | ||
3 | |||
) |
void xtables_exit_error | ( | enum xtables_exittype | status, |
const char * | msg, | ||
... | |||
) |
References exit_tryhelp(), PARAMETER_PROBLEM, prog_name, prog_vers, VERSION_PROBLEM, and xtables_free_opts().