adithya.hebbar
Tue Sep 10 2024
We can generate a base64-encoded random key easily using either
Alternatively, using
Both commands will give you a 32-byte random key encoded in base64.
#encryption #openssl
openssl
or a combination of dd
and base64
. Here's how:
openssl rand -base64 32
Alternatively, using
dd
and base64
:
dd if=/dev/urandom bs=32 count=1 2>/dev/null | base64
Both commands will give you a 32-byte random key encoded in base64.
#encryption #openssl