Initiate IKE_ANY configurations with IKEv2
authorMartin Willi <martin@revosec.ch>
Sat, 17 Dec 2011 13:26:04 +0000 (14:26 +0100)
committerMartin Willi <martin@revosec.ch>
Tue, 20 Mar 2012 16:31:25 +0000 (17:31 +0100)
src/libcharon/sa/ike_sa.c

index cb560cd..04524b3 100644 (file)
@@ -2042,6 +2042,11 @@ ike_sa_t * ike_sa_create(ike_sa_id_t *ike_sa_id, bool initiator,
        private_ike_sa_t *this;
        static u_int32_t unique_id = 0;
 
+       if (version != IKEV1)
+       {
+               version = IKEV2;
+       }
+
        INIT(this,
                .public = {
                        .get_version = _get_version,