ike-rekey: There is no passive reauth task, so it will never collide with one

This commit is contained in:
Tobias Brunner 2016-05-31 14:35:22 +02:00
parent 724d65900c
commit 7426576184
2 changed files with 4 additions and 7 deletions

View File

@ -761,8 +761,7 @@ static bool handle_collisions(private_task_manager_t *this, task_t *task)
/* do we have to check */
if (type == TASK_IKE_REKEY || type == TASK_CHILD_REKEY ||
type == TASK_CHILD_DELETE || type == TASK_IKE_DELETE ||
type == TASK_IKE_REAUTH)
type == TASK_CHILD_DELETE || type == TASK_IKE_DELETE)
{
/* find an exchange collision, and notify these tasks */
enumerator = array_create_enumerator(this->active_tasks);
@ -771,8 +770,7 @@ static bool handle_collisions(private_task_manager_t *this, task_t *task)
switch (active->get_type(active))
{
case TASK_IKE_REKEY:
if (type == TASK_IKE_REKEY || type == TASK_IKE_DELETE ||
type == TASK_IKE_REAUTH)
if (type == TASK_IKE_REKEY || type == TASK_IKE_DELETE)
{
ike_rekey_t *rekey = (ike_rekey_t*)active;
rekey->collide(rekey, task);

View File

@ -284,9 +284,8 @@ METHOD(task_t, process_i, status_t,
{
case FAILED:
/* rekeying failed, fallback to old SA */
if (!(this->collision && (
this->collision->get_type(this->collision) == TASK_IKE_DELETE ||
this->collision->get_type(this->collision) == TASK_IKE_REAUTH)))
if (!this->collision ||
this->collision->get_type(this->collision) != TASK_IKE_DELETE)
{
schedule_delayed_rekey(this);
}