charon-cmd: Only use loose identity matching if no IDr is configured
This commit is contained in:
@@ -247,8 +247,9 @@ static void add_auth_cfg(private_cmd_connection_t *this, peer_cfg_t *peer_cfg,
|
||||
else
|
||||
{
|
||||
id = identification_create_from_string(this->host);
|
||||
/* only use this if remote ID was not configured explicitly */
|
||||
auth->add(auth, AUTH_RULE_IDENTITY_LOOSE, TRUE);
|
||||
}
|
||||
auth->add(auth, AUTH_RULE_IDENTITY_LOOSE, TRUE);
|
||||
}
|
||||
auth->add(auth, AUTH_RULE_IDENTITY, id);
|
||||
peer_cfg->add_auth_cfg(peer_cfg, auth, local);
|
||||
|
||||
Reference in New Issue
Block a user