lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [day] [month] [year] [list]
Date:   Tue, 25 Oct 2022 14:42:54 -0700
From:   Stephen Hemminger <stephen@...workplumber.org>
To:     netdev@...r.kernel.org
Cc:     Stephen Hemminger <stephen@...workplumber.org>
Subject: [RFC iproute2] ip: revert including new features in all cases

The problem is ip commands built from latest version still have to
run on older kernels.  Running current "ip monitor" on older
kernels would fail because it could not add the group for stats
since rtnl group for stats was not added until 5.18 kernel.

The proposed solution is to revert the inclusion of new features
that could be rejected by older kernels from the default "all"
setting of ip monitor.

This effectively reverts commit 4e8a9914c4d459be57ddedf1df35b315e7fea8a5.

Signed-off-by: Stephen Hemminger <stephen@...workplumber.org>
---
 ip/ipmonitor.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/ip/ipmonitor.c b/ip/ipmonitor.c
index 8a72ea42db73..ea91166b5fe9 100644
--- a/ip/ipmonitor.c
+++ b/ip/ipmonitor.c
@@ -190,7 +190,12 @@ static int accept_msg(struct rtnl_ctrl_data *ctrl,
 #define IPMON_LNSID		BIT(9)
 #define IPMON_LNEXTHOP		BIT(10)
 
-#define IPMON_L_ALL		(~0)
+/* All only includes those bit supported by older kernels */
+#define IPMON_L_ALL	(IPMON_LLINK | IPMON_LADDR |	\
+			 IPMON_LROUTE | IPMON_LMROUTE | \
+			 IPMON_LPREFIX | IPMON_LNEIGH |	\
+			 IPMON_LNETCONF | IPMON_LRULE | \
+			 IPMON_LNSID)
 
 int do_ipmonitor(int argc, char **argv)
 {
-- 
2.35.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