mem-pool: Pass the remote IKE address, to re-acquire() an address during reauth

With make-before-break IKEv2 re-authentication, virtual IP addresses must be
assigned overlapping to the same peer. With the remote IKE address, the backend
can detect re-authentication attempts by comparing the remote host address and
port. This allows proper reassignment of the virtual IP if it is re-requested.

This change removes the mem-pool.reassign_online option, as it is obsolete now.
IPs get automatically reassigned if a peer re-requests the same address, and
additionally connects from the same address and port.
This commit is contained in:
Martin Willi
2015-02-20 13:34:57 +01:00
parent 3676023e54
commit 22e6a06b8c
7 changed files with 87 additions and 55 deletions
+1 -1
View File
@@ -43,7 +43,7 @@ static void assert_acquire(mem_pool_t *pool, char *requested, char *expected,
id = identification_create_from_string("tester");
req = host_create_from_string(requested, 0);
acquired = pool->acquire_address(pool, id, req, operation);
acquired = pool->acquire_address(pool, id, req, operation, NULL);
assert_host(expected, acquired);
DESTROY_IF(acquired);