NETRC(5)

๐ŸŒธ NETRC(5) โ€” the file formats manual, but make it cute ๐ŸŒธ

okay so bestie, we're talking about netrc, netrc(5), the File Formats Manual section, aka netrc, .netrc โ€” your user configuration era for ftp. ๐Ÿ’…


โœจ NAME โœจ

netrc, .netrc โ€” user configuration for ftp


๐Ÿ’– DESCRIPTION ๐Ÿ’–

okay so this file is literally where you keep your configuration and autologin info for the File Transfer Protocol client, ftp(1). it's giving โœจsetupโœจ.

The .netrc file contains login and initialization information used by the auto-login process. no cap. it resides in the user's home directory โ€” that's its home, its main character address ๐Ÿ ๐Ÿ’–

The following tokens are recognized; they may be separated by spaces, tabs, or new-lines. so go off with the whitespace, she doesn't care ๐ŸŽ€

  • machine name โ€” Identify a remote machine name. the auto-login process searches the .netrc file for a machine token that matches the remote machine specified on the ftp command line or as an open command argument. Once a match is made, the subsequent .netrc tokens are processed, stopping when the end of file is reached or another machine or a default token is encountered. like... she finds her match and then she stops, periodt. ๐Ÿ’…
  • default โ€” This is the same as machine name except that default matches any name. there can be only one default token, and it must be after all machine tokens. she's the last one at the party, not the first. This is normally used as:
default login anonymous password user@site

thereby giving the user automatic anonymous ftp login to machines not specified in .netrc. This can be overridden by using the -n flag to disable auto-login. so if you don't want the default vibe, hit -n and she'll chill ๐Ÿซถ

  • login name โ€” Identify a user on the remote machine. If this token is present, the auto-login process will initiate a login using the specified name. that's your username bestie, go claim it ๐Ÿ‘‘
  • password string โ€” Supply a password. If this token is present, the auto-login process will supply the specified string if the remote server requires a password as part of the login process. Note that if this token is present in the .netrc file for any user other than anonymous, ftp will abort the auto-login process if the .netrc is readable by anyone besides the user. ๐Ÿ˜ญ so like. chmod that thing. she is NOT playing about your privacy. it's giving ๐Ÿ”’
  • account string โ€” Supply an additional account password. If this token is present, the auto-login process will supply the specified string if the remote server requires an additional account password, or the auto-login process will initiate an ACCT command if it does not. extra password era, we love a bonus step โœจ
  • macdef name โ€” Define a macro. This token functions like the ftp macdef command functions. A macro is defined with the specified name; its contents begin with the next .netrc line and continue until a null line (consecutive new-line characters) is encountered. If a macro named init is defined, it is automatically executed as the last step in the auto-login process. so init is the one that runs itself, no invitation needed, she just shows up ๐Ÿงšโœจ

๐Ÿ‘€ SEE ALSO ๐Ÿ‘€


and that's the whole page bestie, you ate that ๐Ÿ’…โœจ

this lil masterpiece came from the Linux NetKit (0.17) era, dated September 23, 1997, and lives in section NETRC(5) โ€” vintage but still iconic, fr fr ๐ŸŒˆ๐Ÿ’–

๐Ÿ“ฆ where this page comes from