Raise alerts when enforcing IKE_SA unique policy
This commit is contained in:
@@ -1769,6 +1769,7 @@ METHOD(ike_sa_manager_t, check_uniqueness, bool,
|
||||
switch (policy)
|
||||
{
|
||||
case UNIQUE_REPLACE:
|
||||
charon->bus->alert(charon->bus, ALERT_UNIQUE_REPLACE);
|
||||
DBG1(DBG_IKE, "deleting duplicate IKE_SA for peer "
|
||||
"'%Y' due to uniqueness policy", other);
|
||||
status = duplicate->delete(duplicate);
|
||||
|
||||
@@ -807,6 +807,7 @@ METHOD(task_t, build_r, status_t,
|
||||
this->ike_sa, FALSE))
|
||||
{
|
||||
DBG1(DBG_IKE, "cancelling IKE_SA setup due to uniqueness policy");
|
||||
charon->bus->alert(charon->bus, ALERT_UNIQUE_KEEP);
|
||||
message->add_notify(message, TRUE, AUTHENTICATION_FAILED,
|
||||
chunk_empty);
|
||||
return FAILED;
|
||||
|
||||
Reference in New Issue
Block a user