Don't log the actual password when command-logging
"passwd xxxx".
This commit is contained in:
parent
d27d502ce6
commit
a09d09cbe7
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=31828
@ -17,7 +17,7 @@
|
|||||||
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
|
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
|
||||||
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
|
||||||
*
|
*
|
||||||
* $Id: command.c,v 1.111 1997/12/17 00:19:22 brian Exp $
|
* $Id: command.c,v 1.112 1997/12/17 21:21:38 brian Exp $
|
||||||
*
|
*
|
||||||
*/
|
*/
|
||||||
#include <sys/param.h>
|
#include <sys/param.h>
|
||||||
@ -742,10 +742,17 @@ static int
|
|||||||
arghidden(int argc, char const *const *argv, int n)
|
arghidden(int argc, char const *const *argv, int n)
|
||||||
{
|
{
|
||||||
/* Is arg n of the given command to be hidden from the log ? */
|
/* Is arg n of the given command to be hidden from the log ? */
|
||||||
|
|
||||||
|
/* set authkey xxxxx */
|
||||||
|
/* set key xxxxx */
|
||||||
if (n == 2 && !strncasecmp(argv[0], "se", 2) &&
|
if (n == 2 && !strncasecmp(argv[0], "se", 2) &&
|
||||||
(!strncasecmp(argv[1], "authk", 5) || !strncasecmp(argv[1], "ke", 2)))
|
(!strncasecmp(argv[1], "authk", 5) || !strncasecmp(argv[1], "ke", 2)))
|
||||||
return 1;
|
return 1;
|
||||||
|
|
||||||
|
/* passwd xxxxx */
|
||||||
|
if (n == 1 && !strncasecmp(argv[0], "p", 1))
|
||||||
|
return 1;
|
||||||
|
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
.\" $Id: ppp.8,v 1.85 1997/12/16 00:32:35 brian Exp $
|
.\" $Id: ppp.8,v 1.86 1997/12/17 21:21:40 brian Exp $
|
||||||
.Dd 20 September 1995
|
.Dd 20 September 1995
|
||||||
.Os FreeBSD
|
.Os FreeBSD
|
||||||
.Dt PPP 8
|
.Dt PPP 8
|
||||||
@ -1985,7 +1985,22 @@ label is assumed.
|
|||||||
.It passwd pass
|
.It passwd pass
|
||||||
Specify the password required for access to the full
|
Specify the password required for access to the full
|
||||||
.Nm
|
.Nm
|
||||||
command set.
|
command set. This password is required when connecting to the diagnostic
|
||||||
|
port (see the
|
||||||
|
.Dq set server
|
||||||
|
command).
|
||||||
|
.Ar Pass
|
||||||
|
may be specified either on the
|
||||||
|
.Dq set server
|
||||||
|
command line or by putting an entry in
|
||||||
|
.Pa /var/log/ppp.secret
|
||||||
|
for the local host. The value of
|
||||||
|
.Ar pass
|
||||||
|
is not logged when
|
||||||
|
.Ar command
|
||||||
|
logging is active, instead, the literal string
|
||||||
|
.Dq ********
|
||||||
|
is logged.
|
||||||
|
|
||||||
.It quit|bye [all]
|
.It quit|bye [all]
|
||||||
Exit
|
Exit
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
.\" $Id: ppp.8,v 1.85 1997/12/16 00:32:35 brian Exp $
|
.\" $Id: ppp.8,v 1.86 1997/12/17 21:21:40 brian Exp $
|
||||||
.Dd 20 September 1995
|
.Dd 20 September 1995
|
||||||
.Os FreeBSD
|
.Os FreeBSD
|
||||||
.Dt PPP 8
|
.Dt PPP 8
|
||||||
@ -1985,7 +1985,22 @@ label is assumed.
|
|||||||
.It passwd pass
|
.It passwd pass
|
||||||
Specify the password required for access to the full
|
Specify the password required for access to the full
|
||||||
.Nm
|
.Nm
|
||||||
command set.
|
command set. This password is required when connecting to the diagnostic
|
||||||
|
port (see the
|
||||||
|
.Dq set server
|
||||||
|
command).
|
||||||
|
.Ar Pass
|
||||||
|
may be specified either on the
|
||||||
|
.Dq set server
|
||||||
|
command line or by putting an entry in
|
||||||
|
.Pa /var/log/ppp.secret
|
||||||
|
for the local host. The value of
|
||||||
|
.Ar pass
|
||||||
|
is not logged when
|
||||||
|
.Ar command
|
||||||
|
logging is active, instead, the literal string
|
||||||
|
.Dq ********
|
||||||
|
is logged.
|
||||||
|
|
||||||
.It quit|bye [all]
|
.It quit|bye [all]
|
||||||
Exit
|
Exit
|
||||||
|
Loading…
Reference in New Issue
Block a user