diff options
author | Hans-Joerg Hoexer <hshoexer@cvs.openbsd.org> | 2006-06-02 05:59:32 +0000 |
---|---|---|
committer | Hans-Joerg Hoexer <hshoexer@cvs.openbsd.org> | 2006-06-02 05:59:32 +0000 |
commit | 5f914c0eb1f34f923c5251126ed6a7d2c8663c0d (patch) | |
tree | ed2fb03d3cbcb65638b066a806553fd6c9892616 /sbin/ipsecctl/ike.c | |
parent | ad578685d095c60c83441c0b5e2a4fd1e9d18f35 (diff) |
allow to specify phase 1 and 2 lifetimes. Right now, these values
can only be set globally (ie. Default-phase-[12]-lifetime).
Diffstat (limited to 'sbin/ipsecctl/ike.c')
-rw-r--r-- | sbin/ipsecctl/ike.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/sbin/ipsecctl/ike.c b/sbin/ipsecctl/ike.c index 795577ede8c..095f3ee7024 100644 --- a/sbin/ipsecctl/ike.c +++ b/sbin/ipsecctl/ike.c @@ -1,4 +1,4 @@ -/* $OpenBSD: ike.c,v 1.34 2006/06/02 03:40:26 hshoexer Exp $ */ +/* $OpenBSD: ike.c,v 1.35 2006/06/02 05:59:31 hshoexer Exp $ */ /* * Copyright (c) 2005 Hans-Joerg Hoexer <hshoexer@openbsd.org> * @@ -72,6 +72,12 @@ ike_section_general(struct ipsec_rule *r, FILE *fd) fprintf(fd, SET "[General]:DPD-check-interval=%d force\n", CONF_DFLT_DYNAMIC_DPD_CHECK_INTERVAL); } + if (r->mmlife && r->mmlife->lifetime != -1) + fprintf(fd, SET "[General]:Default-phase-1-lifetime=%d force\n", + r->mmlife->lifetime); + if (r->qmlife && r->mmlife->lifetime != -1) + fprintf(fd, SET "[General]:Default-phase-2-lifetime=%d force\n", + r->qmlife->lifetime); } static void |