summaryrefslogtreecommitdiff
path: root/usr.sbin
diff options
context:
space:
mode:
authorbrian <brian@cvs.openbsd.org>1999-08-22 01:33:16 +0000
committerbrian <brian@cvs.openbsd.org>1999-08-22 01:33:16 +0000
commitea79928526ae3af87920aeebb9267f131731c701 (patch)
tree30979e5f521735f5ce63cae4bfc9a2a915b6bf2c /usr.sbin
parentf2ef619c8c65d978fc45b90073ed32ea592a6663 (diff)
Allow authkey to be changed independently of the current phase.
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/ppp/ppp/command.c19
1 files changed, 5 insertions, 14 deletions
diff --git a/usr.sbin/ppp/ppp/command.c b/usr.sbin/ppp/ppp/command.c
index b16f2809bf0..1c6b6dab1d5 100644
--- a/usr.sbin/ppp/ppp/command.c
+++ b/usr.sbin/ppp/ppp/command.c
@@ -17,7 +17,7 @@
* IMPLIED WARRANTIES, INCLUDING, WITHOUT LIMITATION, THE IMPLIED
* WARRANTIES OF MERCHANTIBILITY AND FITNESS FOR A PARTICULAR PURPOSE.
*
- * $Id: command.c,v 1.34 1999/08/17 17:25:34 brian Exp $
+ * $Id: command.c,v 1.35 1999/08/22 01:33:15 brian Exp $
*
*/
#include <sys/param.h>
@@ -144,7 +144,7 @@
#define NEG_VJCOMP 53
const char Version[] = "2.23";
-const char VersionDate[] = "$Date: 1999/08/17 17:25:34 $";
+const char VersionDate[] = "$Date: 1999/08/22 01:33:15 $";
static int ShowCommand(struct cmdargs const *);
static int TerminalCommand(struct cmdargs const *);
@@ -1399,18 +1399,9 @@ SetVariable(struct cmdargs const *arg)
switch (param) {
case VAR_AUTHKEY:
- switch (bundle_Phase(arg->bundle)) {
- case PHASE_DEAD:
- case PHASE_ESTABLISH:
- strncpy(arg->bundle->cfg.auth.key, argp,
- sizeof arg->bundle->cfg.auth.key - 1);
- arg->bundle->cfg.auth.key[sizeof arg->bundle->cfg.auth.key - 1] = '\0';
- break;
- default:
- err = "set authkey: Only available at phase DEAD/ESTABLISH\n";
- log_Printf(LogWARN, err);
- break;
- }
+ strncpy(arg->bundle->cfg.auth.key, argp,
+ sizeof arg->bundle->cfg.auth.key - 1);
+ arg->bundle->cfg.auth.key[sizeof arg->bundle->cfg.auth.key - 1] = '\0';
break;
case VAR_AUTHNAME: