The establishment and application of anonymous FTP server

Source: Internet
Author: User
Tags anonymous ftp

When you try to connect to a remote computer using FTP, the remote system asks you for a username and password, and it is almost impossible to require each user to request an account for each server system on the vast Internet. The Internet offers an excellent solution-anonymous service, which allows users to access even if they do not have an account on their computer. It only requires typing anonymous service account name, as for password information, the system will give you some prompts, you just follow the prompts to enter the relevant information. The establishment of anonymous FTP service may be slightly different under different operating system environments, and the following example introduces the establishment and application of anonymous FTP server in UNIX environment.

First, how to create an anonymous FTP server

1. Add new user FTP, set its home directory for any user has no write permission;

2. Create a new group Anonymou, it can only be used by anonymous FTP;

3. Create a bin directory under the FTP user's home directory, which belongs to the root user and cannot be written to any user;

4. Create a etc directory in the FTP user's home directory, it belongs to root user, and can not write to any user;

5. Create a public directory under the FTP user's home directory, which belongs to the FTP user and can be written to any user. If you do not allow other users to have storage capabilities on your computer for security reasons, you can set their permissions to 555;

6. Put the LS program into the created bin directory, and modify it to 111 mode, that is, to any user can only execute;

7. Create passwd and group two files in the ETC directory that you have created, and set them to 444 ways (read-only).

Second, create anonymous FTP----Log on under Unix with Root, and then follow the steps below to establish an FTP server gradually.

1. Establish a new group of Anonymou----#mkgroupanonymou

2. Create new user FTP, and FTP users belong to the Anonymou group----#mkuserpgrp = ' Nonymou ' home= '/u/anonymou ' ftp

3. Create the relevant directory under the user directory

  #cd/u/anonymou
  #mkdiretc
  #mkdirbin
  #mkdirpublic

4. Copy ls to/usr/anonymou/bin and set its read and write properties

  #cp/bin/ls./bin
  #chmod111./bin/ls

5. Create the/u/anonymou/etc/group file----Add one line to the file: anonymou:!:201:

6. Create a/U/ANONYMOU/ETC/PASSWD file----add one line to the file:

  ftp:*:213:201::/u/anonymou:/bin/ksh

7. Modify the properties of/u/anonymou/etc/group and/u/anonymou/etc/passwd files

  #chmod444/u/anonymou/etc/passwd----#chmod444/u/anonymou/etc/group

8. Set the way to read and write each subdirectory under the home directory

  #chownftppublic
  #chmod555public
  #chmod555bin
  #chmod555etc
  #cd..
  #chmod555anonymou

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.