[sysadmin-bin] PATH is not always correct in cron
- From: Patrick Uiterwijk <puiterwijk src gnome org>
- To: gnome-sysadmin gnome org,commits-list gnome org
- Subject: [sysadmin-bin] PATH is not always correct in cron
- Date: Sat, 28 Jun 2014 15:16:58 +0000 (UTC)
commit 1599ccb38a93f3884a140df6ea6e5c6e487d9c62
Author: Patrick Uiterwijk <puiterwijk redhat com>
Date: Sat Jun 28 11:16:54 2014 -0400
PATH is not always correct in cron
gnomeweb/list-abusers | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/gnomeweb/list-abusers b/gnomeweb/list-abusers
index 579fa3f..6242eec 100755
--- a/gnomeweb/list-abusers
+++ b/gnomeweb/list-abusers
@@ -120,13 +120,13 @@ END {
baninfo="\tShould be banned"
# XXX - IP address is used as-is in the regexp
# XXX - should escape characters like . ? [
- (iptables -nL | grep -q -- "$ipaddr") || ADD_TO_IPTABLES=1
+ (/sbin/iptables -nL | grep -q -- "$ipaddr") || ADD_TO_IPTABLES=1
fi
if [ -n "$ADD_TO_IPTABLES" ]; then
echo "Blocked $ipaddr. hits: $hits, perhour: $perhour" >>/var/log/blocked
baninfo="\tBanned"
# XXX - add mail notification
- iptables -A ABUSERS -s $ipaddr -j REJECT --reject-with icmp-admin-prohibited
+ /sbin/iptables -A ABUSERS -s $ipaddr -j REJECT --reject-with icmp-admin-prohibited
fi
fi
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]