aboutsummaryrefslogtreecommitdiffstats
path: root/src/charon/plugins/nm/nm_service.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/charon/plugins/nm/nm_service.c')
-rw-r--r--src/charon/plugins/nm/nm_service.c8
1 files changed, 5 insertions, 3 deletions
diff --git a/src/charon/plugins/nm/nm_service.c b/src/charon/plugins/nm/nm_service.c
index 95e4751ed..8df65d7f9 100644
--- a/src/charon/plugins/nm/nm_service.c
+++ b/src/charon/plugins/nm/nm_service.c
@@ -218,6 +218,7 @@ static gboolean connect_(NMVPNPlugin *plugin, NMConnection *connection,
ike_cfg_t *ike_cfg;
peer_cfg_t *peer_cfg;
child_cfg_t *child_cfg;
+ lifetime_cfg_t *lifetime;
traffic_selector_t *ts;
ike_sa_t *ike_sa;
auth_cfg_t *auth;
@@ -426,9 +427,10 @@ static gboolean connect_(NMVPNPlugin *plugin, NMConnection *connection,
auth->add(auth, AUTH_RULE_IDENTITY, gateway);
peer_cfg->add_auth_cfg(peer_cfg, auth, FALSE);
- child_cfg = child_cfg_create(priv->name,
- 10800, 10200, /* lifetime 3h, rekey 2h50min */
- 300, /* jitter 5min */
+ lifetime = lifetime_cfg_create_time(10800 /* 3h */, 10200 /* 2h50min */,
+ 300 /* 5min */);
+
+ child_cfg = child_cfg_create(priv->name, lifetime,
NULL, TRUE, MODE_TUNNEL, /* updown, hostaccess */
ACTION_NONE, ACTION_NONE, ipcomp);
child_cfg->add_proposal(child_cfg, proposal_create_default(PROTO_ESP));