apg < stands for “another-password-generator”
apg < generates several random passwords
-a 0 < use algo. 0 - pronounce-able pw. gen. default
-a 1 < use algo. 1 - random character pw. gen.
-c /dev/urandom < use /dev/urandom seed for pw. gen.
-c /tmp/seed < use custom seed file for pw. gen.
-c cl_seed < use cl_seed as random seed for pw. gen.
< use it to gen. pws. in shell scripts.
-s < ask user to type a random sequence for pw. gen.
< only first 16 keys are significant
-M C < mode-gen. MUST use capital letters for every pw.
-M L < mode-gen. MUST use small letters for every pw.
< ALWAYS present if algo. 0 is used
-M N < mode-gen. MUST use numeral symbol for every pw.
-M S < mode-gen. MUST use special symbol for every pw.
-m 8 < generates an 8 character long pw. default.
-m 16 < generates a 16 character long pw.
-m min_pass_len < specify how long you want your pw. to be.
-n 1 < generates one pw.
-n 6 < generates six pws. default.
-n num_of_pass < specify how many pws. you want to generate
example :
apg -a 1 -c /dev/urandom -M CLNS -m 16 -n 8
https://explainshell.com/ or info apg
or man apg
the above is a better, more direct approach to pw. generation
the ‘SeaHorse
’ or ‘Password Safe
’ GUI apps can be used as well.
i find the above approach takes considerably less time (with a keyboard) if you make a script or even keep it as a handy alias.
if you want to use ‘Password Safe’ JUST for pw. generation then you have to take additional steps with login-credentials, more clicks, and the built in generator doesn’t offer that many options.
the -c option is SO useful.
the only thing with apg is that it hasn’t seen updates in quite a while and i was wondering if there is anything better CLI wise.
what is the difference between /dev/random
and /dev/urandom
?
-c cl_seed
seems to be less secure since it uses the same seed each time if you leave the seed file unchanged.