lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Date:	Mon, 11 Jan 2010 17:24:04 +0200
From:	Alex Badea <>
Cc:, Alex Badea <>
Subject: [PATCH iproute2] ip xfrm policy: allow different tmpl family

Allow tmpl IP addresses to have a different family than
selector addresses.  This is useful in conjunction with

Signed-off-by: Alex Badea <>

Rather than resetting preferred_family unconditionally, we could
have a new optional keyword for TMPL, e.g. "ip xfrm policy add ...
tmpl unspec mode tunnel ...".  Let me know if that would be preferred.

 ip/xfrm_policy.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/ip/xfrm_policy.c b/ip/xfrm_policy.c
index 11116e5..2788477 100644
--- a/ip/xfrm_policy.c
+++ b/ip/xfrm_policy.c
@@ -201,10 +201,10 @@ static int xfrm_tmpl_parse(struct xfrm_user_tmpl *tmpl,
 			idp = *argv;
+			preferred_family = AF_UNSPEC;
 			xfrm_id_parse(&tmpl->saddr, &tmpl->id, &tmpl->family,
 				      0, &argc, &argv);
-			if (preferred_family == AF_UNSPEC)
-				preferred_family = tmpl->family;
+			preferred_family = tmpl->family;
 		if (!NEXT_ARG_OK())

To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to
More majordomo info at

Powered by blists - more mailing lists