Monthly Archives: March 2006

openssl cheat sheet

Generate a 2048 bit keyfile named private.key:
openssl genrsa -out private.key 2048

Take that keyfile and pull out the public key into public.key:
openssl rsa -in private.key -out public.key -pubout

Sign some text with your private key:
openssl dgst -sign private.key -out signature.asc