1
0
mirror of https://github.com/fwbuilder/fwbuilder synced 2026-03-23 19:57:21 +01:00

* ActionsDialog.cpp (setRule): see #1871 "PF Actions Tag and

Classify can be terminating or non-terminating". Added checkbox to
the action properties dialog for actions Tag and Classify for PF
that lets the user choose if these actions should be terminating
or not. Old behavior (Tag was non-terminating and Classify was
terminating) is reflected in default settings of the checkboxes.
Terminating rules generate "pass quick" commands, while
non-terminating rules generate "pass" commands (no "quick" option).
This commit is contained in:
Vadim Kurland 2011-02-15 14:20:27 -08:00
parent bee424b3d0
commit 0df4ae9abd
9 changed files with 624 additions and 458 deletions

View File

@ -1,3 +1,14 @@
2011-02-15 vadim <vadim@netcitadel.com>
* ActionsDialog.cpp (setRule): see #1871 "PF Actions Tag and
Classify can be terminating or non-terminating". Added checkbox to
the action properties dialog for actions Tag and Classify for PF
that lets the user choose if these actions should be terminating
or not. Old behavior (Tag was non-terminating and Classify was
terminating) is reflected in default settings of the checkboxes.
Terminating rules generate "pass quick" commands, while
non-terminating rules generate "pass" commands (no "quick" option).
2011-02-14 vadim <vadim@netcitadel.com>
* OSConfigurator_bsd_interfaces.cpp (configureInterfaces): fixes

View File

@ -185,14 +185,14 @@ void ActionsDialog::applyChanges()
Rule *rule = Rule::cast(new_state);
PolicyRule *policy_rule = PolicyRule::cast(new_state);
if (editor=="TagInt")
if (editor=="TagIptables")
{
FWObject *tag_object = m_dialog->iptTagDropArea->getObject();
// if tag_object==NULL, setTagObject clears setting in the rule
policy_rule->setTagObject(tag_object);
}
if (editor=="TagStr")
if (editor=="TagPF")
{
FWObject *tag_object = m_dialog->pfTagDropArea->getObject();
// if tag_object==NULL, setTagObject clears setting in the rule
@ -294,6 +294,21 @@ void ActionsDialog::setRule(Rule *r)
m_dialog->useDummyNetQueue->setChecked(1);
}
// as of 4.2.0 build 3477 we provide checkboxes to make Tag and
// Classify actions (PF) terminating or non-terminating on
// per-rule basis. Old behavior: Tag was non-terminating and
// Classify was terminating. Set options accordingly if they are
// not set.
if (platform=="pf")
{
string pf_tag_terminating = ropt->getStr("pf_tag_terminating");
if (pf_tag_terminating.empty())
ropt->setBool("pf_tag_terminating", false);
string pf_classify_terminating = ropt->getStr("pf_classify_terminating");
if (pf_classify_terminating.empty())
ropt->setBool("pf_classify_terminating", true);
}
if (platform=="iptables")
{
m_dialog->classify_terminating->show();
@ -325,6 +340,9 @@ void ActionsDialog::setRule(Rule *r)
data.registerOption(m_dialog->ipt_mark_connections, ropt,
"ipt_mark_connections");
data.registerOption(m_dialog->pf_tag_terminating, ropt, "pf_tag_terminating");
// data.registerOption(ipt_mark_prerouting, ropt, "ipt_mark_prerouting");
data.registerOption(m_dialog->accountingvalue_str, ropt,
"rule_name_accounting");
@ -333,6 +351,10 @@ void ActionsDialog::setRule(Rule *r)
data.registerOption(m_dialog->classify_str, ropt, "classify_str");
data.registerOption(m_dialog->custom_str, ropt, "custom_str");
data.registerOption(m_dialog->pf_classify_str, ropt, "pf_classify_str");
data.registerOption(m_dialog->pf_classify_terminating, ropt,
"pf_classify_terminating");
// ROUTE action:
// build a map for combobox so visible combobox items can be localized
@ -370,39 +392,43 @@ void ActionsDialog::setRule(Rule *r)
{
w=m_dialog->RejectPage;
}
else if (editor=="TagInt")
else if (editor=="TagIptables")
{
w=m_dialog->TagIntPage;
w = m_dialog->TagIptables;
FWObject *o = policy_rule->getTagObject();
m_dialog->iptTagDropArea->setObject(o);
m_dialog->iptTagDropArea->update();
}
else if (editor=="TagStr")
else if (editor=="TagPF")
{
w=m_dialog->TagStrPage;
w = m_dialog->TagPF;
FWObject *o = policy_rule->getTagObject();
m_dialog->pfTagDropArea->setObject(o);
m_dialog->pfTagDropArea->update();
}
else if (editor=="AccountingStr")
{
w=m_dialog->AccountingStrPage;
w = m_dialog->AccountingStrPage;
}
else if (editor=="ClassifyArgsIPFW")
{
w=m_dialog->ClassifyArgsIPFW;
w = m_dialog->ClassifyArgsIPFW;
}
else if (editor=="PipeArgsIPFW")
{
w=m_dialog->PipeArgsIPFW;
w = m_dialog->PipeArgsIPFW;
}
else if (editor=="ClassifyStr")
else if (editor=="ClassifyIptables")
{
w=m_dialog->ClassifyStrPage;
w = m_dialog->ClassifyIptables;
}
else if (editor=="ClassifyPF")
{
w = m_dialog->ClassifyPF;
}
else if (editor=="CustomStr")
{
w=m_dialog->CustomStrPage;
w = m_dialog->CustomStrPage;
}
else if (editor=="BranchChain")
{

View File

@ -980,7 +980,10 @@ QString FWObjectPropertiesFactory::getRuleActionProperties(Rule *rule)
par = par + " " + ropt->getStr("ipfw_pipe_queue_num").c_str();
} else
{
par = ropt->getStr("classify_str").c_str();
if (platform=="pf")
par = ropt->getStr("pf_classify_str").c_str();
else
par = ropt->getStr("classify_str").c_str();
}
break;
case PolicyRule::Pipe :
@ -1063,7 +1066,7 @@ QString FWObjectPropertiesFactory::getRuleActionPropertiesRich(Rule *rule)
QString res = QObject::tr("<b>Action :</b> %1<br>").arg(act);
if (!par.isEmpty())
{
res += QObject::tr("<b>Parameter:</b> ")+par;
res += QObject::tr("<b>Parameter:</b> %1").arg(par);
}
return res;
}

