Skip to content

Instantly share code, notes, and snippets.

@LivingInSyn
Created August 5, 2020 20:07
Show Gist options
  • Save LivingInSyn/f91a7a99599db81ca2aba6055c7880a8 to your computer and use it in GitHub Desktop.
Save LivingInSyn/f91a7a99599db81ca2aba6055c7880a8 to your computer and use it in GitHub Desktop.
mkc() {
mkdir $1
cd $1
}
myip() {
curl 'https://api.ipify.org?format=json'
}
myip6() {
curl 'https://api6.ipify.org?format=json'
}
unixsec() {
date +%s
}
rfc3339() {
date -u +"%Y-%m-%dT%H:%M:%SZ"
}
checkcert(){
openssl x509 -in $1 -text -noout
}
newcsr(){
openssl req -new -key $1 -out $2
}
newrsakey(){
openssl genrsa -out $1 2048
}
checkexpire() {
echo | openssl s_client -servername $1 -connect $1:443 2>/dev/null | openssl x509 -noout -dates
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment