V
V
Vladislav2015-11-24 18:06:36
iptables
Vladislav, 2015-11-24 18:06:36

Why doesn't www-data ALL=NOPASSWD: /sbin/iptables work?

I want to allow iptables to run from php, I write in sudoers www-data ALL=NOPASSWD: /sbin/iptables? I'm trying to run a script that executes exec("sudo iptables -I INPUT -s 45.117.249.31 -j DROP"); says that there is no permission. How can it be solved?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
S
svd71, 2015-11-24
@svd71

if only because there is a link to the file /sbin/xtables-multi. Then you need to set the rights to it.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question