From 3a820148dcfb028436f6bf6c1455a37bc6eccc9e Mon Sep 17 00:00:00 2001 From: Daniel Hokka Zakrisson Date: Mon, 5 May 2008 17:24:19 +0000 Subject: [PATCH] Add hack to workaround "audit_log_user_command(): Connection refused" from sudo. --- kernel-2.6.spec | 1 + linux-2.6-640-netlink-audit-hack.patch | 15 +++++++++++++++ 2 files changed, 16 insertions(+) create mode 100644 linux-2.6-640-netlink-audit-hack.patch diff --git a/kernel-2.6.spec b/kernel-2.6.spec index 606cd11b7..ccb94c422 100644 --- a/kernel-2.6.spec +++ b/kernel-2.6.spec @@ -172,6 +172,7 @@ Patch580: linux-2.6-580-show-proc-virt.patch Patch590: linux-2.6-590-chopstix-intern.patch Patch620: linux-2.6-620-kdb.patch Patch630: linux-2.6-630-sched-fix.patch +Patch640: linux-2.6-640-netlink-audit-hack.patch # See also the file named 'sources' here for the related checksums # NOTE. iwlwifi should be in-kernel starting from 2.6.24 diff --git a/linux-2.6-640-netlink-audit-hack.patch b/linux-2.6-640-netlink-audit-hack.patch new file mode 100644 index 000000000..ad2f1d23a --- /dev/null +++ b/linux-2.6-640-netlink-audit-hack.patch @@ -0,0 +1,15 @@ +diff -Nurp linux-2.6.22-630/net/netlink/af_netlink.c linux-2.6.22-640/net/netlink/af_netlink.c +--- linux-2.6.22-630/net/netlink/af_netlink.c 2008-04-09 18:46:27.000000000 +0200 ++++ linux-2.6.22-640/net/netlink/af_netlink.c 2008-05-05 19:20:02.000000000 +0200 +@@ -426,6 +426,11 @@ static int netlink_create(struct socket + if (protocol<0 || protocol >= MAX_LINKS) + return -EPROTONOSUPPORT; + ++#ifndef CONFIG_AUDIT ++ if (protocol == NETLINK_AUDIT) ++ return -EPROTONOSUPPORT; ++#endif ++ + netlink_lock_table(); + #ifdef CONFIG_KMOD + if (!nl_table[protocol].registered) { -- 2.43.0