Cyborg - TryHackMe

Enumeration

NMAP

nmap all ports
nmap port 22 and 80 OS detection, version detection, script scanning

Gobuster

User.txt

Privilege Escalation

#!/bin/bash
sudo find / -name "*.mp3" | sudo tee /etc/mp3backups/backed_up_files.txt
input="/etc/mp3backups/backed_up_files.txt"
#while IFS= read -r line
#do
#a="/etc/mp3backups/backed_up_files.txt"
# b=$(basename $input)
#echo
# echo "$line"
#done < "$input"
while getopts c: flag
do
case "${flag}" in
c) command=${OPTARG};;
esac
done
backup_files="/home/alex/Music/song1.mp3 /home/alex/Music/song2.mp3 /home/alex/Music/song3.mp3 /home/alex/Music/song4.mp3 /home/alex/Music/song5.mp3 /home/alex/Music/song6.mp3 /home/alex/Music/song7.mp3 /home/alex/Music/song8.mp3 /home/alex/Music/song9.mp3 /home/alex/Music/song10.mp3 /home/alex/Music/song11.mp3 /home/alex/Music/song12.mp3"# Where to backup to.
dest="/etc/mp3backups/"
# Create archive filename.
hostname=$(hostname -s)
archive_file="$hostname-scheduled.tgz"
# Print start status message.
echo "Backing up $backup_files to $dest/$archive_file"
echo# Backup the files using tar.
tar czf $dest/$archive_file $backup_files
# Print end status message.
echo
echo "Backup finished"
cmd=$($command)
echo $cmd

--

--

--

Software Developer having keen interest in Security, Privacy and Pen-testing. Certs:- Security+,PenTest+,AZ900

Love podcasts or audiobooks? Learn on the go with our new app.

Recommended from Medium

TKING Trading Competition Rolling Out, $15,000 Worth of TKING to be won!

Safeguard Your Business: When disaster strikes!

The Current State of eAuthentication at the IRS and a Proposal for a New Approach

Security Alert: A MUST READ for Anyone Who Writes on Medium

OWASP Web Security Testing Guide v4.2 released

{UPDATE} Submarine Jump! Hack Free Resources Generator

Purchase Online Cooling Memory FoamMattress https://t.co/ktHFtZNXB3

Secretum x Alpha Hunt

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store
0xsanz

0xsanz

Software Developer having keen interest in Security, Privacy and Pen-testing. Certs:- Security+,PenTest+,AZ900

More from Medium

Brooklyn Nine Nine | CTF | Write-ups

RootMe — TryHackMe CTF Walkthrough

TryHackMe: Ignite Detailed Walkthrough | 2022

TryHackMe: Ignite Detailed Walkthrough | 2022

TryHackMe | Red Team Fundamentals WriteUp