quick-mode: Make sure we have a proposal before determining lifetimes
Fixes: e0dd36c9c7 ("ikev1: Get and set the lifetimes of the selected proposal/transform")
This commit is contained in:
@@ -1147,9 +1147,6 @@ METHOD(task_t, process_r, status_t,
|
|||||||
flags);
|
flags);
|
||||||
list->destroy_offset(list, offsetof(proposal_t, destroy));
|
list->destroy_offset(list, offsetof(proposal_t, destroy));
|
||||||
|
|
||||||
get_lifetimes(this);
|
|
||||||
apply_lifetimes(this, sa_payload);
|
|
||||||
|
|
||||||
if (!this->proposal)
|
if (!this->proposal)
|
||||||
{
|
{
|
||||||
DBG1(DBG_IKE, "no matching proposal found, sending %N",
|
DBG1(DBG_IKE, "no matching proposal found, sending %N",
|
||||||
@@ -1158,6 +1155,9 @@ METHOD(task_t, process_r, status_t,
|
|||||||
}
|
}
|
||||||
this->spi_i = this->proposal->get_spi(this->proposal);
|
this->spi_i = this->proposal->get_spi(this->proposal);
|
||||||
|
|
||||||
|
get_lifetimes(this);
|
||||||
|
apply_lifetimes(this, sa_payload);
|
||||||
|
|
||||||
if (!get_nonce(this, &this->nonce_i, message))
|
if (!get_nonce(this, &this->nonce_i, message))
|
||||||
{
|
{
|
||||||
return send_notify(this, INVALID_PAYLOAD_TYPE);
|
return send_notify(this, INVALID_PAYLOAD_TYPE);
|
||||||
|
|||||||
Reference in New Issue
Block a user