Downloading files from Target
Different ways to download files from Target Machine.
WGET
Python HTTP Server
Start a python server on the host machine
cd /tmp
python3 -m http.server 8000
Download file from target:
You can also use cURL:
SCP
This assumes we have ssh access to the target machine
File will be downloaded to the /tmp directory
Base64
Now, we can copy this base64
string, go to the remote host, and use base64 -d
to decode it, and pipe the output into a file:
Validating File Transfer
Sometimes we need to validate the file transfer. We can utilize the file
command and md5sum
command to do this.
File
Confirm file type
MD5SUM
On host machine:
On Target Machine
Compare output from both and make sure they match. If not, then something went wrong in the transfer or encode/decode process.
Last updated