O'Reilly logo

Ubuntu Unleashed 2014 Edition: Covering 13.10 and 14.04,Ninth Edition by Paul Hudson, Andrew Hudson, Matthew Helmke

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Using the ftphosts File to Allow or Deny FTP Server Connection

You can create a file in /etc called ftphosts to allow or deny specific users or addresses from connecting to the FTP server. The format of the file is the word allow or deny, optionally followed by a username, followed by an IP or a DNS address:

allow username addressdeny username address

Listing 26.2 shows a sample configuration of this file.

LISTING 26.2 ftphosts Configuration File for Allowing or Denying Users

# Example host access file## Everything after a '#' is treated as comment,# empty lines are ignoredallow fatima 208.164.186.1 208.164.186.2 208.164.186.4deny richard 208.164.186.5allow jane ubuntuforums.orgdeny john naughtysite.netallow ahmed ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required