summaryrefslogtreecommitdiffstats
path: root/sbin/ping
diff options
context:
space:
mode:
authormdodd <mdodd@FreeBSD.org>2003-04-02 20:14:44 +0000
committermdodd <mdodd@FreeBSD.org>2003-04-02 20:14:44 +0000
commitccc6071f7ea7e2ba54dfcf45ff8afda2e395aa3d (patch)
tree2e9681302fc88cc051f2afb4ca92612f8833c409 /sbin/ping
parentb6e2a1dccdce92b4fa014a9ca9dd2ab1697ce9aa (diff)
downloadFreeBSD-src-ccc6071f7ea7e2ba54dfcf45ff8afda2e395aa3d.zip
FreeBSD-src-ccc6071f7ea7e2ba54dfcf45ff8afda2e395aa3d.tar.gz
Back out support for RFC3514.
RFC3514 poses an unacceptale risk to compliant systems.
Diffstat (limited to 'sbin/ping')
-rw-r--r--sbin/ping/ping.86
-rw-r--r--sbin/ping/ping.c14
2 files changed, 3 insertions, 17 deletions
diff --git a/sbin/ping/ping.8 b/sbin/ping/ping.8
index 49223e4..71fa31a 100644
--- a/sbin/ping/ping.8
+++ b/sbin/ping/ping.8
@@ -42,7 +42,7 @@
packets to network hosts
.Sh SYNOPSIS
.Nm
-.Op Fl AaDdEfnoQqRrv
+.Op Fl AaDdfnoQqRrv
.Op Fl c Ar count
.Op Fl i Ar wait
.Op Fl l Ar preload
@@ -56,7 +56,7 @@ packets to network hosts
.Op Fl z Ar tos
.Ar host
.Nm
-.Op Fl AaDdEfLnoQqRrv
+.Op Fl AaDdfLnoQqRrv
.Op Fl c Ar count
.Op Fl I Ar iface
.Op Fl i Ar wait
@@ -122,8 +122,6 @@ If this option is not specified,
will operate until interrupted.
.It Fl D
Set the Don't Fragment bit.
-.It Fl E
-Set the EVIL bit.
.It Fl d
Set the
.Dv SO_DEBUG
diff --git a/sbin/ping/ping.c b/sbin/ping/ping.c
index b0efe14..0d41c92 100644
--- a/sbin/ping/ping.c
+++ b/sbin/ping/ping.c
@@ -143,7 +143,6 @@ int options;
#define F_HDRINCL 0x40000
#define F_MASK 0x80000
#define F_TIME 0x100000
-#define F_SO_EVIL 0x200000
/*
* MAX_DUP_CHK is the number of bits in received table, i.e. the maximum
@@ -257,7 +256,7 @@ main(argc, argv)
outpack = outpackhdr + sizeof(struct ip);
while ((ch = getopt(argc, argv,
- "Aac:DdEfI:i:Ll:M:m:nop:QqRrS:s:T:t:vz:"
+ "Aac:DdfI:i:Ll:M:m:nop:QqRrS:s:T:t:vz:"
#ifdef IPSEC
#ifdef IPSEC_POLICY_IPSEC
"P:"
@@ -287,9 +286,6 @@ main(argc, argv)
case 'd':
options |= F_SO_DEBUG;
break;
- case 'E':
- options |= F_SO_EVIL;
- break;
case 'f':
if (uid) {
errno = EPERM;
@@ -551,10 +547,6 @@ main(argc, argv)
if (options & F_SO_DONTROUTE)
(void)setsockopt(s, SOL_SOCKET, SO_DONTROUTE, (char *)&hold,
sizeof(hold));
- if (options & F_SO_EVIL)
- if (setsockopt(s, IPPROTO_IP, IP_EVIL_INTENT, (char *)&hold,
- sizeof(hold)) != 0)
- err(EX_OSERR, "setsockopt(s, IPPROTO_IP, IP_EVIL_INTENT, ...)");
#ifdef IPSEC
#ifdef IPSEC_POLICY_IPSEC
if (options & F_POLICY) {
@@ -601,8 +593,6 @@ main(argc, argv)
ip->ip_tos = tos;
ip->ip_id = 0;
ip->ip_off = df ? IP_DF : 0;
- if (options & F_SO_EVIL)
- ip->ip_off |= IP_EF;
ip->ip_ttl = ttl;
ip->ip_p = IPPROTO_ICMP;
ip->ip_src.s_addr = source ? sock_in.sin_addr.s_addr : INADDR_ANY;
@@ -1001,8 +991,6 @@ pr_pack(buf, cc, from, tv)
(void)printf(" ttl=%d", ip->ip_ttl);
if (timing)
(void)printf(" time=%.3f ms", triptime);
- if (ip->ip_off & IP_EF)
- (void)printf(" (EVIL)");
if (dupflag)
(void)printf(" (DUP!)");
if (options & F_AUDIBLE)
OpenPOWER on IntegriCloud