View File

@ -1,7 +1,8 @@
<ui version="4.0" >
<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>ActionsDialog_q</class>
<widget class="QWidget" name="ActionsDialog_q" >
<property name="geometry" >
<widget class="QWidget" name="ActionsDialog_q">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
@ -9,78 +10,82 @@
<height>229</height>
</rect>
</property>
<property name="windowTitle" >
<property name="windowTitle">
<string>Actions Dialog</string>
</property>
<layout class="QGridLayout" name="gridLayout" >
<item row="0" column="0" >
<widget class="QFrame" name="frame4" >
<property name="frameShape" >
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QFrame" name="frame4">
<property name="frameShape">
<enum>QFrame::Box</enum>
</property>
<property name="frameShadow" >
<property name="frameShadow">
<enum>QFrame::Sunken</enum>
</property>
<layout class="QGridLayout" >
<item row="0" column="0" >
<widget class="QStackedWidget" name="widgetStack" >
<property name="minimumSize" >
<layout class="QGridLayout">
<item row="0" column="0">
<widget class="QStackedWidget" name="widgetStack">
<property name="minimumSize">
<size>
<width>320</width>
<height>0</height>
</size>
</property>
<property name="frameShape" >
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="frameShadow" >
<property name="frameShadow">
<enum>QFrame::Plain</enum>
</property>
<property name="currentIndex" >
<number>7</number>
<property name="currentIndex">
<number>8</number>
</property>
<widget class="QWidget" name="TagStrPage" >
<layout class="QGridLayout" >
<property name="spacing" >
<number>12</number>
</property>
<item row="0" column="0" colspan="2" >
<widget class="QLabel" name="textLabel4" >
<property name="text" >
<widget class="QWidget" name="TagPF">
<layout class="QGridLayout" name="gridLayout_3">
<item row="0" column="0">
<widget class="QLabel" name="textLabel4">
<property name="text">
<string>Tag service object:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="0" >
<widget class="FWObjectDropArea" native="1" name="pfTagDropArea" >
<property name="sizePolicy" >
<sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
<item row="1" column="0">
<widget class="FWObjectDropArea" name="pfTagDropArea" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize" >
<property name="minimumSize">
<size>
<width>100</width>
<height>80</height>
</size>
</property>
<property name="font" >
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
</widget>
</item>
<item row="1" column="1" >
<item row="1" column="1">
<widget class="QCheckBox" name="pf_tag_terminating">
<property name="text">
<string>Make this rule terminating</string>
</property>
</widget>
</item>
<item row="1" column="2">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>691</width>
<height>58</height>
@ -88,15 +93,15 @@
</property>
</spacer>
</item>
<item row="2" column="0" colspan="2" >
<item row="2" column="0" colspan="3">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -106,36 +111,36 @@
</item>
</layout>
</widget>
<widget class="QWidget" name="RejectPage" >
<layout class="QGridLayout" >
<property name="margin" >
<widget class="QWidget" name="RejectPage">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="1" column="0" colspan="3" >
<widget class="QLabel" name="textLabel3" >
<property name="text" >
<item row="1" column="0" colspan="3">
<widget class="QLabel" name="textLabel3">
<property name="text">
<string>If rule action is 'Reject', this option defines firewall's reaction to the packet matching the rule</string>
</property>
<property name="alignment" >
<property name="alignment">
<set>Qt::AlignVCenter</set>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="3" column="1" >
<item row="3" column="1">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -143,9 +148,9 @@
</property>
</spacer>
</item>
<item row="2" column="1" >
<widget class="QComboBox" name="rejectvalue" >
<property name="minimumSize" >
<item row="2" column="1">
<widget class="QComboBox" name="rejectvalue">
<property name="minimumSize">
<size>
<width>300</width>
<height>0</height>
@ -153,15 +158,15 @@
</property>
</widget>
</item>
<item row="2" column="0" >
<item row="2" column="0">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>10</width>
<height>20</height>
@ -169,15 +174,15 @@
</property>
</spacer>
</item>
<item row="2" column="2" >
<item row="2" column="2">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>0</width>
<height>20</height>
@ -187,53 +192,53 @@
</item>
</layout>
</widget>
<widget class="QWidget" name="NonePage" >
<layout class="QGridLayout" >
<property name="margin" >
<widget class="QWidget" name="NonePage">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" >
<widget class="QLabel" name="textLabel5" >
<property name="text" >
<item row="0" column="0">
<widget class="QLabel" name="textLabel5">
<property name="text">
<string>This action has no parameters.</string>
</property>
<property name="alignment" >
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="TagIntPage" >
<layout class="QGridLayout" >
<property name="spacing" >
<widget class="QWidget" name="TagIptables">
<layout class="QGridLayout">
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" colspan="2" >
<widget class="QLabel" name="textLabel4_2" >
<property name="text" >
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="textLabel4_2">
<property name="text">
<string>Tag service object:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item rowspan="3" row="0" column="2" >
<item row="0" column="2" rowspan="3">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>201</width>
<height>81</height>
@ -241,67 +246,67 @@
</property>
</spacer>
</item>
<item rowspan="3" row="1" column="0" >
<widget class="FWObjectDropArea" native="1" name="iptTagDropArea" >
<property name="sizePolicy" >
<sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
<item row="1" column="0" rowspan="3">
<widget class="FWObjectDropArea" name="iptTagDropArea" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize" >
<property name="minimumSize">
<size>
<width>100</width>
<height>80</height>
</size>
</property>
<property name="font" >
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
</widget>
</item>
<item row="1" column="1" >
<widget class="QCheckBox" name="ipt_mark_connections" >
<property name="toolTip" >
<item row="1" column="1">
<widget class="QCheckBox" name="ipt_mark_connections">
<property name="toolTip">
<string>Requires CONNMARK target</string>
</property>
<property name="text" >
<property name="text">
<string>Tag connections created by packets that match this rule</string>
</property>
</widget>
</item>
<item row="2" column="1" >
<widget class="QLabel" name="tag_terminating" >
<property name="toolTip" >
<item row="2" column="1">
<widget class="QLabel" name="tag_terminating">
<property name="toolTip">
<string>Note: this action translates into MARK target for iptables.
Normally this target is non-terminating, that is, other rules
with Classify or Tag actions below this one will process
the same packet. However, Firewall Builder can emulate
terminating behavior for this action. Option in the "compiler"
terminating behavior for this action. Option in the &quot;compiler&quot;
tab of the firewall object properties dialog activates emulation.</string>
</property>
<property name="text" >
<property name="text">
<string>Emulation of terminating behavior for MARK target is currently ON, the rule will be terminating</string>
</property>
<property name="alignment" >
<property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignVCenter</set>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="4" column="0" colspan="3" >
<item row="4" column="0" colspan="3">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>609</width>
<height>21</height>
@ -311,39 +316,39 @@ tab of the firewall object properties dialog activates emulation.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="AccountingStrPage" >
<layout class="QGridLayout" >
<property name="margin" >
<widget class="QWidget" name="AccountingStrPage">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="1" column="0" >
<widget class="QLabel" name="textLabel1_4" >
<property name="text" >
<item row="1" column="0">
<widget class="QLabel" name="textLabel1_4">
<property name="text">
<string>Rule name for accounting. (white spaces and special characters are not allowed)</string>
</property>
<property name="alignment" >
<property name="alignment">
<set>Qt::AlignVCenter</set>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="2" column="0" >
<widget class="QLineEdit" name="accountingvalue_str" />
<item row="2" column="0">
<widget class="QLineEdit" name="accountingvalue_str"/>
</item>
<item row="3" column="0" >
<item row="3" column="0">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -353,49 +358,49 @@ tab of the firewall object properties dialog activates emulation.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="ClassifyArgsIPFW" >
<layout class="QGridLayout" >
<property name="margin" >
<widget class="QWidget" name="ClassifyArgsIPFW">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" colspan="3" >
<widget class="QLabel" name="textLabel1" >
<property name="text" >
<item row="0" column="0" colspan="3">
<widget class="QLabel" name="textLabel1">
<property name="text">
<string>Packet classification can be implemented in different ways:</string>
</property>
<property name="alignment" >
<property name="alignment">
<set>Qt::AlignVCenter</set>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>true</bool>
</property>
</widget>
</item>
<item row="1" column="0" colspan="3" >
<widget class="QGroupBox" name="buttonGroup1" >
<property name="title" >
<item row="1" column="0" colspan="3">
<widget class="QGroupBox" name="buttonGroup1">
<property name="title">
<string/>
</property>
<layout class="QGridLayout" >
<property name="margin" >
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="1" column="0" >
<widget class="QRadioButton" name="useDummyNetPipe" >
<property name="text" >
<item row="1" column="0">
<widget class="QRadioButton" name="useDummyNetPipe">
<property name="text">
<string>use dummynet(4) 'pipe'</string>
</property>
</widget>
</item>
<item row="2" column="0" >
<widget class="QRadioButton" name="useDummyNetQueue" >
<property name="text" >
<item row="2" column="0">
<widget class="QRadioButton" name="useDummyNetQueue">
<property name="text">
<string>use dummynet(4) 'queue'</string>
</property>
</widget>
@ -403,25 +408,25 @@ tab of the firewall object properties dialog activates emulation.</string>
</layout>
</widget>
</item>
<item row="2" column="0" >
<widget class="QLabel" name="textLabel2_2" >
<property name="text" >
<item row="2" column="0">
<widget class="QLabel" name="textLabel2_2">
<property name="text">
<string>Pipe or queue number:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="2" column="2" >
<item row="2" column="2">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
@ -429,28 +434,28 @@ tab of the firewall object properties dialog activates emulation.</string>
</property>
</spacer>
</item>
<item row="2" column="1" >
<widget class="QSpinBox" name="usePortNum" >
<property name="minimumSize" >
<item row="2" column="1">
<widget class="QSpinBox" name="usePortNum">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximum" >
<property name="maximum">
<number>999999</number>
</property>
</widget>
</item>
<item row="3" column="1" >
<item row="3" column="1">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -460,36 +465,36 @@ tab of the firewall object properties dialog activates emulation.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="CustomStrPage" >
<layout class="QVBoxLayout" >
<property name="spacing" >
<widget class="QWidget" name="CustomStrPage">
<layout class="QVBoxLayout">
<property name="spacing">
<number>12</number>
</property>
<property name="margin" >
<property name="margin">
<number>12</number>
</property>
<item>
<widget class="QLabel" name="textLabel1_2" >
<property name="text" >
<widget class="QLabel" name="textLabel1_2">
<property name="text">
<string>Custom string:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="custom_str" />
<widget class="QLineEdit" name="custom_str"/>
</item>
<item>
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -499,36 +504,36 @@ tab of the firewall object properties dialog activates emulation.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="ClassifyStrPage" >
<layout class="QGridLayout" >
<property name="margin" >
<widget class="QWidget" name="ClassifyIptables">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" >
<widget class="QLabel" name="textLabel2_3" >
<property name="text" >
<item row="0" column="0">
<widget class="QLabel" name="textLabel2_3">
<property name="text">
<string>Classify string:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="0" >
<widget class="QLineEdit" name="classify_str" />
<item row="1" column="0">
<widget class="QLineEdit" name="classify_str"/>
</item>
<item row="4" column="0" >
<item row="4" column="0">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -536,57 +541,94 @@ tab of the firewall object properties dialog activates emulation.</string>
</property>
</spacer>
</item>
<item row="3" column="0" >
<widget class="QLabel" name="classify_terminating" >
<property name="toolTip" >
<item row="3" column="0">
<widget class="QLabel" name="classify_terminating">
<property name="toolTip">
<string>Note: CLASSIFY target in iptables is non-terminating,
this means other rules with Classify or Branch
target below this one will process the same packet.
However, Firewall Builder can emulate terminating
behavior for this action. Emulation is activated
by an option in the "compiler" tab of the firewall
by an option in the &quot;compiler&quot; tab of the firewall
object properties dialog.</string>
</property>
<property name="text" >
<property name="text">
<string>Emulation is currently ON, rule will be terminating</string>
</property>
<property name="alignment" >
<property name="alignment">
<set>Qt::AlignCenter</set>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="PipeArgsIPFW" >
<layout class="QGridLayout" >
<property name="margin" >
<number>12</number>
</property>
<property name="spacing" >
<number>12</number>
</property>
<item row="1" column="0" >
<widget class="QLabel" name="textLabel2_2_2" >
<property name="text" >
<string>Divert socket port number:</string>
<widget class="QWidget" name="ClassifyPF">
<layout class="QGridLayout" name="gridLayout_4">
<item row="0" column="0">
<widget class="QLabel" name="textLabel2_6">
<property name="text">
<string>Classify string:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="2" >
<item row="1" column="0">
<widget class="QLineEdit" name="pf_classify_str"/>
</item>
<item row="2" column="0">
<widget class="QCheckBox" name="pf_classify_terminating">
<property name="text">
<string>Make this rule terminating</string>
</property>
</widget>
</item>
<item row="3" column="0">
<spacer name="verticalSpacer_2">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>93</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="QWidget" name="PipeArgsIPFW">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing">
<number>12</number>
</property>
<item row="1" column="0">
<widget class="QLabel" name="textLabel2_2_2">
<property name="text">
<string>Divert socket port number:</string>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="2">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
@ -594,28 +636,28 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="1" column="1" >
<widget class="QSpinBox" name="divertPortNum" >
<property name="minimumSize" >
<item row="1" column="1">
<widget class="QSpinBox" name="divertPortNum">
<property name="minimumSize">
<size>
<width>80</width>
<height>0</height>
</size>
</property>
<property name="maximum" >
<property name="maximum">
<number>999999</number>
</property>
</widget>
</item>
<item row="2" column="0" >
<item row="2" column="0">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -625,55 +667,55 @@ object properties dialog.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="BranchChainPage" >
<layout class="QGridLayout" >
<property name="spacing" >
<widget class="QWidget" name="BranchChainPage">
<layout class="QGridLayout">
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" colspan="2" >
<widget class="QLabel" name="textLabel1_3" >
<property name="text" >
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="textLabel1_3">
<property name="text">
<string>Policy ruleset object:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="0" >
<widget class="FWObjectDropArea" native="1" name="iptBranchDropArea" >
<property name="sizePolicy" >
<sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
<item row="1" column="0">
<widget class="FWObjectDropArea" name="iptBranchDropArea" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize" >
<property name="minimumSize">
<size>
<width>100</width>
<height>80</height>
</size>
</property>
<property name="font" >
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
</widget>
</item>
<item row="1" column="1" >
<widget class="QCheckBox" name="ipt_branch_in_mangle" >
<property name="text" >
<item row="1" column="1">
<widget class="QCheckBox" name="ipt_branch_in_mangle">
<property name="text">
<string>In addition to 'filter', create branching rule in 'mangle' table as well</string>
</property>
</widget>
</item>
<item row="1" column="2" >
<item row="1" column="2">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>41</width>
<height>21</height>
@ -681,15 +723,15 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="2" column="1" >
<item row="2" column="1">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>30</width>
<height>20</height>
@ -699,48 +741,48 @@ object properties dialog.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="BranchAnchorPage" >
<layout class="QGridLayout" >
<property name="spacing" >
<widget class="QWidget" name="BranchAnchorPage">
<layout class="QGridLayout">
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" colspan="2" >
<widget class="QLabel" name="textLabel2_4" >
<property name="text" >
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="textLabel2_4">
<property name="text">
<string>Policy rule set object:</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="1" column="0" >
<widget class="FWObjectDropArea" native="1" name="pfBranchDropArea" >
<property name="sizePolicy" >
<sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
<item row="1" column="0">
<widget class="FWObjectDropArea" name="pfBranchDropArea" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize" >
<property name="minimumSize">
<size>
<width>100</width>
<height>80</height>
</size>
</property>
<property name="font" >
<property name="font">
<font>
<pointsize>9</pointsize>
</font>
</property>
</widget>
</item>
<item row="1" column="1" >
<item row="1" column="1">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>701</width>
<height>64</height>
@ -748,15 +790,15 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="2" column="0" colspan="2" >
<item row="2" column="0" colspan="2">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -766,23 +808,23 @@ object properties dialog.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="RouteIPFPage" >
<layout class="QGridLayout" >
<property name="margin" >
<widget class="QWidget" name="RouteIPFPage">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="2" column="0" >
<item row="2" column="0">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>0</height>
@ -790,144 +832,144 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="1" column="0" >
<layout class="QHBoxLayout" >
<property name="spacing" >
<item row="1" column="0">
<layout class="QHBoxLayout">
<property name="spacing">
<number>12</number>
</property>
<property name="margin" >
<property name="margin">
<number>12</number>
</property>
<item>
<widget class="QComboBox" name="ipf_route_option" >
<widget class="QComboBox" name="ipf_route_option">
<item>
<property name="text" >
<property name="text">
<string>Route through</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Route reply through</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Route a copy through</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QLabel" name="textLabel3_2" >
<property name="text" >
<widget class="QLabel" name="textLabel3_2">
<property name="text">
<string>interface</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="ipf_route_opt_if" />
<widget class="QComboBox" name="ipf_route_opt_if"/>
</item>
<item>
<widget class="QLabel" name="textLabel4_4" >
<property name="text" >
<widget class="QLabel" name="textLabel4_4">
<property name="text">
<string>next hop</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="ipf_route_opt_addr" />
<widget class="QLineEdit" name="ipf_route_opt_addr"/>
</item>
</layout>
</item>
</layout>
</widget>
<widget class="QWidget" name="RoutePFPage" >
<layout class="QGridLayout" >
<property name="spacing" >
<widget class="QWidget" name="RoutePFPage">
<layout class="QGridLayout">
<property name="spacing">
<number>12</number>
</property>
<item row="1" column="0" colspan="5" >
<layout class="QHBoxLayout" >
<property name="spacing" >
<item row="1" column="0" colspan="5">
<layout class="QHBoxLayout">
<property name="spacing">
<number>12</number>
</property>
<property name="margin" >
<property name="margin">
<number>12</number>
</property>
<item>
<widget class="QComboBox" name="pf_route_option" >
<widget class="QComboBox" name="pf_route_option">
<item>
<property name="text" >
<property name="text">
<string>None</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Route through</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Route reply through</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Route a copy through</string>
</property>
</item>
</widget>
</item>
<item>
<widget class="QLabel" name="textLabel1_5" >
<property name="text" >
<widget class="QLabel" name="textLabel1_5">
<property name="text">
<string>interface</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QComboBox" name="pf_route_opt_if" />
<widget class="QComboBox" name="pf_route_opt_if"/>
</item>
<item>
<widget class="QLabel" name="textLabel2_5" >
<property name="text" >
<widget class="QLabel" name="textLabel2_5">
<property name="text">
<string>next hop</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item>
<widget class="QLineEdit" name="pf_route_opt_addr" />
<widget class="QLineEdit" name="pf_route_opt_addr"/>
</item>
</layout>
</item>
<item row="2" column="0" >
<widget class="QCheckBox" name="pf_fastroute" >
<property name="text" >
<item row="2" column="0">
<widget class="QCheckBox" name="pf_fastroute">
<property name="text">
<string>Fastroute</string>
</property>
</widget>
</item>
<item row="2" column="1" >
<item row="2" column="1">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
@ -935,48 +977,48 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="2" column="2" >
<widget class="QLabel" name="label" >
<property name="text" >
<item row="2" column="2">
<widget class="QLabel" name="label">
<property name="text">
<string>Load Balancing:</string>
</property>
</widget>
</item>
<item row="2" column="3" >
<widget class="QComboBox" name="pf_route_load_option" >
<item row="2" column="3">
<widget class="QComboBox" name="pf_route_load_option">
<item>
<property name="text" >
<property name="text">
<string>None</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Bitmask</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Random</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Source Hash</string>
</property>
</item>
<item>
<property name="text" >
<property name="text">
<string>Round Robin</string>
</property>
</item>
</widget>
</item>
<item row="2" column="4" >
<item row="2" column="4">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>131</width>
<height>20</height>
@ -984,15 +1026,15 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="3" column="0" colspan="5" >
<item row="3" column="0" colspan="5">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::MinimumExpanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>553</width>
<height>0</height>
@ -1002,62 +1044,62 @@ object properties dialog.</string>
</item>
</layout>
</widget>
<widget class="QWidget" name="RouteIPTPage" >
<layout class="QGridLayout" >
<property name="margin" >
<widget class="QWidget" name="RouteIPTPage">
<layout class="QGridLayout">
<property name="margin">
<number>12</number>
</property>
<property name="spacing" >
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" >
<widget class="QLabel" name="textLabel4_3" >
<property name="text" >
<item row="0" column="0">
<widget class="QLabel" name="textLabel4_3">
<property name="text">
<string>Change inbound interface to</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="2" column="0" >
<widget class="QLabel" name="textLabel6" >
<property name="text" >
<item row="2" column="0">
<widget class="QLabel" name="textLabel6">
<property name="text">
<string>Route through gateway</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="2" column="1" colspan="3" >
<widget class="QLineEdit" name="ipt_gw" />
<item row="2" column="1" colspan="3">
<widget class="QLineEdit" name="ipt_gw"/>
</item>
<item row="1" column="0" >
<widget class="QLabel" name="textLabel5_2" >
<property name="text" >
<item row="1" column="0">
<widget class="QLabel" name="textLabel5_2">
<property name="text">
<string>Change outbound interface to</string>
</property>
<property name="wordWrap" >
<property name="wordWrap">
<bool>false</bool>
</property>
</widget>
</item>
<item row="0" column="1" colspan="2" >
<widget class="QComboBox" name="ipt_iif" />
<item row="0" column="1" colspan="2">
<widget class="QComboBox" name="ipt_iif"/>
</item>
<item row="1" column="1" colspan="2" >
<widget class="QComboBox" name="ipt_oif" />
<item row="1" column="1" colspan="2">
<widget class="QComboBox" name="ipt_oif"/>
</item>
<item row="0" column="3" >
<item row="0" column="3">
<spacer>
<property name="orientation" >
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeType" >
<property name="sizeType">
<enum>QSizePolicy::Expanding</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>170</width>
<height>20</height>
@ -1065,49 +1107,49 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="3" column="0" colspan="2" >
<widget class="QCheckBox" name="ipt_continue" >
<property name="text" >
<item row="3" column="0" colspan="2">
<widget class="QCheckBox" name="ipt_continue">
<property name="text">
<string>Continue packet inspection</string>
</property>
</widget>
</item>
<item row="3" column="2" colspan="2" >
<widget class="QCheckBox" name="ipt_tee" >
<property name="text" >
<item row="3" column="2" colspan="2">
<widget class="QCheckBox" name="ipt_tee">
<property name="text">
<string>Make a copy</string>
</property>
</widget>
</item>
</layout>
</widget>
<widget class="QWidget" name="NATBranchPage" >
<layout class="QGridLayout" name="gridLayout_2" >
<property name="spacing" >
<widget class="QWidget" name="NATBranchPage">
<layout class="QGridLayout" name="gridLayout_2">
<property name="spacing">
<number>12</number>
</property>
<item row="0" column="0" colspan="2" >
<widget class="QLabel" name="label_2" >
<property name="text" >
<item row="0" column="0" colspan="2">
<widget class="QLabel" name="label_2">
<property name="text">
<string>NAT Rule set object:</string>
</property>
</widget>
</item>
<item row="1" column="0" >
<widget class="FWObjectDropArea" native="1" name="natBranchDropArea" >
<property name="sizePolicy" >
<sizepolicy vsizetype="Fixed" hsizetype="Fixed" >
<item row="1" column="0">
<widget class="FWObjectDropArea" name="natBranchDropArea" native="true">
<property name="sizePolicy">
<sizepolicy hsizetype="Fixed" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize" >
<property name="minimumSize">
<size>
<width>100</width>
<height>80</height>
</size>
</property>
<property name="maximumSize" >
<property name="maximumSize">
<size>
<width>100</width>
<height>80</height>
@ -1115,12 +1157,12 @@ object properties dialog.</string>
</property>
</widget>
</item>
<item row="1" column="1" >
<spacer name="horizontalSpacer" >
<property name="orientation" >
<item row="1" column="1">
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>663</width>
<height>20</height>
@ -1128,12 +1170,12 @@ object properties dialog.</string>
</property>
</spacer>
</item>
<item row="2" column="1" >
<spacer name="verticalSpacer" >
<property name="orientation" >
<item row="2" column="1">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0" >
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>33</height>
@ -1159,7 +1201,7 @@ object properties dialog.</string>
</customwidget>
</customwidgets>
<resources>
<include location="MainRes.qrc" />
<include location="MainRes.qrc"/>
</resources>
<connections>
<connection>
@ -1168,11 +1210,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>196</x>
<y>222</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1184,11 +1226,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>52</x>
<y>181</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1200,11 +1242,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>52</x>
<y>164</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1216,11 +1258,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>178</x>
<y>240</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1232,11 +1274,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>57</x>
<y>206</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1248,11 +1290,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>313</x>
<y>206</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1264,11 +1306,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>494</x>
<y>207</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1280,11 +1322,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>55</x>
<y>243</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1296,11 +1338,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>105</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1312,11 +1354,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>105</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1328,11 +1370,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>141</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1344,11 +1386,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>105</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1360,11 +1402,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>105</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1376,11 +1418,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>iptRouteContinueToggled()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>105</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1392,11 +1434,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>105</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1408,11 +1450,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>250</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1424,11 +1466,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>45</x>
<y>221</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1440,11 +1482,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>301</x>
<y>221</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1456,11 +1498,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>482</x>
<y>222</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1472,11 +1514,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>225</x>
<y>218</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1488,11 +1530,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>46</x>
<y>233</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1504,11 +1546,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>46</x>
<y>131</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1520,11 +1562,11 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>46</x>
<y>233</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>20</x>
<y>20</y>
</hint>
@ -1536,15 +1578,66 @@ object properties dialog.</string>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel" >
<hint type="sourcelabel">
<x>338</x>
<y>233</y>
</hint>
<hint type="destinationlabel" >
<hint type="destinationlabel">
<x>317</x>
<y>177</y>
</hint>
</hints>
</connection>
<connection>
<sender>pf_tag_terminating</sender>
<signal>toggled(bool)</signal>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel">
<x>238</x>
<y>89</y>
</hint>
<hint type="destinationlabel">
<x>425</x>
<y>114</y>
</hint>
</hints>
</connection>
<connection>
<sender>pf_classify_terminating</sender>
<signal>toggled(bool)</signal>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel">
<x>425</x>
<y>88</y>
</hint>
<hint type="destinationlabel">
<x>425</x>
<y>114</y>
</hint>
</hints>
</connection>
<connection>
<sender>pf_classify_str</sender>
<signal>editingFinished()</signal>
<receiver>ActionsDialog_q</receiver>
<slot>changed()</slot>
<hints>
<hint type="sourcelabel">
<x>425</x>
<y>59</y>
</hint>
<hint type="destinationlabel">
<x>425</x>
<y>114</y>
</hint>
</hints>
</connection>
</connections>
<slots>
<slot>changed()</slot>
</slots>
</ui>

