Results 1 to 5 of 5
I have been providing ftp server for a closed(to outside) network, and someone is troubling me. I have found the IP adress of the client, and now I want to ...
- 12-08-2006 #1Just Joined!
- Join Date
- Dec 2006
- Location
- Turkiye
- Posts
- 9
How to ban IP in vsftpd
I have been providing ftp server for a closed(to outside) network, and someone is troubling me. I have found the IP adress of the client, and now I want to prevent it from reaching the server, but I don't know how. Can someone help?
- 12-09-2006 #2
Someone on your internal, private network is giving you trouble? Make him sit in the corner for one hour.

You can add a DROP rule for his IP to your iptables INPUT chain. Or you can deny him with the tcp_wrappers mechanism - /etc/hosts.deny.
Both very effective.
- 12-09-2006 #3Just Joined!
- Join Date
- Dec 2006
- Location
- Turkiye
- Posts
- 9
I am new to linux, so can you tell me how to do these?
- 12-09-2006 #4
Depending on how you manage iptables/netfilter, the easier of the two is probably denying with tcp_wrappers.
Step 1
Run the command whereis -b vsftpd. Make a note of the first path it returns. In my case, that is /usr/sbin/vsftpd.
Next, using that path, run the command ldd /usr/sbin/vsftpd | grep 'libwrap.so'. Did you see any results? If so, vsftpd has been compiled with tcp_wrappers support. If not, the rest of the steps won't do anything.
Step 2
Edit /etc/hosts.deny and add a line that looks like:where "10.0.0.1" is the IP of the person you want to deny.Code:vsftpd : 10.0.0.1
That should take care of it. If the person you're trying to deny is sufficiently clever, though, there are probably going to be more steps to take.
- 12-10-2006 #5Just Joined!
- Join Date
- Dec 2006
- Location
- Turkiye
- Posts
- 9
Thank you, that seems to have solved the problem.


Reply With Quote
