ikev1: Pass current auth-cfg when looking for key to determine auth method

If multiple certificates use the same subjects we might choose the wrong
one otherwise. This way we use the one referenced with leftcert and
stored in the auth-cfg and we actually do the same thing later in the
pubkey authenticator.

Fixes #1077.
This commit is contained in:
Tobias Brunner 2015-08-19 17:25:30 +02:00
parent 49a20ef019
commit 47ee60177e
1 changed files with 1 additions and 1 deletions

View File

@ -404,7 +404,7 @@ static auth_method_t get_pubkey_method(private_phase1_t *this, auth_cfg_t *auth)
id = (identification_t*)auth->get(auth, AUTH_RULE_IDENTITY);
if (id)
{
private = lib->credmgr->get_private(lib->credmgr, KEY_ANY, id, NULL);
private = lib->credmgr->get_private(lib->credmgr, KEY_ANY, id, auth);
if (private)
{
switch (private->get_type(private))