diff --git a/.aliases b/.aliases index cf4cf0d..29c0c35 100644 --- a/.aliases +++ b/.aliases @@ -54,3 +54,10 @@ alias update='sudo softwareupdate -i -a; brew update; brew upgrade; brew cleanup # Merge some PDFs, usage: pdfmerge file1.pdf file2.pdf alias pdfmerge='/System/Library/Automator/Combine\ PDF\ Pages.action/Contents/Resources/join.py -o output.pdf' + +# Generates a localhost certificate (localhost.key and localhost.crt) +alias genlocalhostcert='openssl req -x509 -out localhost.crt -keyout localhost.key \ + -newkey rsa:2048 -nodes -sha256 \ + -subj ''/CN=localhost'' -extensions EXT -config <( \ + printf "[dn]\nCN=localhost\n[req]\ndistinguished_name = dn\n[EXT]\nsubjectAltName=DNS:localhost\nkeyUsage=digitalSignature\nextendedKeyUsage=serverAuth")' +