summaryrefslogtreecommitdiffstats
path: root/etc
diff options
context:
space:
mode:
authorScott Ullrich <sullrich@pfsense.org>2005-12-16 05:25:47 +0000
committerScott Ullrich <sullrich@pfsense.org>2005-12-16 05:25:47 +0000
commit3cd71852aad61bfdeb09dd911c3cdfd7fe5bf1cf (patch)
tree500cf3abc67061ea902656464bc61c5c394bf27a /etc
parent8b7207755b2567f2472be60c74999d5e161f7f74 (diff)
downloadpfsense-3cd71852aad61bfdeb09dd911c3cdfd7fe5bf1cf.zip
pfsense-3cd71852aad61bfdeb09dd911c3cdfd7fe5bf1cf.tar.gz
MFC 8474
Make shaper first match - fix a months old oversight.
Diffstat (limited to 'etc')
-rw-r--r--etc/inc/filter.inc7
-rw-r--r--etc/inc/shaper.inc2
2 files changed, 7 insertions, 2 deletions
diff --git a/etc/inc/filter.inc b/etc/inc/filter.inc
index 9a6a268..5ce29d9 100644
--- a/etc/inc/filter.inc
+++ b/etc/inc/filter.inc
@@ -97,7 +97,12 @@ function filter_configure_sync() {
$altq_queues = filter_generate_altq_queues($altq_ints);
/* generate altq rules */
if($g['booting'] == true) echo " altq-rules ";
- $pf_altq_rules = filter_generate_pf_altq_rules();
+ /* Setup a default rule that tags ALL packets as unshaped
+ * we'll match only unshaped packets in the shaper code later
+ * this allows the shaper to be first match
+ */
+ $pf_altq_rules = "block any tag unshaped label SHAPER: first match rule\n";
+ $pf_altq_rules .= filter_generate_pf_altq_rules();
}
/* enable pf if we need to, otherwise disable */
diff --git a/etc/inc/shaper.inc b/etc/inc/shaper.inc
index d2598b2..d1abe40 100644
--- a/etc/inc/shaper.inc
+++ b/etc/inc/shaper.inc
@@ -590,7 +590,7 @@ function filter_generate_pf_altq_rules() {
$line .= "{$flags}/SAFRPU ";
$qtag = "{$direction}queue";
- $line .= " keep state tag {$rule[$qtag]} ";
+ $line .= " keep state tagged unshaped tag {$rule[$qtag]} ";
$line .= "\n";
$shaperrules .= $line;
OpenPOWER on IntegriCloud