{ }
};
+enum fw3_zone_logmask {
+ FW3_ZONE_LOG_FILTER = (1 << 0),
+ FW3_ZONE_LOG_MANGLE = (1 << 1),
+};
+
const struct fw3_option fw3_zone_opts[] = {
FW3_OPT("enabled", bool, zone, enabled),
FW3_OPT("mtu_fix", bool, zone, mtu_fix),
FW3_OPT("custom_chains", bool, zone, custom_chains),
- FW3_OPT("log", bool, zone, log),
+ FW3_OPT("log", int, zone, log),
FW3_OPT("log_limit", limit, zone, log_limit),
FW3_OPT("auto_helper", bool, zone, auto_helper),
{
if (zone->mtu_fix)
{
- if (zone->log)
+ if (zone->log & FW3_ZONE_LOG_MANGLE)
{
snprintf(buf, sizeof(buf) - 1, "MSSFIX(%s): ", zone->name);
fw3_flag_names[zone->policy_output]);
fw3_ipt_rule_append(r, "zone_%s_output", zone->name);
- if (zone->log)
+ if (zone->log & FW3_ZONE_LOG_FILTER)
{
for (t = FW3_FLAG_REJECT; t <= FW3_FLAG_DROP; t++)
{