⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 pure-ftpd.8

📁 功能强大的ftp服务器源代码
💻 8
📖 第 1 页 / 共 2 页
字号:
.TP.B \-xIn normal operation mode, authenticated users can read/write filesbeginning with a dot ('.'). Anonymous users can't, for security reasons(like changing banners or a forgotten .rhosts). When '\-x' is used,authenticated users can download dot\-files, but not overwrite/create them,even if they own them. That way, you can prevent hosted users from messing.qmail files..TP.B \-XThis flag is identical to the previous one (writing dot\-files isprohibited), but in addition, users can't even *read* files and directoriesbeginning with a dot (like "cd .ssh")..TP.B \-y per user max sessions:max anonymous sessionsThis switch enables per-user concurrency limits. Two values are separated by acolumn. The first one is the max number of concurrent sessions for a singlelogin. The second one is the maximum number of anonoymous sessions..TP.B \-Y tls behavior\fB\-Y 0\fR(default) disables SSL/TLS security mechanisms..br\fB\-Y 1\fRAccept both normal sessions and SSL/TLS ones..br\fB\-Y 2\fRrefuses connections that aren't using SSL/TLS security mechanisms, includinganonymous ones..brThe server must have been compiled with SSL/TLS support and a valid certificatemust be in place to accept encrypted sessions..TP.B \-zAllow anonymous users to read files and directories starting with a dot ('.')..TP.B \-ZAdd safe guards against common customer mistakes (like chmod 0 on their own files) ..SH "AUTHENTICATION"Some of the complexities of older servers are left out..PPThis version of pure\-ftpd can use PAM for authentication. If you wan't it toconsult any files like /etc/shells or /etc/ftpd/ftpusers consult pamdocs. LDAP directories and SQL databases are also supported..PPAnonymous users are authenticated in any of three ways:.PP1. The user logs in as "ftp" or "anonymous" and there is anaccount called "ftp" with an existing home directory. This serverdoes not ask anonymous users for an email address or other password..PP2. The user connects to an IP address which resolves to the name of adirectory in.I /etc/pure\-ftpd(or a symlink in that directory to a real directory), and there is anaccount called "ftp" (which does not need to have a valid homedirectory). See.B Virtual Serversbelow..PP.B Ftpddoes a.BR chroot (2)to the relevant base directory when an anonymous user logs in..PPNote that.B ftpdallows remote users to log in as root if the password is known and \-unot used..SH "UNUSUAL FEATURES".B Ftpdnever switches uid and euid, it uses.BR setfsuid (2)instead. The main reason is that uid switching has been exploited inseveral breakins, but the sheer ugliness of uid switching counts too..B Ftpdonly calls.BR setfsuid (2)once, at login..PPIf a user's home directory is \fB/path/to/home/./\fR, FTP sessions under that UID will be chroot()ed. In addition, if a users's home directory is \fB/path/to/home/./directory\fR the session will be chroot()ed to /path/to/home and the FTP session will start in 'directory'..PPAs noted above, this.B pure\-ftpdomits several features that are required by the RFC or might beconsidered useful at first. Here is a list of the most importantomissions..PPOn\-the\-fly tar is not supported, for several reasons. I feel thatusers who want to get many files should use a special FTP client suchas "mirror," which also supports incremental fetch. I don't want toeither add several hundred lines of code to create tar files orexecute an external tar. Finally, on\-the\-fly tar distorts log files..PPOn\-the\-fly compression is left out too. Most files on an FTP site arecompressed already, and if a file isn't, there presumably is a reasonwhy. (As for decompression: Don't FTP users waste bandwidth enoughwithout help from on\-the\-fly decompression?).SH "DIRECTORY ALIASES"Shortcuts for the "cd" command can be set up if the server has been compiledwith the \-\-with\-diraliases feature..PPTo enable directory aliases, create a file called.I /etc/pureftpd\-dir\-aliasesand alternate lines of alias names and associated directories..SH "ANONYMOUS FTP"This server leaves out some of the commands and features that havebeen used to subvert anonymous FTP servers in the past, but still youhave to be a little bit careful in order to support anonymous FTPwithout risk to the rest of your files..PPMake.I ~ftpand all files and directories below this directory owned by some userother than "ftp," and only the.I .../incomingdirectory/directories writable by "ftp." It is probably best if alldirectories are writable only by a special group such as "ftpadmin"and "ftp" is not a member of this group..PPIf you do not trust the local users, put.I ~ftpon a separate partition, so local users can't hard\-link unapprovedfiles into the anonymous FTP area..PPUse of the.B \-soption is strongly suggested. (Simply add "\-s" to the end of the.B ftpdline in.I /etc/inetd.confto enable it.).PPMost other FTP servers require that a number of files such as.I ~ftp/bin/lsexist. This server does not require that any files or directorieswithin.I ~/ftpwhatsoever exist, and I recommend that all such unnecessary files areremoved (for no real reason)..PPIt may be worth considering to run the anonymous FTP service as avirtual server, to get automatic logins and to firewall off the FTPaddress/port to which real users can log in..PPIf your server is a public FTP site, you may want to allow only 'ftp' and 'anonymous' users to log in. Use the.B \-eoption for this. Real accounts will be ignored and you will get a secure, anonymous\-only FTP server..SH "MAGIC FILES"The files.I <ftproot>/.bannerand.I .messageare magical..PIf there is a file called.I .bannerin the root directory of the anonymous FTP area, or in the rootdirectory of a virtual host, and it is shorter than 1024 bytes, it isprinted upon login. (If the client does not log in explicitly, and animplicit login is triggered by a CWD or CDUP command, the banner isnot printed. This is regrettable but hard to avoid.).PIf there is a file called.I .messagein any directory and it is shorter than 1024 bytes, that file isprinted whenever a user enters that directory using CWD or CDUP..SH "VIRTUAL SERVERS"You can run several different anonymous FTP servers on one host, bygiving the host several IP addresses with different DNS names..PPHere are the steps needed to create an extra server using an IP aliason linux 2.4.x, called "ftp.example.com" on address 10.11.12.13. onthe IP alias eth0..PP1. Create an "ftp" account if you do not have one. It it best ifthe account does not have a valid home directory and shell. I preferto make.I /dev/nullthe ftp account's home directory and shell..B Ftpduses this account to set the anonymous users' uid..PP2. Create a directory as described in.B Anonymous FTPand make a symlink called.I /etc/pure\-ftpd/10.11.12.13which points to this directory..PP3. Make sure your kernel has support for IP aliases..PP4. Make sure that the following commands are run at boot:.PP.in +2/sbin/ifconfig eth0:1 10.11.12.13.PPThat should be all. If you have problems, here are some things totry..PPFirst, symlink.I /etc/pure\-ftpd/127.0.0.1to some directory and say "ftp localhost". If that doesn't log youin, the problem is with.B ftpd..PPIf not, "ping \-v 10.11.12.13" and/or "ping \-v ftp.example.com" from thesame host. If this does not work, the problem is with the IP alias..PPNext, try "ping \-v 10.11.12.13" from a host on the local ethernet, andafterwards "/sbin/arp \-a". If 10.11.12.13 is listed among the ARPentries with the correct hardware address, the problem is probablywith the IP alias. If 10.11.12.13 is listed, but has hardware address0:0:0:0:0:0, then proxy\-ARP isn't working..PPIf none of that helps, I'm stumped. Good luck..PP.B Warning:If you setup a virtual hosts, normal users will not be able to login viathis name, so.B don'tcreate link/directory in.I /etc/pure\-ftpdfor your regular hostname..SH "FILES".I /etc/passwdis used via libc (and PAM is this case), to get the uid and homedirectory of normal users, the uid and home directory of "ftp" fornormal anonymous ftp, and just the uid of "ftp" for virtual ftp hosts..PP.I /etc/shadowis used like.I /etc/passwdif shadow support is enabled..PP.I /etc/groupis used via libc, to get the group membership of normal users..PP.I /proc/net/tcpis used to count existing FTP connections, if the.B \-cor.B \-poptions are used.PP.I /etc/pure\-ftpd/<ip address>is the base directory for the <ip address> virtual ftp server, or asymbolic link to its base directory..B Ftpddoes a.BR chroot (2)into this directory when a user logs in to <ip address>, thus symlinksoutside this directory will not work..PP.I ~ftpis the base directory for "normal" anonymous FTP..B Ftpddoes a.BR chroot (2)into this directory when an anonymous user logs in, thus symlinksoutside this directory will not work..SH "LS"The behaviour of LIST and NLST is a tricky issue. Few servers sendRFC\-compliant responses to LIST, and some clients depend onnon\-compliant responses..PPThis server uses.BR glob (3)to do filename globbing..PPThe response to NLST is by default similar to that of.BR ls (1),andthat to LIST is by default similar to that of.B "ls \-l"or.B "ls \-lg"on most Unix systems, except that the "total" count is meaningless.Only regular files, directories and symlinks are shown. Only important.B lsoptions are supported:.TP.B \-1Undoes.BR \-l " and " \-C ..TP.B \-alists even files/directories whose names begin with "."..TP.B \-Clists files in as many colums as will fit on the screen. Undoes.BR \-1 " and " \-l ..TP.B \-dlists argument directories' names rather their contents..TP.B \-DList files beginning with a dot ('.') even when the client doesn'tappend the.B \-aoption to the.B listcommand..TP.B \-Fappends '*' to executable regular files, '@' to symlinks and '/' todirectories..TP.B \-lshows various details about the file, including file group. See.BR ls (1)for details. Undoes.BR \-1 " and " \-C ..TP.B \-rreverses the sorting order (modifies.BR \-S " and " \-t " and the default alphabetical ordering).".TP.B \-Rrecursively descends into subdirectories of the argument directories..TP.B \-SSorts by file size instead of by name. Undoes.BR \-t ..TP.B \-tSorts by file modification time instead of by name. Undoes.BR \-S ..SH "PROTOCOL"Here are the FTP commands supported by this server..br.B ABOR.B NOOP.B ALLO.B USER.B PASS.B QUIT.B SYST.B PORT.B EPRT.B PASV.B EPSV.B SPSV.B PWD.B XPWD.B CWD.B XCWD.B CDUP.B XCUP.B HELP.B RETR.B REST.B DELE.B STOR.B APPE.B STOU.B MKD.B XMKD.B RMD.B XRMD.B LIST.B NLST.B TYPE.B MODE.B STRU.B XDBG.B MDTM.B SIZE.B RNFR.B RNTO.B STAT.B MLST.B MLSD.B FEAT.B ESTA.B ESTP.B AUTH TLS.B PBSZ.B PROT.B SITE IDLE.B SITE CHMOD.B SITE HELP.B SITE TIME.SH "BUGS"Please report bugs to the mailing\-list (see below).Pure\-FTPd looks very stable and is used on production servers. However it comes with no warranty and it can have nasty bugs or security flaws..SH "HOME PAGE"http://www.pureftpd.org/.SH "NEW VERSIONS"See the mailing\-list on \fBhttp://www.pureftpd.org/ml/\fR..SH "AUTHOR AND LICENSE"Troll\-FTPd was written by Arnt Gulbrandsen <agulbra@troll.no> and copyright 1995\-2002Troll Tech AS, Waldemar Thranes gate 98B, N\-0175 Oslo, Norway, fax +4722806380..PPPure\-FTPd is (C)opyleft 2001\-2003 by Frank DENIS <j@pureftpd.org> andthe Pure\-FTPd team..PPThis software is covered by the BSD license..PPContributors:.br Arnt Gulbrandsen, Troll Tech AS, Janos Farkas, August Fullford, Ximenes Zalteca, Patrick Michael Kane, Arkadiusz Miskiewicz, Michael K. Johnson, Kelley Lingerfelt, Sebastian Andersson, Andreas Westin, Jason Lunz, Mathias Gumz, Claudiu Costin, Ping, Paul Lasarev, Jean\-Mathieux Schaffhauser, Emmanuel Hocdet, Sami Koskinen, Sami Farin, Luis Llorente Campo, Peter Pentchev, Darren Casey, The Regents of the University of California, Theo de Raadt (OpenBSD), Matthias Andree, Isak Lyberth, Steve Reid, RSA Data Security Inc, Trilucid, Dmtry Lebkov, Johan Huisman, Thorsten Kukuk, Jan van Veen, Roger Constantin Demetrescu, Stefano F., Robert Varga, Freeman, James Metcalf, Im Eunjea, Philip Gladstone, Kenneth Stailey, Brad Smith, Ulrik Sartipy,  Cindy Marasco, Nicolas Doye, Thomas Briggs, Stanton Gallegos, Florin Andrei, Chan Wilson, Bjoern Metzdorf, Ben Gertzfield, Akhilesch Mritunjai, Dawid Szymanski, Kurt Inge Smadal, Alex Dupre, Gabriele Vinci, Andrey Ulanov, Fygul Hether, Jeffrey Lim, Ying-Chieh Liao, Johannes Erdfelt, Martin Sarfy, Clive Goodhead, Aristoteles Pagaltzis, Stefan Hornburg, Mehmet Cokcevik, Brynjar Eide..SH "SEE ALSO".BR "ftp(1)" ,.BR "pure-ftpd(8)".BR "pure-ftpwho(8)".BR "pure-mrtginfo(8)".BR "pure-uploadscript(8)".BR "pure-statsdecode(8)".BR "pure-pw(8)".BR "pure-quotacheck(8)".BR "pure-authd(8)".BR "RFC 959" ,.BR "RFC 2228",.BR "RFC 2389" " and".BR "RFC 2428" .

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -