[PATCH 2.6.27-rc9] af_key: fix SADB_X_SPDDELETE response
From: Tobias Brunner
Date: Thu Oct 09 2008 - 08:37:40 EST
When deleting an SPD entry using SADB_X_SPDDELETE, c.data.byid is not
initialized to zero in pfkey_spddelete(). Thus, key_notify_policy()
responds with a PF_KEY message of type SADB_X_SPDDELETE2 instead of
SADB_X_SPDDELETE.
Signed-off-by: Tobias Brunner <tobias.brunner@xxxxxxxxxxxxxx>
--- a/net/key/af_key.c 2008-10-09 13:10:04.000000000 +0200
+++ b/net/key/af_key.c 2008-10-09 13:49:11.000000000 +0200
@@ -2317,6 +2317,7 @@
c.seq = hdr->sadb_msg_seq;
c.pid = hdr->sadb_msg_pid;
+ c.data.byid = 0;
c.event = XFRM_MSG_DELPOLICY;
km_policy_notify(xp, pol->sadb_x_policy_dir-1, &c);
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/