diff options
author | brian <brian@FreeBSD.org> | 1997-09-09 21:51:39 +0000 |
---|---|---|
committer | brian <brian@FreeBSD.org> | 1997-09-09 21:51:39 +0000 |
commit | 0791c3c050563d41ecbe2f1f3dbd97650078073e (patch) | |
tree | 3e5dfc8a61a8bcf3a14a246396d24730d53012df /usr.sbin/ppp/auth.c | |
parent | 4939f4fc068fe39f1044cd1462eb87e57064ec20 (diff) | |
download | FreeBSD-src-0791c3c050563d41ecbe2f1f3dbd97650078073e.zip FreeBSD-src-0791c3c050563d41ecbe2f1f3dbd97650078073e.tar.gz |
Correct ppp authentication defaults in interactive
mode. We don't want to be forced to type a password
here :-(
Pointed out by: mouth@ibm.net (John Kelly)
While I'm there, don't allow a "set server" in
interactive mode.
Diffstat (limited to 'usr.sbin/ppp/auth.c')
-rw-r--r-- | usr.sbin/ppp/auth.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/usr.sbin/ppp/auth.c b/usr.sbin/ppp/auth.c index 1ea18c9..72197e6 100644 --- a/usr.sbin/ppp/auth.c +++ b/usr.sbin/ppp/auth.c @@ -17,7 +17,7 @@ * IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED * WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE. * - * $Id: auth.c,v 1.15 1997/08/25 00:29:05 brian Exp $ + * $Id: auth.c,v 1.16 1997/09/04 00:38:17 brian Exp $ * * TODO: * o Implement check against with registered IP addresses. @@ -48,8 +48,12 @@ LocalAuthInit() if (p) *p = '\0'; - VarLocalAuth = LocalAuthValidate(SECRETFILE, VarShortHost, "") == NOT_FOUND ? - LOCAL_DENY : LOCAL_NO_AUTH; + if (!(mode&(MODE_AUTO|MODE_DEDICATED|MODE_DIRECT))) + /* We're allowed in interactive and direct */ + VarLocalAuth = LOCAL_AUTH; + else + VarLocalAuth = LocalAuthValidate(SECRETFILE, VarShortHost, "") + == NOT_FOUND ? LOCAL_DENY : LOCAL_NO_AUTH; } LOCAL_AUTH_VALID |