From 9c4d10c7aede6c549d5c6d56404fe182bd75d0ec Mon Sep 17 00:00:00 2001 From: Filip Tehlar Date: Wed, 19 Aug 2020 07:54:08 +0000 Subject: ikev2: use remote proposals when installing tunnel Type: fix Change-Id: Ia1556aa854fa83fb5340308c4eec868b7b4f8351 Signed-off-by: Filip Tehlar --- src/plugins/ikev2/ikev2.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/plugins/ikev2') diff --git a/src/plugins/ikev2/ikev2.c b/src/plugins/ikev2/ikev2.c index 5ae1c0c24d0..cc45d14b56f 100644 --- a/src/plugins/ikev2/ikev2.c +++ b/src/plugins/ikev2/ikev2.c @@ -1498,7 +1498,7 @@ ikev2_create_tunnel_interface (vnet_main_t * vnm, ikev2_sa_t * sa, { a.local_ip.ip4.as_u32 = sa->iaddr.as_u32; a.remote_ip.ip4.as_u32 = sa->raddr.as_u32; - proposals = child->i_proposals; + proposals = child->r_proposals; a.local_spi = child->r_proposals[0].spi; a.remote_spi = child->i_proposals[0].spi; } @@ -1506,7 +1506,7 @@ ikev2_create_tunnel_interface (vnet_main_t * vnm, ikev2_sa_t * sa, { a.local_ip.ip4.as_u32 = sa->raddr.as_u32; a.remote_ip.ip4.as_u32 = sa->iaddr.as_u32; - proposals = child->r_proposals; + proposals = child->i_proposals; a.local_spi = child->i_proposals[0].spi; a.remote_spi = child->r_proposals[0].spi; } -- cgit 1.2.3-korg