Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Do I need to run DenyHosts as root?

DenyHosts run
0
Posted

Do I need to run DenyHosts as root?

0

If you are running DenyHosts in daemon mode then yes you must run DenyHosts as root. In all other cases, such as running DenyHosts from cron then technically speaking, no. However, in order to run DenyHosts as non-root you must ensure that you have read-permissions on the /var/log/ sshd server logs. Alternatively, you can copy them to a directory where you do have read-permissions. Also, in order for DenyHosts to block hosts, it needs write permissions for the /etc/hosts.deny file. DenyHosts will gladly run without being able to update this file. In this mode, the hosts that should be blocked are written to stdout (in a form suitable for pasting into /etc/hosts.deny). Also, you can use an alternate HOSTS_DENY file (other than /etc/hosts.deny) which may not require root priviledges.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123