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 MFC after: 1 week
This commit is contained in:
parent
39bbca6ffd
commit
cd48d883bd
@ -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;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user