implemented reauthentication using the new reauth=yes|no parameter

This commit is contained in:
Martin Willi
2006-12-19 07:30:07 +00:00
parent 4986554f1a
commit 6fe03b0af0
20 changed files with 210 additions and 67 deletions
+1
View File
@@ -190,6 +190,7 @@ static const token_info_t token_info[] =
{ ARG_ULNG, offsetof(starter_conn_t, sa_keying_tries), NULL },
{ ARG_PCNT, offsetof(starter_conn_t, sa_rekey_fuzz), NULL },
{ ARG_MISC, 0, NULL /* KW_REKEY */ },
{ ARG_MISC, 0, NULL /* KW_REAUTH */ },
{ ARG_STR, offsetof(starter_conn_t, ike), NULL },
{ ARG_STR, offsetof(starter_conn_t, esp), NULL },
{ ARG_STR, offsetof(starter_conn_t, pfsgroup), LST_pfsgroup },
+5 -1
View File
@@ -67,7 +67,8 @@ static void default_values(starter_config_t *cfg)
cfg->conn_default.seen = LEMPTY;
cfg->conn_default.startup = STARTUP_NO;
cfg->conn_default.state = STATE_IGNORE;
cfg->conn_default.policy = POLICY_ENCRYPT | POLICY_TUNNEL | POLICY_RSASIG | POLICY_PFS;
cfg->conn_default.policy = POLICY_ENCRYPT | POLICY_TUNNEL | POLICY_RSASIG |
POLICY_PFS | POLICY_REAUTH;
cfg->conn_default.ike = clone_str(ike_defaults, "ike_defaults");
cfg->conn_default.esp = clone_str(esp_defaults, "esp_defaults");
@@ -447,6 +448,9 @@ load_conn(starter_conn_t *conn, kw_list_t *kw, starter_config_t *cfg)
case KW_REKEY:
KW_POLICY_FLAG("no", "yes", POLICY_DONT_REKEY)
break;
case KW_REAUTH:
KW_POLICY_FLAG("yes", "no", POLICY_REAUTH)
break;
case KW_MODECONFIG:
KW_POLICY_FLAG("push", "pull", POLICY_MODECFG_PUSH)
break;
+10 -1
View File
@@ -733,12 +733,21 @@ and
The two ends need not agree,
but while a value of
.B no
prevents Pluto from requesting renegotiation,
prevents Pluto/Charon from requesting renegotiation,
it does not prevent responding to renegotiation requested from the other end,
so
.B no
will be largely ineffective unless both ends agree on it.
.TP
.B reauth
whether rekeying of an IKE_SA should also reauthenticate the peer. In IKEv1,
reauthentication is always done. In IKEv2, a value of
.B no
rekeys without uninstalling the IPsec SAs, a value of
.B yes
(the default) creates a new IKE_SA from scratch and tries to recreate
all IPsec SAs.
.TP
.B rekeyfuzz
maximum percentage by which
.B rekeymargin
+1
View File
@@ -73,6 +73,7 @@ typedef enum {
KW_KEYINGTRIES,
KW_REKEYFUZZ,
KW_REKEY,
KW_REAUTH,
KW_IKE,
KW_ESP,
KW_PFSGROUP,
+1
View File
@@ -62,6 +62,7 @@ ikelifetime, KW_IKELIFETIME
keyingtries, KW_KEYINGTRIES
rekeyfuzz, KW_REKEYFUZZ
rekey, KW_REKEY
reauth, KW_REAUTH
esp, KW_ESP
ike, KW_IKE
pfsgroup, KW_PFSGROUP
+1
View File
@@ -205,6 +205,7 @@ int starter_stroke_add_conn(starter_conn_t *conn)
}
else
{
msg.add_conn.rekey.reauth = (conn->policy & POLICY_REAUTH);
msg.add_conn.rekey.ipsec_lifetime = conn->sa_ipsec_life_seconds;
msg.add_conn.rekey.ike_lifetime = conn->sa_ike_life_seconds;
msg.add_conn.rekey.margin = conn->sa_rekey_margin;