aboutsummaryrefslogtreecommitdiff
path: root/sbin/ipfw
diff options
context:
space:
mode:
authorArchie Cobbs <archie@FreeBSD.org>1998-12-07 05:54:37 +0000
committerArchie Cobbs <archie@FreeBSD.org>1998-12-07 05:54:37 +0000
commitb31a38612b75244bfd436715845c173c2e313f37 (patch)
tree78e923c5e5c109bff8083280aa913c2937b4598f /sbin/ipfw
parent6572231d20d35cb60ddf3e98a5a3c00843b67e44 (diff)
downloadsrc-b31a38612b75244bfd436715845c173c2e313f37.tar.gz
src-b31a38612b75244bfd436715845c173c2e313f37.zip
Disallow ipfw "tee" rules until it is actually implemented.
PR: bin/8471
Notes
Notes: svn path=/head/; revision=41576
Diffstat (limited to 'sbin/ipfw')
-rw-r--r--sbin/ipfw/ipfw.82
-rw-r--r--sbin/ipfw/ipfw.c13
2 files changed, 10 insertions, 5 deletions
diff --git a/sbin/ipfw/ipfw.8 b/sbin/ipfw/ipfw.8
index d7f8cd81b142..6875c94aaa2c 100644
--- a/sbin/ipfw/ipfw.8
+++ b/sbin/ipfw/ipfw.8
@@ -574,6 +574,8 @@ are reassembled before delivery to the socket, whereas fragments diverted via
are not.
.Pp
Port aliases containing dashes cannot be first in a list.
+.Pp
+The ``tee'' action is unimplemented.
.Sh AUTHORS
.An Ugen J. S. Antsilevich ,
.An Poul-Henning Kamp ,
diff --git a/sbin/ipfw/ipfw.c b/sbin/ipfw/ipfw.c
index d0f06ce5c2d9..91a8a3a878d2 100644
--- a/sbin/ipfw/ipfw.c
+++ b/sbin/ipfw/ipfw.c
@@ -16,7 +16,7 @@
*
* NEW command line interface for IP firewall facility
*
- * $Id: ipfw.c,v 1.60 1998/09/28 22:56:37 alex Exp $
+ * $Id: ipfw.c,v 1.61 1998/11/23 10:54:28 joerg Exp $
*
*/
@@ -879,7 +879,7 @@ add(ac,av)
} else if (!strncmp(*av,"divert",strlen(*av))) {
rule.fw_flg |= IP_FW_F_DIVERT; av++; ac--;
if (!ac)
- show_usage("missing divert port");
+ show_usage("missing %s port", "divert");
rule.fw_divert_port = strtoul(*av, NULL, 0); av++; ac--;
if (rule.fw_divert_port == 0) {
struct servent *s;
@@ -888,12 +888,12 @@ add(ac,av)
if (s != NULL)
rule.fw_divert_port = ntohs(s->s_port);
else
- show_usage("illegal divert port");
+ show_usage("illegal %s port", "divert");
}
} else if (!strncmp(*av,"tee",strlen(*av))) {
rule.fw_flg |= IP_FW_F_TEE; av++; ac--;
if (!ac)
- show_usage("missing divert port");
+ show_usage("missing %s port", "tee divert");
rule.fw_divert_port = strtoul(*av, NULL, 0); av++; ac--;
if (rule.fw_divert_port == 0) {
struct servent *s;
@@ -902,8 +902,11 @@ add(ac,av)
if (s != NULL)
rule.fw_divert_port = ntohs(s->s_port);
else
- show_usage("illegal divert port");
+ show_usage("illegal %s port", "tee divert");
}
+#ifndef IPFW_TEE_IS_FINALLY_IMPLEMENTED
+ err(EX_USAGE, "the ``tee'' action is not implemented");
+#endif
} else if (!strncmp(*av,"fwd",strlen(*av)) ||
!strncmp(*av,"forward",strlen(*av))) {
struct in_addr dummyip;