]> git.ipfire.org Git - thirdparty/strongswan.git/blobdiff - src/libcharon/sa/ikev2/tasks/ike_auth.c
ike: Optionally allow private algorithms for IKE/CHILD_SAs
[thirdparty/strongswan.git] / src / libcharon / sa / ikev2 / tasks / ike_auth.c
index f95ec5c55bf9249c203d4b5c8eb1a4019af1f337..6448d8baa9ce165be12491f46dadf80e9aa251a3 100644 (file)
@@ -330,7 +330,9 @@ static bool load_cfg_candidates(private_ike_auth_t *this)
        my_id = this->ike_sa->get_my_id(this->ike_sa);
        other_id = this->ike_sa->get_other_id(this->ike_sa);
        ike_proposal = this->ike_sa->get_proposal(this->ike_sa);
-       private = this->ike_sa->supports_extension(this->ike_sa, EXT_STRONGSWAN);
+       private = this->ike_sa->supports_extension(this->ike_sa, EXT_STRONGSWAN) ||
+                         lib->settings->get_bool(lib->settings, "%s.accept_private_algs",
+                                                                         FALSE, lib->ns);
 
        DBG1(DBG_CFG, "looking for peer configs matching %H[%Y]...%H[%Y]",
                 me, my_id, other, other_id);