From hava, 5 Years ago, written in Bash.
This paste is a reply to Re: Re: save-certificate.sh from hava - view diff
Embed
  1. #!/bin/bash
  2. read -p "Certificate name (e.g. connexeon.com-2017): " CERT_NAME
  3. echo "Certificate (press Ctrl+D when done): " && cat > $CERT_NAME.cer
  4. echo "Root Certificate (press Ctrl+D when done): " && cat > $CERT_NAME-CA.cer
  5. echo "Intermediate Certificate (press Ctrl+D when done): " && cat >> $CERT_NAME-CA.cer
  6. read -p "Nextcloud Username: " USER
  7. read -s -p "Nextcloud Password: " PWD
  8. curl -u $USER:$PWD -X MKCOL "https://c.connexeon.com/remote.php/dav/files/$USER/$CERT_NAME"
  9. for i in /root/$CERT_NAME/* ; do
  10.   curl -u $USER:$PWD -T "${i##*/}" "https://c.connexeon.com/remote.php/dav/files/$USER/$CERT_NAME/${i##*/}"
  11. done;
  12. echo "Certificate uploaded to: https://c.connexeon.com/remote.php/dav/files/$USER/$CERT_NAME"

Replies to Re: Re: Re: save-certificate.sh rss

Title Name Language When
Re: Re: Re: Re: save-certificate.sh Botched Dolphin bash 5 Years ago.