Sisyphus repository
Last update: 1 october 2023 | SRPMs: 18631 | Visits: 37535156
en ru br
ALT Linux repos
S:1.8.7-alt1
5.0: 1.4.0-alt4
4.1: 1.4.0-alt0.M41.1
4.0: 1.3.7-alt1
3.0: 1.3.1-alt2

Group :: System/Kernel and hardware
RPM: iptables

 Main   Changelog   Spec   Patches   Sources   Download   Gear   Bugs and FR  Repocop 

Patch: iptables-1.4.0-alt-eperm.patch
Download


--- iptables-1.4.0/ip6tables.c
+++ iptables-1.4.0/ip6tables.c
@@ -1894,11 +1894,12 @@ int do_command6(int argc, char *argv[], char **table, ip6tc_handle_t *handle)
 		*handle = ip6tc_init(*table);
 
 	/* try to insmod the module if iptc_init failed */
+	errno = 0;
 	if (!*handle && load_xtables_ko(modprobe, 0) != -1)
 		*handle = ip6tc_init(*table);
 
 	if (!*handle)
-		exit_error(VERSION_PROBLEM,
+		exit_error(errno == EPERM ? OTHER_PROBLEM : VERSION_PROBLEM,
 			"can't initialize ip6tables table `%s': %s",
 			*table, ip6tc_strerror(errno));
 
--- iptables-1.4.0/iptables.c
+++ iptables-1.4.0/iptables.c
@@ -1957,11 +1957,12 @@ int do_command(int argc, char *argv[], char **table, iptc_handle_t *handle)
 		*handle = iptc_init(*table);
 
 	/* try to insmod the module if iptc_init failed */
+	errno = 0;
 	if (!*handle && load_xtables_ko(modprobe, 0) != -1)
 		*handle = iptc_init(*table);
 
 	if (!*handle)
-		exit_error(VERSION_PROBLEM,
+		exit_error(errno == EPERM ? OTHER_PROBLEM : VERSION_PROBLEM,
 			   "can't initialize iptables table `%s': %s",
 			   *table, iptc_strerror(errno));
 
 
design & coding: Vladimir Lettiev aka crux © 2004-2005, Andrew Avramenko aka liks © 2007-2008
current maintainer: Michael Shigorin