iptables permission problem in perl scripts
ghenry at suretecsystems.com
Sun Aug 14 10:27:51 CEST 2005
On Sunday 14 Aug 2005 08:34, afshin lamei wrote:
> Dear all,
> I have a cgi script, which uses some perl scripts in which i'm running
> iptables command using "system" function, like this:
> system("iptables -F FORWARD")
> the cgi file is owned by root/root and is run by user nobody.
> myfile.pl is owned by root/root, and I've it setuid (chmod u+s
> myfile.pl ; chown root:nobody myfile.pl) to be able to run iptable
> commands, but it returns this error:
> modprobe: Can't locate module ip_tables.
> iptables v1.2.11: can't initialize iptables table `nat': Permission
> denied (you must be root) perhaps iptables or your kernel needs to be
> what's the solution?
You can grant apache permission or another user etc.
Open Source. Open Solutions(tm).
More information about the netfilter