diff options
author | Niklas Hallqvist <niklas@cvs.openbsd.org> | 2000-05-02 14:37:01 +0000 |
---|---|---|
committer | Niklas Hallqvist <niklas@cvs.openbsd.org> | 2000-05-02 14:37:01 +0000 |
commit | 72a4d4203b22931174551a88523fc297350d39b9 (patch) | |
tree | 4d23bab5d6297648bc6e44bfe133f8d97cffdee9 /sbin/isakmpd | |
parent | a080c32b50bc3a028b2dd4381df6e20d6acdc4b7 (diff) |
conf.h: Merge with EOM 1.11
ui.c: Merge with EOM 1.41
author: niklas
From ho: provide defaults for requested transforms, shortens config files
vastly.
Diffstat (limited to 'sbin/isakmpd')
-rw-r--r-- | sbin/isakmpd/conf.h | 26 | ||||
-rw-r--r-- | sbin/isakmpd/ui.c | 7 |
2 files changed, 27 insertions, 6 deletions
diff --git a/sbin/isakmpd/conf.h b/sbin/isakmpd/conf.h index 8e8578e7435..0404636792d 100644 --- a/sbin/isakmpd/conf.h +++ b/sbin/isakmpd/conf.h @@ -1,5 +1,5 @@ -/* $OpenBSD: conf.h,v 1.9 1999/08/05 22:41:08 niklas Exp $ */ -/* $EOM: conf.h,v 1.10 1999/08/05 14:57:59 niklas Exp $ */ +/* $OpenBSD: conf.h,v 1.10 2000/05/02 14:37:00 niklas Exp $ */ +/* $EOM: conf.h,v 1.11 2000/05/01 20:57:33 niklas Exp $ */ /* * Copyright (c) 1998, 1999 Niklas Hallqvist. All rights reserved. @@ -43,6 +43,25 @@ #define CONFIG_FILE "/etc/isakmpd/isakmpd.conf" +/* Default values for autogenerated part of our configuration. */ +#define CONF_DFLT_TAG_LIFE_MAIN_MODE "LIFE_MAIN_MODE" +#define CONF_DFLT_TYPE_LIFE_MAIN_MODE "SECONDS" +#define CONF_DFLT_VAL_LIFE_MAIN_MODE "3600,60:86400" + +#define CONF_DFLT_TAG_LIFE_QUICK_MODE "LIFE_QUICK_MODE" +#define CONF_DFLT_TYPE_LIFE_QUICK_MODE "SECONDS" +#define CONF_DFLT_VAL_LIFE_QUICK_MODE "1200,60:86400" + +#define CONF_DFLT_VAL_BLF_KEYLEN "128,96:192" + +#define CONF_DFLT_RETRANSMITS "3" +#define CONF_DFLT_EXCH_MAX_TIME "120" +#define CONF_DFLT_POLICY_FILE "/etc/isakmpd/isakmpd.policy" + +#define CONF_DFLT_X509_CA_DIR "/etc/isakmpd/ca/" +#define CONF_DFLT_X509_CERT_DIR "/etc/isakmpd/certs/" +#define CONF_DFLT_X509_PRIVATE_KEY "/etc/isakmpd/private/local.key" + struct conf_list_node { TAILQ_ENTRY (conf_list_node) link; char *field; @@ -69,6 +88,7 @@ extern int conf_match_num (char *, char *, int); extern void conf_reinit (void); extern int conf_remove (int, char *, char *); extern int conf_remove_section (int, char *); -extern int conf_set (int, char *, char *, char *, int); +extern int conf_set (int, char *, char *, char *, int, int); +extern void conf_report (void); #endif /* _CONF_H_ */ diff --git a/sbin/isakmpd/ui.c b/sbin/isakmpd/ui.c index baca4f6d128..22d07ad48cf 100644 --- a/sbin/isakmpd/ui.c +++ b/sbin/isakmpd/ui.c @@ -1,5 +1,5 @@ -/* $OpenBSD: ui.c,v 1.15 2000/04/07 22:10:30 niklas Exp $ */ -/* $EOM: ui.c,v 1.40 2000/04/07 22:05:57 niklas Exp $ */ +/* $OpenBSD: ui.c,v 1.16 2000/05/02 14:37:00 niklas Exp $ */ +/* $EOM: ui.c,v 1.41 2000/05/01 20:57:33 niklas Exp $ */ /* * Copyright (c) 1998, 1999, 2000 Niklas Hallqvist. All rights reserved. @@ -147,7 +147,7 @@ ui_config (char *cmd) if (sscanf (cmd, "C %*s [%80[^]]]:%80[^=]=%80s %d", section, tag, value, &override) != 4) goto fail; - conf_set (trans, section, tag, value, override); + conf_set (trans, section, tag, value, override, 0); } else if (strcasecmp (subcmd, "rm") == 0) { @@ -235,6 +235,7 @@ ui_report (char *cmd) transport_report (); connection_report (); timer_report (); + conf_report (); } /* |