Random Password Generator Command in Linux we Rarely Use

Author profile picture

A long term value investor. Believes that secular trends drive investing. Be on the right side of the big trends.

Password generators are now in abundance. Particularly surprising are the many web applications for this purpose. The random.org service honestly admits that it generates passwords on the server side and it is contraindicated to use them for anything serious. Other services claim to generate passwords locally using JavaScript, but whether or not to take their word for it and whether their approach ensures that leaks are safe is a tricky one.

At the same time, a random password generator has been present in the repositories of all Linux distributions since the nineties and is called

. Many passwords that you have received in your life are most likely generated by him.

Interestingly, its author is Theodore Tso, the one who developed the ext2 filesystem and its journaled versions ext3 and ext4.

For example,

16 1 will generate one sixteen character password.

If you do not specify the second argument (the number of passwords), then by default in interactive mode

will generate as many as eighty passwords - four columns of twenty lines. As conceived by the authors, this should protect the user from those who like to look into someone else's screen.

So if you starting an online site, an eCommerce shop or any other use case that requires a password, the user generates a whole password table and copies or memorizes one random one from it. In this case, an attacker or an excessively curious office colleague will not be able to find out which password out of eight dozen the user has chosen. In the days of massive remote work, this argument seems a bit taut, and it is doubtful that passwords are so easy to remember.

In modern times, the

-s / - secure
option is much more useful, which generates completely random passwords with no claim to readability. You can also add -B / - ambiguous to it, which excludes appearance-like characters like O / 0 and 1 / I from the output.

Join Hacker Noon

Create your free account to unlock your custom reading experience.