IKEv1 XAuth: Changed the xauth_request task to use the new MIGRATE status.
authorClavister OpenSource <opensource@clavister.com>
Thu, 24 Nov 2011 15:57:10 +0000 (16:57 +0100)
committerClavister OpenSource <opensource@clavister.com>
Tue, 20 Mar 2012 16:30:52 +0000 (17:30 +0100)
src/libcharon/sa/task_manager_v1.c
src/libcharon/sa/tasks/main_mode.c

index d5474d9..2b22bcd 100644 (file)
@@ -22,6 +22,7 @@
 #include <sa/tasks/ike_vendor.h>
 #include <sa/tasks/main_mode.h>
 #include <sa/tasks/quick_mode.h>
+#include <sa/tasks/xauth_request.h>
 #include <processing/jobs/retransmit_job.h>
 
 typedef struct exchange_t exchange_t;
@@ -536,6 +537,8 @@ static status_t process_request(private_task_manager_t *this,
                                this->passive_tasks->insert_last(this->passive_tasks, task);
                                task = (task_t *)main_mode_create(this->ike_sa, FALSE);
                                this->passive_tasks->insert_last(this->passive_tasks, task);
+                               task = (task_t *)xauth_request_create(this->ike_sa, FALSE);
+                               this->passive_tasks->insert_last(this->passive_tasks, task);
                                break;
                        case AGGRESSIVE:
                                /* TODO-IKEv1: agressive mode */
index d3d1cbe..f592767 100644 (file)
@@ -624,7 +624,7 @@ METHOD(task_t, build_r, status_t,
                        /* TODO-IKEv1: Check the proposal for XAuthInit* auth modes */
                        /* TODO-IKEv1: check for XAUTH rounds, queue them */
                        if(0) /* TODO-IKEv1: Change to 1 if XAUTH is desired. */
-                       this->ike_sa->initiate_xauth(this->ike_sa);
+                               return MIGRATE;
                        return SUCCESS;
                }
                default: