PWGEN(1)
๐ PWGEN(1) ๐
okay bestie, welcome to the General Commands Manual section for pwgen, and no you did not misread that, we're doing a whole manpage together and it's gonna be iconic โจ
๐ NAME ๐
pwgen โ generate pronounceable passwords ๐ฆ
โจ SYNOPSIS โจ
pwgen [ OPTION ] [ pw_length ] [ num_pw ]
๐ธ DESCRIPTION ๐ธ
so like, pwgen makes passwords that are designed to be easily memorized by humans while also being as secure as possible. that's the whole vibe. ๐
but real talk, no cap: human-memorable passwords are never going to be as secure as completely completely random passwords. that's just facts. in particular, passwords generated by pwgen without the -s option should not be used in places where the password could be attacked via an off-line brute-force attack ๐ญ. on the other hand, completely randomly generated passwords have a tendency to be written down, and are subject to being compromised in that fashion. so it's giving tradeoffs, periodt.
the way pwgen was designed, it works both interactively and in shell scripts ๐ซถ. so its default behavior differs depending on whether standard output is a tty device or a pipe to another program:
- used interactively,
pwgenwill display a screenful of passwords, letting you pick a single password and then quickly erase the screen. this prevents someone from being able to "shoulder surf" the user's chosen password ๐โจ iconic behavior honestly. - when standard output (stdout) is not a tty,
pwgenwill only generate one password, because that tends to be much more convenient for shell scripts, and in order to be compatible with previous versions of this program. legacy support, we love her ๐
๐ OPTIONS ๐
-0,--no-numeralsโ don't include numbers in the generated passwords. numbers? not invited ๐ซ-1โ print the generated passwords one per line.-A,--no-capitalizeโ don't bother to include any capital letters in the generated passwords. lowercase only era.-a,--alt-phonicsโ this option doesn't do anything special; it is present only for backwards compatibility. it's literally just vibing there ๐ง-B,--ambiguousโ don't use characters that could be confused by the user when printed, such as'l'and'1', or'0'or'O'. this reduces the number of possible passwords significantly, and as such reduces the quality of the passwords. it may be useful for users who have bad vision, but in general use of this option is not recommended. lowkey a nerf, bestie.-c,--capitalizeโ include at least one capital letter in the password. this is the default if the standard output is a tty device.-Cโ print the generated passwords in columns. this is the default if the standard output is a tty device.-N,--num-passwords=numโ generate num passwords. this defaults to a screenful if passwords are printed by columns, and one password otherwise.-n,--numeralsโ include at least one number in the password. this is the default if the standard output is a tty device.-H,--sha1=/path/to/file[#seed]โ will use the sha1's hash of given file and the optional seed to create password. it will allow you to compute the same password later, if you remember the file, seed, andpwgen's options used. ie:pwgen -H ~/your_favorite.mp3#your@email.comgives a list of possibles passwords for your pop3 account, and you can ask this list again and again ๐โจ
WARNING: the passwords generated using this option are not very random. if you use this option, make sure the attacker can not obtain a copy of the file. also, note that the name of the file may be easily available from the~/.historyor~/.bash_historyfile. ๐ stay safe out there fr.
-h,--helpโ print a help message.-rchars,--remove-chars=chars โ don't use the specified characters in password. this option will disable the phomeme-based generator and uses the random password generator.-s,--secureโ generate completely random, hard-to-memorize passwords. these should only be used for machine passwords, since otherwise it's almost guaranteed that users will simply write the password on a piece of paper taped to the monitor... ๐ญ๐ญ pls don't do that.-v,--no-vowelsโ generate random passwords that do not contain vowels or numbers that might be mistaken for vowels. it provides less secure passwords to allow system administrators to not have to worry with random passwords accidentally contain offensive substrings ๐ the more you know.-y,--symbolsโ include at least one special character in the password.
๐ AUTHOR ๐
this version of pwgen was written by Theodore Ts'o <tytso@alum.mit.edu> ๐ it is modelled after a program originally written by Brandon S. Allbery, and then later extensively modified by Olaf Titz, Jim Lynch, and others. it was rewritten from scratch by Theodore Ts'o because the original program was somewhat of a hack, and thus hard to maintain, and because the licensing status of the program was unclear. glow-up of the century honestly ๐
๐ฅ SEE ALSO ๐ฅ
and that's the whole page bestie!! this was pwgen version 2.08, dated August 2017, and you can find it in the General Commands Manual section ๐ tysm for reading, mwah, go make some passwords (the secure kind, preferably with -s if it's for a machine, iykyk) ๐โจ๐ฆ
๐ฆ where this page comes from
- alpine 3.22: pwgen-doc 2.08-r3 ยท GPL-2.0-only
- alpine 3.23: pwgen-doc 2.08-r3 ยท GPL-2.0-only
- alpine 3.24: pwgen-doc 2.08-r3 ยท GPL-2.0-only
- arch rolling: pwgen 2.08-4 ยท GPL-2.0-only
- debian bookworm: pwgen 2.08-2 ยท GPL-2.0-only
- debian trixie: pwgen 2.08-2 ยท GPL-2.0-only
- epel 10: pwgen 2.08-17.el10_1 ยท GPL-1.0-or-later
- epel 9: pwgen 2.08-8.el9 ยท GPL+
- fedora 43: pwgen 2.08-17.fc43 ยท GPL-1.0-or-later
- fedora 44: pwgen 2.08-18.fc44 ยท GPL-1.0-or-later
- nixos 26.05: pwgen 2.08
- nixpkgs unstable: pwgen 2.08
- opensuse-leap 16.0: pwgen 2.08-bp160.1.12 ยท GPL-2.0-or-later
- opensuse-leap 16.0: pwgen 2.08-bp160.1.12 ยท GPL-2.0-or-later
- opensuse-leap 16.0: pwgen 2.08-bp160.1.12 ยท GPL-2.0-or-later
- opensuse-leap 16.0: pwgen 2.08-bp160.1.12 ยท GPL-2.0-or-later
- ubuntu jammy: pwgen 2.08-2build1 ยท GPL-2.0-only
- ubuntu noble: pwgen 2.08-2build2 ยท GPL-2.0-only
- ubuntu questing: pwgen 2.08-2build2
- ubuntu resolute: pwgen 2.08-2build3 ยท GPL-2.0-only
- ubuntu stonking: pwgen 2.08-2build3 ยท GPL-2.0-only
- ๐ girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms