Nagios Login & Brute Force

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
Locked
balia
Posts: 6
Joined: Mon Sep 09, 2013 1:16 pm

Nagios Login & Brute Force

Post by balia »

After I installed Nagios on a server, I notice that Nagios is accessed from a webbrowser.
Does Nagios offer any kind of protection against brute force attacks by limiting the number of login attempts?
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Nagios Login & Brute Force

Post by sreinhardt »

Considering nagios core uses htpasswd files, no it does not prevent this. However your nagios server should not ideally be allowed external internet access anyway. There are also apache modules that you can use to prevent some issues too.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
balia
Posts: 6
Joined: Mon Sep 09, 2013 1:16 pm

Re: Nagios Login & Brute Force

Post by balia »

Are there per application firewall rules on linux?
How would you block Nagios from the internet?
sreinhardt
-fno-stack-protector
Posts: 4366
Joined: Mon Nov 19, 2012 12:10 pm

Re: Nagios Login & Brute Force

Post by sreinhardt »

Yes you can lock down apache to only allow specific hosts to connect and deny the rest. Additionally to "block" nagios from the internet, simply do not forward a port from your border firewall to the nagios web interface. You do not need to stop nagios from reaching the internet entirely, you need to not allow external sources to access your internal nagios machine. Also you can setup IPtables as a local firewall on the nagios machine to block incoming and outgoing network connections.
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
balia
Posts: 6
Joined: Mon Sep 09, 2013 1:16 pm

Re: Nagios Login & Brute Force

Post by balia »

Doesn't what you recommend require isolating the machine from the network and the internet?

If the machine hosts a website, locking down apache will prevent all users from accessing the website.
The same goes for setting up the iptables to block all incoming and outgoing network traffic.
Lastly, when I accessed Nagios from the browser, I did it from port 80.
Is there a way to restrict Nagios to a specific port?
slansing
Posts: 7698
Joined: Mon Apr 23, 2012 4:28 pm
Location: Travelling through time and space...

Re: Nagios Login & Brute Force

Post by slansing »

Well unless those users are not behind the firewall they should be able to access it, as spenser is suggestion firewall level solutions which would make sense for the case you stated. Yes, you can lock nagios to a specific port that is once again done in Apache on vhosts as Apache serves the webpages.
Locked