Date: Fri, 10 Nov 2017 11:19:33 +0000 (UTC) From: "Andrey V. Elsukov" <ae@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-stable@freebsd.org, svn-src-stable-11@freebsd.org Subject: svn commit: r325639 - stable/11/sys/netipsec Message-ID: <201711101119.vAABJXKs045457@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: ae Date: Fri Nov 10 11:19:33 2017 New Revision: 325639 URL: https://svnweb.freebsd.org/changeset/base/325639 Log: MFC r325355: Use correct pointer in key_updateaddresses() when updating NAT-T config. key_updateaddresses() is used to update SA addresses and NAT-T configuration in SADB_UPDATE message. This is done using cloning SA content from old SA into new one. But addresses and NAT-T configuration are taking from SADB_UPDATE message. Use newsa pointer to set NAT-T properties into cloned SA. PR: 223382 Modified: stable/11/sys/netipsec/key.c Directory Properties: stable/11/ (props changed) Modified: stable/11/sys/netipsec/key.c ============================================================================== --- stable/11/sys/netipsec/key.c Fri Nov 10 09:49:08 2017 (r325638) +++ stable/11/sys/netipsec/key.c Fri Nov 10 11:19:33 2017 (r325639) @@ -5100,7 +5100,7 @@ key_updateaddresses(struct socket *so, struct mbuf *m, newsav->natt = NULL; newsav->sah = sah; newsav->state = SADB_SASTATE_MATURE; - error = key_setnatt(sav, mhp); + error = key_setnatt(newsav, mhp); if (error != 0) goto fail;
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201711101119.vAABJXKs045457>