Finish my Denyhosts package [$20]
-
Yep. When I tried to get denyhosts working on 1.2.2 I used the packages-7-stable location. For some odd reason I kept getting an error that was asking for some lib file.
Anyway if you want you can check out my 1.2.2 install script and my 1.2.3 script to see what I was doing. So far I can only get it working on 1.2.3.
http://www.tomschaefer.org/temp/pfsense/denyhosts/ -
Just out of curiosity…Does this modify a rule on the firewall..like an aliase and update it with a list of IP's or does it query a list out on the net?
Are you able to create a white list?
-
Hello, it does not modify rules on the firewall. All hosts are checked against the /etc/hosts.deniedssh for access. By default everyone is allowed.
When the system log shows that someone attempted to access ssh or web access many times with a wrong password they are blocked.The list of IP can be updated from a net list located on http://xmlrpc.denyhosts.net:9911 but this is optional. You can configure this in the config file.
To create a white list just add a host to the hosts.allow file in the format of "ALL : ALL : allow". For example: "sshd : 192.168.1.100 : allow" will whitelist host 100 for ssh access.
-
tommyboy180: I sent a private message to you. I haven't seen a response yet.
-
Bounty Still in progress.
-
Did you respond to mcrane's private message? It sounded like he was interested in taking up the bounty.
-
Yes I did. I even had the privilege to speak with him on the phone one morning about a month ago. Mcrane has agreed to help me build this package after he has finished some other projects.
We may see this package soon, hopfully.
-
Sorry for the delay I will try to get this done soon.
-
Another alternative is denyssh. It's designed for use on FreeBSD with PF. I don't think it's as well maintained or as popular as DenyHosts though.
Keep in mind that pfSense already has sshlockout_pf as well (at least in v1.2). It looks like syslog runs all of its entries through sshlockout_pf. If an entry indicates some kind of ssh login failure, the originating IP is added to the sshlockout table. There is a rule that drops everything from any addresses in the sshlockout table. Every 60 minutes, the sshlockout table is emptied by a cron rule.
Perhaps the DenyHosts package should disable the sshlockout_pf mechanism when it's installed (?).
-
Denyhosts is still the way to go. Its the better choice and its already ported for FreeBSD.
I took a look at sshlockout_pf. Tested a default install of pfsense 1.2.3 July build and I was able to bruteforce ssh. Nothing locked me out, the only thing that did happen was after 5 failed attempts pfsense closed the connection but a new one could be established everytime. There is defintly a need for a denyhosts package. I am hoping the package will be created soon.
I also found this link for the people that are installing denyhosts with pkg_add -
Newer builds of pfSense 1.2.3+ should be ok with functional sshlockout_pf.
-
Yes sir. I took a look at the other day. However, it is nowhere near the functionality of Denyhosts. [EDIT I still can bruteforce my way into the latest build of 1.2.3]
The one thing that I really love about denyhosts is the option to get and send bad IPs from a central Database. If an IP is attacking you, you can opt in to send that IP to the denyhosts database so millions of other denyhosts users will block that IP with a list update. The same thing the other way around, denyhosts will download a list with IPs that attacked other people and prevent them from attacking you.Denyhosts doesn't just protect SSH, it also monitors http and more. All auth that occurs on the box is actively monitored.
-
tommyboy i said newer snapshots and there hasn't been one after my post.
-
My apologies
-
I started working on the package yesterday. I should have a basic version out soon. May have some questions to ask you to speed the development along.
Mark
-
The DenyHosts package is now available for pfSense 1.2.3 and higher. Please test it and let me know the results.
Best Regards,
Mark J Crane
-
Ok, I am testing now.
When you uninstall the package it does not restore the original hosts.allow entires
The package doesn't seems to want to start and I cannot figure out why, the service reports down in the service tab in the GUI. -
When you uninstall the package it does not restore the original hosts.allow entires
I just updated the package.
Now when the pfsense denyhosts 0.5 package is installed now it makes a copy of the hosts.allow file and saves it to hosts.allow.bak. When the package is deleted from the pfSense GUI then it saves the hosts.allow.bak file back to the hosts.allow file.
The package doesn't seems to want to start and I cannot figure out why, the service reports down in the service tab in the GUI.
The FreeBSD denyhosts package was not installing. I've done some additional work on it and it now seems to install okay. Please test and confirm.
Best Regards,
Mark J Crane
-
Ok. I looked at it, as far as I can tell its working fine.
Great work. Please send me a PM where I can send the money and complete the bounty. :)
-
This package doesn't work on Nano-BSD? I'm getting some errors. If you say it should run on this platform I can post the errors.