View File

@ -7,7 +7,7 @@
<x>0</x>
<y>0</y>
<width>1186</width>
<height>325</height>
<height>329</height>
</rect>
</property>
<property name="windowTitle">
@ -41,7 +41,7 @@
<number>0</number>
</property>
<property name="currentIndex">
<number>0</number>
<number>2</number>
</property>
<widget class="QWidget" name="ipt">
<layout class="QGridLayout">
@ -642,9 +642,6 @@
<string>hashlimit</string>
</attribute>
<layout class="QGridLayout" name="gridLayout_8">
<property name="verticalSpacing">
<number>8</number>
</property>
<property name="leftMargin">
<number>12</number>
</property>
@ -654,6 +651,9 @@
<property name="bottomMargin">
<number>12</number>
</property>
<property name="verticalSpacing">
<number>8</number>
</property>
<item row="0" column="0">
<widget class="QLabel" name="textLabel2_5">
<property name="text">

View File

@ -614,11 +614,43 @@ bool PolicyCompiler_pf::setQuickFlag::processNext()
PolicyRule *rule=getNext(); if (rule==NULL) return false;
tmp_queue.push_back(rule);
if ( rule->getAction()!=PolicyRule::Scrub &&
rule->getAction()!=PolicyRule::Accounting &&
rule->getAction()!=PolicyRule::Tag &&
rule->getAction()!=PolicyRule::Branch
) rule->setBool("quick",true);
FWOptions *ropt = rule->getOptionsObject();
// as of 4.2.0 build 3477 we provide checkboxes to make Tag and
// Classify actions (PF) terminating or non-terminating on
// per-rule basis. Old behavior: Tag was non-terminating and
// Classify was terminating. Set options accordingly if they are
// not set.
switch (rule->getAction())
{
case PolicyRule::Scrub:
case PolicyRule::Accounting:
case PolicyRule::Branch:
break;
case PolicyRule::Tag:
{
string pf_tag_terminating = ropt->getStr("pf_tag_terminating");
if (pf_tag_terminating.empty())
ropt->setBool("pf_tag_terminating", false);
if (ropt->getBool("pf_tag_terminating")) rule->setBool("quick", true);
break;
}
case PolicyRule::Classify:
{
string pf_classify_terminating = ropt->getStr("pf_classify_terminating");
if (pf_classify_terminating.empty())
ropt->setBool("pf_classify_terminating", true);
if (ropt->getBool("pf_classify_terminating")) rule->setBool("quick", true);
break;
}
default:
rule->setBool("quick", true);
break;
}
return true;
}
@ -966,6 +998,8 @@ void PolicyCompiler_pf::compile()
add( new checkForObjectsWithErrors(
"check if we have objects with errors in rule elements"));
add(new setQuickFlag("set 'quick' flag"));
add(new DetectShadowing("Detect shadowing"));
add(new simplePrintProgress());
@ -1172,10 +1206,9 @@ void PolicyCompiler_pf::insertPfsyncRule()
bool PolicyCompiler_pf::checkForShadowingPlatformSpecific(PolicyRule *r1,
PolicyRule *r2)
{
PolicyRule::Action r2_action = r2->getAction();
// Tag action is non-terminating and does not shadow anything
if (r2_action == PolicyRule::Tag) return false;
bool quick = r2->getBool("quick");
// if quick == false, the rule is non-terminating
if (!quick) return false;
return true;
}

