ikev1: Get and set the lifetimes of the selected proposal/transform
[strongswan.git] / src / libcharon / sa / ikev1 / tasks / aggressive_mode.c
index 94c3b76..7314f88 100644 (file)
@@ -415,7 +415,8 @@ METHOD(task_t, process_r, status_t,
                        this->ike_sa->set_proposal(this->ike_sa, this->proposal);
 
                        this->method = sa_payload->get_auth_method(sa_payload);
-                       this->lifetime = sa_payload->get_lifetime(sa_payload);
+                       this->lifetime = sa_payload->get_lifetime(sa_payload,
+                                                                                                         this->proposal);
 
                        switch (this->method)
                        {
@@ -653,7 +654,7 @@ METHOD(task_t, process_i, status_t,
                }
                this->ike_sa->set_proposal(this->ike_sa, this->proposal);
 
-               lifetime = sa_payload->get_lifetime(sa_payload);
+               lifetime = sa_payload->get_lifetime(sa_payload, this->proposal);
                if (lifetime != this->lifetime)
                {
                        DBG1(DBG_IKE, "received lifetime %us does not match configured "