Add a closeaction ipsec.conf keyword to configure close action
This commit is contained in:
1 parent
0eb23d7be2
commit
f34ebc845b
8 files changed
+30
-17
No files matched your search
@@ -228,6 +228,7 @@ static const token_info_t token_info[] =
|
||||
{ ARG_TIME, offsetof(starter_conn_t, dpd_delay), NULL },
|
||||
{ ARG_TIME, offsetof(starter_conn_t, dpd_timeout), NULL },
|
||||
{ ARG_ENUM, offsetof(starter_conn_t, dpd_action), LST_dpd_action },
|
||||
{ ARG_ENUM, offsetof(starter_conn_t, close_action), LST_dpd_action },
|
||||
{ ARG_TIME, offsetof(starter_conn_t, inactivity), NULL },
|
||||
{ ARG_MISC, 0, NULL /* KW_MODECONFIG */ },
|
||||
{ ARG_MISC, 0, NULL /* KW_XAUTH */ },
|
||||
|
||||
@@ -143,6 +143,8 @@ struct starter_conn {
|
||||
dpd_action_t dpd_action;
|
||||
int dpd_count;
|
||||
|
||||
dpd_action_t close_action;
|
||||
|
||||
time_t inactivity;
|
||||
|
||||
bool me_mediation;
|
||||
|
||||
@@ -91,6 +91,7 @@ typedef enum {
|
||||
KW_DPDDELAY,
|
||||
KW_DPDTIMEOUT,
|
||||
KW_DPDACTION,
|
||||
KW_CLOSEACTION,
|
||||
KW_INACTIVITY,
|
||||
KW_MODECONFIG,
|
||||
KW_XAUTH,
|
||||
|
||||
@@ -82,6 +82,7 @@ pfsgroup, KW_PFSGROUP
|
||||
dpddelay, KW_DPDDELAY
|
||||
dpdtimeout, KW_DPDTIMEOUT
|
||||
dpdaction, KW_DPDACTION
|
||||
closeaction, KW_CLOSEACTION
|
||||
inactivity, KW_INACTIVITY
|
||||
modeconfig, KW_MODECONFIG
|
||||
xauth, KW_XAUTH
|
||||
|
||||
@@ -258,6 +258,7 @@ int starter_stroke_add_conn(starter_config_t *cfg, starter_conn_t *conn)
|
||||
msg.add_conn.algorithms.esp = push_string(&msg, conn->esp);
|
||||
msg.add_conn.dpd.delay = conn->dpd_delay;
|
||||
msg.add_conn.dpd.action = conn->dpd_action;
|
||||
msg.add_conn.close_action = conn->close_action;
|
||||
msg.add_conn.inactivity = conn->inactivity;
|
||||
msg.add_conn.ikeme.mediation = conn->me_mediation;
|
||||
msg.add_conn.ikeme.mediated_by = push_string(&msg, conn->me_mediated_by);
|
||||
|
||||
Reference in new issue
Block a user