Transferring Files with Code
Python
Python 2 - Download
$ python2.7 -c 'import urllib;urllib.urlretrieve ("https://raw.githubusercontent.com/rebootuser/LinEnum/master/LinEnum.sh", "LinEnum.sh")'Python 3 - Download
$ python3 -c 'import urllib.request;urllib.request.urlretrieve("https://raw.githubusercontent.com/rebootuser/LinEnum/master/LinEnum.sh", "LinEnum.sh")'Upload Operations using Python3
Starting the Python uploadserver Module
$ python3 -m uploadserver
File upload available at /upload
Serving HTTP on 0.0.0.0 port 8000 (http://0.0.0.0:8000/) ...Uploading a File Using a Python One-liner
PHP
PHP Download with File_get_contents()
PHP Download with Fopen()
PHP Download a File and Pipe it to Bash
Other Languages
Ruby - Download a File
Perl - Download a File
JavaScript
Download a File Using JavaScript and cscript.exe
VBScript
Download a File Using VBScript and cscript.exe
Last updated