iputils: install ping, ping6, traceroute6 with setuid root
authorCarsten Wolff <carsten@wolffcarsten.de>
Sun, 8 Apr 2018 19:39:10 +0000 (21:39 +0200)
committerJo-Philipp Wich <jo@mein.io>
Tue, 22 Jan 2019 08:05:59 +0000 (09:05 +0100)
these utilities need to run with uid 0 to be useful. Thus,
install them setuid root like other distros do, too.

Signed-off-by: Carsten Wolff <carsten@wolffcarsten.de>
[use INSTALL_SUID macro]
Signed-off-by: Jo-Philipp Wich <jo@mein.io>
package/network/utils/iputils/Makefile

index 344af07afd4c23c968d26b8676507bdb6fa7f9f7..03ad7d2031e4a9f1ac7edef2d2f53a5759859946 100644 (file)
@@ -144,12 +144,12 @@ endef
 
 define Package/iputils-ping/install
        $(INSTALL_DIR) $(1)/usr/bin
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/ping $(1)/usr/bin/
+       $(INSTALL_SUID) $(PKG_BUILD_DIR)/ping $(1)/usr/bin/
 endef
 
 define Package/iputils-ping6/install
        $(INSTALL_DIR) $(1)/usr/bin
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/ping6 $(1)/usr/bin/
+       $(INSTALL_SUID) $(PKG_BUILD_DIR)/ping6 $(1)/usr/bin/
 endef
 
 define Package/iputils-tftpd/install
@@ -169,7 +169,7 @@ endef
 
 define Package/iputils-traceroute6/install
        $(INSTALL_DIR) $(1)/usr/bin
-       $(INSTALL_BIN) $(PKG_BUILD_DIR)/traceroute6 $(1)/usr/bin/
+       $(INSTALL_SUID) $(PKG_BUILD_DIR)/traceroute6 $(1)/usr/bin/
 endef
 
 $(eval $(call BuildPackage,iputils-arping))