Difference between revisions of "Linux cli snippets"
From DevOps Notebook
| Line 17: | Line 17: | ||
Alternative is to add '''HISTCONTROL="ignorespace"''' into ''.bashrc'' file and all things | Alternative is to add '''HISTCONTROL="ignorespace"''' into ''.bashrc'' file and all things | ||
written with space in front wont be recorded in history | written with space in front wont be recorded in history | ||
| + | |||
| + | === Check ssl expiry date on file from cli === | ||
| + | <pre> | ||
| + | # openssl x509 -noout -dates -in /path/to/cert.crt | ||
| + | </pre> | ||
Revision as of 18:06, 7 June 2020
Contents
Linux command line snippets
Get website SSL certificate details using CLI
$ echo | openssl s_client -showcerts -servername sendfileto.net -connect sendfileto.net:443 2>/dev/null | openssl x509 -inform pem -noout -text
Temporary stop bash history
Turn off:
$ set +o history
Turn on:
$ set -o history
Alternative is to add HISTCONTROL="ignorespace" into .bashrc file and all things written with space in front wont be recorded in history
Check ssl expiry date on file from cli
# openssl x509 -noout -dates -in /path/to/cert.crt