cosmetic:

o  Log client connection commands when "set log +command"
o  Don't display PAP password in the log unless we're
   "set log +debug".
This commit is contained in:
Brian Somers 1997-10-16 23:55:19 +00:00
parent e9565321ea
commit 331953abc2
2 changed files with 8 additions and 3 deletions

View File

@ -17,7 +17,7 @@
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
* $Id: main.c,v 1.81 1997/09/22 00:46:55 brian Exp $
* $Id: main.c,v 1.82 1997/10/07 00:56:57 brian Exp $
*
* TODO:
* o Add commands for traffic summary, version display, etc.
@ -547,6 +547,8 @@ ReadTty()
n = read(netfd, linebuff, sizeof(linebuff) - 1);
if (n > 0) {
aft_cmd = 1;
linebuff[n] = '\0';
LogPrintf(LogCOMMAND, "Client: %s\n", linebuff);
DecodeCommand(linebuff, n, 1);
} else {
LogPrintf(LogPHASE, "client connection closed.\n");

View File

@ -18,7 +18,7 @@
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
* $Id: pap.c,v 1.15 1997/09/22 23:59:15 brian Exp $
* $Id: pap.c,v 1.16 1997/09/27 19:11:41 brian Exp $
*
* TODO:
*/
@ -61,7 +61,10 @@ SendPapChallenge(int papid)
plen = namelen + keylen + 2;
LogPrintf(LogDEBUG, "SendPapChallenge: namelen = %d, keylen = %d\n",
namelen, keylen);
LogPrintf(LogPHASE, "PAP: %s (%s)\n", VarAuthName, VarAuthKey);
if (LogIsKept(LogDEBUG))
LogPrintf(LogPHASE, "PAP: %s (%s)\n", VarAuthName, VarAuthKey);
else
LogPrintf(LogPHASE, "PAP: %s\n", VarAuthName);
lh.code = PAP_REQUEST;
lh.id = papid;
lh.length = htons(plen + sizeof(struct fsmheader));