Store shorter soft lifetime of in- and outbound SAs only
This commit is contained in:
1 parent
7a5f372c57
commit
106b938b6b
1 file changed
+8
-1
@@ -632,7 +632,14 @@ METHOD(child_sa_t, install, status_t,
|
|||||||
now = time_monotonic(NULL);
|
now = time_monotonic(NULL);
|
||||||
if (lifetime->time.rekey)
|
if (lifetime->time.rekey)
|
||||||
{
|
{
|
||||||
this->rekey_time = now + lifetime->time.rekey;
|
if (this->rekey_time)
|
||||||
|
{
|
||||||
|
this->rekey_time = min(this->rekey_time, now + lifetime->time.rekey);
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
this->rekey_time = now + lifetime->time.rekey;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (lifetime->time.life)
|
if (lifetime->time.life)
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in new issue
Block a user