All examples will be using SHA-512, <password>
as password placeholder and <salt>
as salt placeholder.
Note: mkpasswd
binary is installed via the package whois
on Debian / Ubuntu only. On other Linux distribution such as ArchLinux, Fedora, CentOS, openSUSE, etc. mkpasswd
is provided by the expect
package but is an totally different utility which is available as expect_mkpasswd
on Debian / Ubuntu. whois
of all other Linux distro doesn't include mkpasswd
but the source (C lang) can be found on the original repository https://github.com/rfc1036/whois.
# With a random password and random salt
mkpasswd -m sha-512
# With a random random salt