As a responder, don't start a TRANSACTION request if we expect one from the initiator
authorMartin Willi <martin@revosec.ch>
Fri, 29 Jun 2012 11:40:05 +0000 (13:40 +0200)
committerMartin Willi <martin@revosec.ch>
Fri, 29 Jun 2012 11:40:31 +0000 (13:40 +0200)
src/libcharon/sa/ikev1/tasks/aggressive_mode.c
src/libcharon/sa/ikev1/tasks/main_mode.c

index ec31548..9b5ad18 100644 (file)
@@ -496,7 +496,8 @@ METHOD(task_t, process_r, status_t,
                                                                                this->ike_sa->get_id(this->ike_sa)));
                                        break;
                        }
-                       if (this->peer_cfg->get_virtual_ip(this->peer_cfg))
+                       if (this->peer_cfg->get_pool(this->peer_cfg) == NULL &&
+                               this->peer_cfg->get_virtual_ip(this->peer_cfg))
                        {
                                this->ike_sa->queue_task(this->ike_sa,
                                                        (task_t*)mode_config_create(this->ike_sa, TRUE));
index fc487e1..5392869 100644 (file)
@@ -524,7 +524,8 @@ METHOD(task_t, build_r, status_t,
                                                                                this->ike_sa->get_id(this->ike_sa)));
                                        break;
                        }
-                       if (this->peer_cfg->get_virtual_ip(this->peer_cfg))
+                       if (this->peer_cfg->get_pool(this->peer_cfg) == NULL &&
+                               this->peer_cfg->get_virtual_ip(this->peer_cfg))
                        {
                                this->ike_sa->queue_task(this->ike_sa,
                                                        (task_t*)mode_config_create(this->ike_sa, TRUE));