Last active
January 3, 2016 04:49
-
-
Save ysangkok/8411890 to your computer and use it in GitHub Desktop.
hushfile encrypted upload
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
cat INPUTFILE | \ | |
openssl enc -aes-256-cbc -pass pass:BOSS123 | \ | |
base64 | \ | |
tr -d '\n' | \ | |
curl --data-urlencode cryptofile@- --data-urlencode metadata=$(\ | |
echo '{"filename":"lol","mimetype":"text/lol","filesize":"very big","deletepassword":"ITSWRONG"}' | \ | |
openssl enc -aes-256-cbc -pass pass:BOSS123 | \ | |
base64 | \ | |
tr -d '\n'\ | |
) --data-urlencode deletepassword=THATSRIGHT "https://hushfile.it/api/upload" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment