controller: Immediately return after re-initiating an existing IKE_SA childless
If no CHILD_SA is initiated, we wait for a state change to IKE_ESTABLISHED but that will never happen for already established IKE_SAs. References strongswan/strongswan#1553
This commit is contained in:
@@ -475,9 +475,13 @@ METHOD(job_t, initiate_execute, job_requeue_t,
|
|||||||
|
|
||||||
if (ike_sa->initiate(ike_sa, listener->child_cfg, NULL) == SUCCESS)
|
if (ike_sa->initiate(ike_sa, listener->child_cfg, NULL) == SUCCESS)
|
||||||
{
|
{
|
||||||
if (!listener->logger.callback)
|
if (!listener->logger.callback ||
|
||||||
{
|
(!listener->child_cfg &&
|
||||||
|
ike_sa->get_state(ike_sa) != IKE_CONNECTING))
|
||||||
|
{ /* immediately return if we don't block or after re-initiating an
|
||||||
|
* existing IKE_SA childless */
|
||||||
listener->status = SUCCESS;
|
listener->status = SUCCESS;
|
||||||
|
listener_done(listener);
|
||||||
}
|
}
|
||||||
charon->ike_sa_manager->checkin(charon->ike_sa_manager, ike_sa);
|
charon->ike_sa_manager->checkin(charon->ike_sa_manager, ike_sa);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user