PAM_FTP(8)

โœจ PAM_FTP โ€” the anonymous ftp moment ๐Ÿ’…

okay so bestie, we're looking at PAM_FTP(8) from the Linux-PAM Manual, and honestly? she's a little chaotic but she does one job and she does it. let's get into it ๐Ÿซถ


๐ŸŒธ NAME ๐ŸŒธ

pam_ftp โ€” the PAM module for anonymous access, periodt.


๐ŸŽ€ SYNOPSIS ๐ŸŽ€

pam_ftp.so [debug] [ignore] [users=XXX,YYY,...]

๐Ÿ’– DESCRIPTION ๐Ÿ’–

so pam_ftp is a PAM module that gives you a pluggable anonymous ftp mode of access. very niche, very demure.

here's the tea on how she works: this module intercepts the user's name and password. if the name is ftp or anonymous, then the user's password gets broken up at the @ delimiter into a PAM_RUSER part and a PAM_RHOST part โ€” and those pam-items get set accordingly, no cap. the username (PAM_USER) gets set to ftp. in this case, the module succeeds. ๐ŸŽ‰

but alternatively? the module sets the PAM_AUTHTOK item with the entered password and fails. that's it, that's the vibe. ๐Ÿ˜ญ

โš ๏ธ BESTIE. LISTEN. This module is not safe and is easily spoofable. i'm not being dramatic, that's literally what the page says. protect yourself. ๐Ÿ’€

โœจ OPTIONS โœจ

  • debug โ€” print debug information. she's telling you everything, fr fr. ๐Ÿ›
  • ignore โ€” pay no attention to the email address of the user (if one was supplied). living in blissful ignorance, iconic. ๐Ÿ™ˆ
  • ftp=XXX,YYY,... โ€” instead of ftp or anonymous, you can provide anonymous login to a comma separated list of users: XXX,YYY,.... and if the applicant enters one of these usernames, the returned username gets set to the first one in the list: XXX. first come, first served energy ๐Ÿ‘‘

๐Ÿ‘‘ MODULE TYPES PROVIDED ๐Ÿ‘‘

only the auth module type is provided. that's the whole roster, she's a specialist ๐Ÿ’…


๐Ÿ”ฅ RETURN VALUES ๐Ÿ”ฅ

  • PAM_SUCCESS โ€” the authentication was successful. slay! โœจ
  • PAM_USER_UNKNOWN โ€” user not known. who is she? don't know her. ๐Ÿฆ‹

๐ŸŒˆ EXAMPLES ๐ŸŒˆ

drop this line into /etc/pam.d/ftpd to handle ftp style anonymous login, and you're so set:

#
# ftpd; add ftp-specifics. These lines enable anonymous ftp over
#       standard UN*X access (the listfile entry blocks access to
#       users listed in /etc/ftpusers)
#
auth    sufficient  pam_ftp.so
auth    required    pam_unix.so use_first_pass
auth    required    pam_listfile.so \
           onerr=succeed item=user sense=deny file=/etc/ftpusers

like. she ate. ๐Ÿ“


๐Ÿงš SEE ALSO ๐Ÿงš

pam.conf(5), pam.d(5), pam(8) โ€” go read the fam too, iykyk ๐Ÿ’œ


๐Ÿ’œ AUTHOR ๐Ÿ’œ

pam_ftp was written by Andrew G. Morgan <morgan@kernel.org>. ty for your service king ๐Ÿซถ


and that's a wrap on PAM_FTP(8) bestie!! this page came from the Linux-PAM crew, dated 09/27/2026 โ€” so yeah, she's current, she's giving documentation main character energy, and she's fully yours now. go forth and configure responsibly ๐Ÿ’…โœจ๐ŸŽ€

๐Ÿ“ฆ where this page comes from