summaryrefslogtreecommitdiffstats
path: root/usr.sbin/ppp
diff options
context:
space:
mode:
authorsjg <sjg@FreeBSD.org>2013-09-05 20:18:59 +0000
committersjg <sjg@FreeBSD.org>2013-09-05 20:18:59 +0000
commit62bb1062226d3ce6a2350808256a25508978352d (patch)
tree22b131dceb13c3df96da594fbaadb693504797c7 /usr.sbin/ppp
parent72ab90509b3a51ab361bf710338f2ef44a4e360d (diff)
parent04932445481c2cb89ff69a83b961bdef3d64757e (diff)
downloadFreeBSD-src-62bb1062226d3ce6a2350808256a25508978352d.zip
FreeBSD-src-62bb1062226d3ce6a2350808256a25508978352d.tar.gz
Merge from head
Diffstat (limited to 'usr.sbin/ppp')
-rw-r--r--usr.sbin/ppp/Makefile7
-rw-r--r--usr.sbin/ppp/command.c2
-rw-r--r--usr.sbin/ppp/defs.c13
-rw-r--r--usr.sbin/ppp/defs.h2
-rw-r--r--usr.sbin/ppp/ppp.8 (renamed from usr.sbin/ppp/ppp.8.m4)38
5 files changed, 17 insertions, 45 deletions
diff --git a/usr.sbin/ppp/Makefile b/usr.sbin/ppp/Makefile
index 11003d7..9943665 100644
--- a/usr.sbin/ppp/Makefile
+++ b/usr.sbin/ppp/Makefile
@@ -44,13 +44,6 @@ M4FLAGS=
LDADD= -lcrypt -lmd -lutil -lz
DPADD= ${LIBCRYPT} ${LIBMD} ${LIBUTIL} ${LIBZ}
-.SUFFIXES: .8 .8.m4
-
-.8.m4.8:
- m4 ${M4FLAGS} ${.IMPSRC} >${.TARGET}
-
-CLEANFILES= ppp.8
-
.if defined(PPP_CONFDIR) && !empty(PPP_CONFDIR)
CFLAGS+=-DPPP_CONFDIR=\"${PPP_CONFDIR}\"
.endif
diff --git a/usr.sbin/ppp/command.c b/usr.sbin/ppp/command.c
index 91fe028..6bdf0c9 100644
--- a/usr.sbin/ppp/command.c
+++ b/usr.sbin/ppp/command.c
@@ -416,7 +416,7 @@ DialCommand(struct cmdargs const *arg)
static char *
strstrword(char *big, const char *little)
{
- /* Get the first occurrance of the word ``little'' in ``big'' */
+ /* Get the first occurrence of the word ``little'' in ``big'' */
char *pos;
int len;
diff --git a/usr.sbin/ppp/defs.c b/usr.sbin/ppp/defs.c
index dcd9e47..856c200 100644
--- a/usr.sbin/ppp/defs.c
+++ b/usr.sbin/ppp/defs.c
@@ -43,7 +43,7 @@
#include <sys/module.h>
#endif
#include <termios.h>
-#if !defined(__FreeBSD__) || __FreeBSD__ < 3
+#ifndef __FreeBSD__
#include <time.h>
#endif
#include <unistd.h>
@@ -56,20 +56,11 @@
#define issep(c) ((c) == '\t' || (c) == ' ')
-#if defined(__NetBSD__) || __FreeBSD__ < 3
+#ifdef __NetBSD__
void
randinit()
{
-#if defined(__FreeBSD__)
- static int initdone; /* srandomdev() call is only required once */
-
- if (!initdone) {
- initdone = 1;
- srandomdev();
- }
-#else
srandom((time(NULL)^getpid())+random());
-#endif
}
#endif
diff --git a/usr.sbin/ppp/defs.h b/usr.sbin/ppp/defs.h
index d7cc799..d320a53 100644
--- a/usr.sbin/ppp/defs.h
+++ b/usr.sbin/ppp/defs.h
@@ -117,7 +117,7 @@
#define ROUNDUP(x) ((x) ? (1 + (((x) - 1) | (sizeof(long) - 1))) : sizeof(long))
-#if defined(__NetBSD__) || __FreeBSD__ < 3
+#ifdef __NetBSD__
extern void randinit(void);
#else
#define random arc4random
diff --git a/usr.sbin/ppp/ppp.8.m4 b/usr.sbin/ppp/ppp.8
index 91b9c51..7358a48 100644
--- a/usr.sbin/ppp/ppp.8.m4
+++ b/usr.sbin/ppp/ppp.8
@@ -1,5 +1,3 @@
-changequote({,})dnl
-changecom(,)dnl
.\"
.\" Copyright (c) 2001 Brian Somers <brian@Awfulhak.org>
.\" All rights reserved.
@@ -65,10 +63,9 @@ This allows
.Nm
to act as a NAT or masquerading engine for all machines on an internal
LAN.
-ifdef({LOCALNAT},{},{Refer to
+Refer to
.Xr libalias 3
for details on the technical side of the NAT engine.
-})dnl
Refer to the
.Sx NETWORK ADDRESS TRANSLATION (PACKET ALIASING)
section of this manual page for details on how to configure NAT in
@@ -313,14 +310,13 @@ An extension to PAP and CHAP,
allows authentication information to be stored in a central or
distributed database along with various per-user framed connection
characteristics.
-ifdef({LOCALRAD},{},{If
+If
.Xr libradius 3
is available at compile time,
.Nm
will use it to make
.Em RADIUS
requests when configured to do so.
-})dnl
.It Supports Proxy Arp.
.Nm
can be configured to make one or more proxy arp entries on behalf of
@@ -3018,9 +3014,9 @@ The option can only be enabled if network address translation is enabled
With this option enabled,
.Nm
will pass traffic for old interface addresses through the NAT
-ifdef({LOCALNAT},{engine,},{engine
+engine
(see
-.Xr libalias 3 ) ,})
+.Xr libalias 3 ) ,
resulting in the ability (in
.Fl auto
mode) to properly connect the process that caused the PPP link to
@@ -3428,18 +3424,17 @@ you wish to map to specific machines behind your gateway.
.It nat deny_incoming yes|no
If set to yes, this command will refuse all incoming packets where an
aliasing link does not already exist.
-ifdef({LOCALNAT},{},{Refer to the
+Refer to the
.Sx CONCEPTUAL BACKGROUND
section of
.Xr libalias 3
for a description of what an
.Dq aliasing link
is.
-})dnl
.Pp
It should be noted under what circumstances an aliasing link is
-ifdef({LOCALNAT},{created.},{created by
-.Xr libalias 3 .})
+created by
+.Xr libalias 3 .
It may be necessary to further protect your network from outside
connections using the
.Dq set filter
@@ -3524,12 +3519,11 @@ for example:
This command tells
.Nm
to proxy certain connections, redirecting them to a given server.
-ifdef({LOCALNAT},{},{Refer to the description of
+Refer to the description of
.Fn PacketAliasProxyRule
in
.Xr libalias 3
for details of the available commands.
-})dnl
.It nat punch_fw Op Ar base count
This command tells
.Nm
@@ -3567,9 +3561,8 @@ if you want to support protocols such as RPC and LPD which require
connections to come from a well known port.
.It nat target Op Ar address
Set the given target address or clear it if no address is given.
-The target address is used
-ifdef({LOCALNAT},{},{by libalias })dnl
-to specify how to NAT incoming packets by default.
+The target address is used by libalias to specify how to NAT incoming packets
+by default.
If a target address is not set or if
.Dq default
is given, packets are not altered and are allowed to route to the internal
@@ -3577,10 +3570,7 @@ network.
.Pp
The target address may be set to
.Dq MYADDR ,
-in which case
-ifdef({LOCALNAT},{all packets will be redirected},
-{libalias will redirect all packets})
-to the interface address.
+in which case libalias will redirect all packets to the interface address.
.It nat use_sockets yes|no
When enabled, this option tells the network address translation engine to
create a socket so that it can guarantee a correct incoming ftp data or
@@ -6055,10 +6045,8 @@ This socket is used to pass links between different instances of
.Xr kldload 2 ,
.Xr pipe 2 ,
.Xr socketpair 2 ,
-ifdef({LOCALNAT},{},{.Xr libalias 3 ,
-})dnl
-ifdef({LOCALRAD},{},{.Xr libradius 3 ,
-})dnl
+.Xr libalias 3 ,
+.Xr libradius 3 ,
.Xr syslog 3 ,
.Xr uucplock 3 ,
.Xr netgraph 4 ,
OpenPOWER on IntegriCloud