Skip to contentSkip to conversation

pfkey: fix SADB_X_EXT_FILTER length check

PATCH In review Nicolas Dichtel 2 participants 2 messages Feb 20, 2014 – Feb 21, 2014 1 message not in the archive

Subsystems (3)
lore
Share & tools
lore
#1 lore raw

PATCH 1/1 pfkey: fix SADB_X_EXT_FILTER length check

In reply to a message not in the archive

This patch fixes commit d3623099d350 ("ipsec: add support of limited SA dump").

sadb_ext_min_len array should be updated with the new type (SADB_X_EXT_FILTER).

---
 net/key/af_key.c | 1 +
 1 file changed, 1 insertion(+)
net/key/af_key.c +1 -0
index f0879c19f452..a50d979b5926 100644
@@ -365,6 +365,7 @@ static const u8 sadb_ext_min_len[] = {
 	[SADB_X_EXT_NAT_T_OA]		= (u8) sizeof(struct sadb_address),
 	[SADB_X_EXT_SEC_CTX]		= (u8) sizeof(struct sadb_x_sec_ctx),
 	[SADB_X_EXT_KMADDRESS]		= (u8) sizeof(struct sadb_x_kmaddress),
+	[SADB_X_EXT_FILTER]		= (u8) sizeof(struct sadb_x_filter),
 };
 
 /* Verify sadb_address_{len,prefixlen} against sa_family.  */
Signature · 1 line
1.8.5.4