only one IP adress for directadmin

peacock

New member
Joined
Jul 7, 2015
Messages
2
I know this question has been asked many times before. I do think I implemented it right but it doesn't work yet.

I want only one IP address to be able to login to direct admin. So I added this line to csf.allow

tcp|in|d=2222|s=ip adress I use and restarted csf and lfd but it doesnt work.

My understanding was that csf.allow works the opposite of the csf.deny . csf.deny file for blocking specific IP's and allow all others, csf.allow allow only listed IP's and deny everything else.
So when I put this line in csf.allow all IP addresses are blocked for port 2222 but the one I added?
So I added an ip address to it which is not mine and I expected that I couldn't login to direct admin (of course I had an ssh session open). But I can still login.
My IP adress isn't in the csf.ignore file also;)


What do I not understand and do wrong?

Thanks in advance!
 
In csf.allow you have to inster just the IP, but keep in mind that the IP you insert will be whitelisted, so, it will have access to all ports and will never get banned if somehow do a bruteforce attack or port scan (and so on).

Regards
 
Hello,

When csf/lfd is installed on directadmin powered server 2222 gets opened in /etc/csf/csf.conf by default. So you need first remove 2222 port from TCP_IN and TCP6_IN and then allow access to 2222 per ip, like you did.
 
Hello,

When csf/lfd is installed on directadmin powered server 2222 gets opened in /etc/csf/csf.conf by default. So you need first remove 2222 port from TCP_IN and TCP6_IN and then allow access to 2222 per ip, like you did.

Thanks, did was the solution!
 
Back
Top