View File

@ -71,7 +71,7 @@
<Tag>
<supported>True</supported>
<description>Tag</description>
<dialog_page>TagInt</dialog_page>
<dialog_page>TagIptables</dialog_page>
</Tag>
<Pipe>
<supported>True</supported>
@ -81,7 +81,7 @@
<Classify>
<supported>True</supported>
<description>Classify</description>
<dialog_page>ClassifyStr</dialog_page>
<dialog_page>ClassifyIptables</dialog_page>
</Classify>
<Custom>
<supported>True</supported>

View File

@ -65,7 +65,7 @@
<Tag>
<supported>True</supported>
<description>Tag</description>
<dialog_page>TagStr</dialog_page>
<dialog_page>TagPF</dialog_page>
</Tag>
<Pipe>
<supported>False</supported>
@ -75,7 +75,7 @@
<Classify>
<supported>True</supported>
<description>Classify</description>
<dialog_page>ClassifyStr</dialog_page>
<dialog_page>ClassifyPF</dialog_page>
</Classify>
<Custom>
<supported>False</supported>

View File

@ -3,7 +3,7 @@
#
# Firewall Builder fwb_pf v4.2.0.3476
#
# Generated Mon Feb 14 16:07:57 2011 PST by vadim
# Generated Tue Feb 15 14:17:50 2011 PST by vadim
#
# files: * pf_cluster_4_rc.conf.local /etc/pf_cluster_4_rc.conf.local
# files: pf_cluster_4_pf.conf /etc/pf_cluster_4_pf.conf