Skip to content

Commit

Permalink
Added localhost generation certificate alias
Browse files Browse the repository at this point in the history
  • Loading branch information
eko committed Jun 20, 2018
1 parent 345d0bc commit 8d3eefc
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions .aliases
Expand Up @@ -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")'

0 comments on commit 8d3eefc

Please sign in to comment.