oj Posted August 13, 2007 Share Posted August 13, 2007 heya guys, ive hit a wall, thought id ask for help and here i am. My problem is that im trying to update my iptables firewall useing a command that works in a terminal but not written into a page useing the system() or exec() commands. i am useing apache ID'd as apache useing sudo NOPASSWD: ALL option opposed to running apache as root and having to recompile the source with the special option (which i cant get to work, but thats for another thread). my script is a one liner. <?php system('/usr/bin/sudo /sbin/iptables -I INPUT 1 -s 1.1.1.1/32 -d 192.168.156.51 -p all -j ACCEPT'); ?> This is all thats stopping me from finishing this site module, Thanks in advance Link to comment https://forums.phpfreaks.com/topic/64610-adjusting-iptables-useing-exec-or-system/ Share on other sites More sharing options...
oj Posted August 21, 2007 Author Share Posted August 21, 2007 NoOne? ok. this thread is over. nvm :-X Link to comment https://forums.phpfreaks.com/topic/64610-adjusting-iptables-useing-exec-or-system/#findComment-330422 Share on other sites More sharing options...
trq Posted August 21, 2007 Share Posted August 21, 2007 What results are you getting? Link to comment https://forums.phpfreaks.com/topic/64610-adjusting-iptables-useing-exec-or-system/#findComment-330424 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.