summaryrefslogtreecommitdiffstats
path: root/usr.sbin
diff options
context:
space:
mode:
authorbrian <brian@FreeBSD.org>1999-07-26 11:15:11 +0000
committerbrian <brian@FreeBSD.org>1999-07-26 11:15:11 +0000
commitdbc7eddfa5650674631dc18adcf60ed0dfea8a32 (patch)
tree127595cbd464087c246fa496ee11f7e2c6ff83b4 /usr.sbin
parent03ab8a3b7f99d8f1fc922f681d713dde620b53e6 (diff)
downloadFreeBSD-src-dbc7eddfa5650674631dc18adcf60ed0dfea8a32.zip
FreeBSD-src-dbc7eddfa5650674631dc18adcf60ed0dfea8a32.tar.gz
Fix an off-by-one error and correct the man page WRT clearing
filters. Submitted by: Peter Jeremy <peter.jeremy@alcatel.com.au> PR: 12437
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/ppp/filter.c4
-rw-r--r--usr.sbin/ppp/ppp.88
-rw-r--r--usr.sbin/ppp/ppp.8.m48
3 files changed, 14 insertions, 6 deletions
diff --git a/usr.sbin/ppp/filter.c b/usr.sbin/ppp/filter.c
index 024cd91..aefb43a 100644
--- a/usr.sbin/ppp/filter.c
+++ b/usr.sbin/ppp/filter.c
@@ -17,7 +17,7 @@
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
- * $Id: filter.c,v 1.29 1999/05/31 23:57:36 brian Exp $
+ * $Id: filter.c,v 1.30 1999/06/23 16:48:21 brian Exp $
*
* TODO: Shoud send ICMP error message when we discard packets.
*/
@@ -306,7 +306,7 @@ Parse(struct ipcp *ipcp, int argc, char const *const *argv,
struct filterent filterdata;
val = strtol(*argv, &wp, 0);
- if (*argv == wp || val > MAXFILTERS) {
+ if (*argv == wp || val >= MAXFILTERS) {
log_Printf(LogWARN, "Parse: invalid filter number.\n");
return (0);
}
diff --git a/usr.sbin/ppp/ppp.8 b/usr.sbin/ppp/ppp.8
index 87b115e..8217cb8 100644
--- a/usr.sbin/ppp/ppp.8
+++ b/usr.sbin/ppp/ppp.8
@@ -1,4 +1,4 @@
-.\" $Id: ppp.8,v 1.177 1999/06/23 16:48:24 brian Exp $
+.\" $Id: ppp.8,v 1.178 1999/07/17 10:33:57 brian Exp $
.Dd 20 September 1995
.nr XX \w'\fC00'
.Os FreeBSD
@@ -1424,7 +1424,7 @@ or
is a numeric value between
.Sq 0
and
-.Sq 19
+.Sq 39
specifying the rule number. Rules are specified in numeric order according to
.Ar rule-no ,
but only if rule
@@ -1438,6 +1438,10 @@ or
.Sq deny .
If a given packet
matches the rule, the associated action is taken immediately.
+.Ar Action
+can also be specified as
+.Sq clear
+to clear the action associated with that particular rule.
.It
.Op Ar src_addr Ns Op / Ns Ar width
and
diff --git a/usr.sbin/ppp/ppp.8.m4 b/usr.sbin/ppp/ppp.8.m4
index 87b115e..8217cb8 100644
--- a/usr.sbin/ppp/ppp.8.m4
+++ b/usr.sbin/ppp/ppp.8.m4
@@ -1,4 +1,4 @@
-.\" $Id: ppp.8,v 1.177 1999/06/23 16:48:24 brian Exp $
+.\" $Id: ppp.8,v 1.178 1999/07/17 10:33:57 brian Exp $
.Dd 20 September 1995
.nr XX \w'\fC00'
.Os FreeBSD
@@ -1424,7 +1424,7 @@ or
is a numeric value between
.Sq 0
and
-.Sq 19
+.Sq 39
specifying the rule number. Rules are specified in numeric order according to
.Ar rule-no ,
but only if rule
@@ -1438,6 +1438,10 @@ or
.Sq deny .
If a given packet
matches the rule, the associated action is taken immediately.
+.Ar Action
+can also be specified as
+.Sq clear
+to clear the action associated with that particular rule.
.It
.Op Ar src_addr Ns Op / Ns Ar width
and
OpenPOWER on IntegriCloud