Last active
April 16, 2024 10:59
-
-
Save SpaceBison/4ef6c00b2b5dac7837ac2df2909b931b to your computer and use it in GitHub Desktop.
Shell one liner to download a file using nc, xxd, tr, and sed
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
# download http://storage.googleapis.com/gtv-videos-bucket/sample/ForBiggerMeltdowns.mp4 | |
printf 'GET /gtv-videos-bucket/sample/ForBiggerMeltdowns.mp4 HTTP/1.1\r\nHost: storage.googleapis.com\r\nConnection: close\r\n\r\n' | nc storage.googleapis.com 80 | xxd -p | tr -d '\n' | sed 's/.*0d0a0d0a//1'| xxd -p -r > ForBiggerMeltdowns.mp4 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment