ike: reuse the reqid of an installed trap having the same config
When we have a trap installed, but a CHILD_SA gets established for the same config from the peer, we should reuse the same reqid. Otherwise we would have two identical policies using different reqids, what we can't handle in our kernel backend.
This commit is contained in:
@@ -1149,7 +1149,11 @@ child_sa_t * child_sa_create(host_t *me, host_t* other,
|
||||
}
|
||||
else
|
||||
{
|
||||
this->reqid = ref_get(&reqid);
|
||||
this->reqid = charon->traps->find_reqid(charon->traps, config);
|
||||
if (!this->reqid)
|
||||
{
|
||||
this->reqid = ref_get(&reqid);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user