Era

#linux #medium

sudo nmap -p- -sS --min-rate 5000 -Pn -n -vv -oA nmap/era 10.10.11.79

PORT   STATE SERVICE REASON
21/tcp open  ftp     syn-ack ttl 63
80/tcp open  http    syn-ack ttl 63
nmap -p 21,80 -sCV -oA nmap/scripts 10.10.11.79

PORT   STATE SERVICE VERSION
21/tcp open  ftp     vsftpd 3.0.5
80/tcp open  http    nginx 1.18.0 (Ubuntu)
|_http-server-header: nginx/1.18.0 (Ubuntu)
|_http-title: Did not follow redirect to http://era.htb/
Service Info: OSs: Unix, Linux; CPE: cpe:/o:linux:linux_kernel

Add era.htb to /etc/hosts file

ffuf -u http://era.htb -H 'Host: FUZZ.era.htb' -w /usr/share/seclists/Discovery/DNS/subdomains-top1million-110000.txt -t 80 -ic -c -fs 154

file                    [Status: 200, Size: 6765, Words: 2608, Lines: 234, Duration: 175ms]

Add file.era.htb to /etc/hosts file

ffuf -u http://file.era.htb/FUZZ -w /usr/share/seclists/Discovery/Web-Content/DirBuster-2007_directory-list-2.3-medium.txt -t 80 -ic -c -fs 6765 -r -e .php

login.php               [Status: 200, Size: 9214, Words: 3701, Lines: 327, Duration: 175ms]
download.php            [Status: 200, Size: 9214, Words: 3701, Lines: 327, Duration: 171ms]
images                  [Status: 403, Size: 162, Words: 4, Lines: 8, Duration: 175ms]
register.php            [Status: 200, Size: 3205, Words: 1094, Lines: 106, Duration: 178ms]
files                   [Status: 403, Size: 162, Words: 4, Lines: 8, Duration: 175ms]
assets                  [Status: 403, Size: 162, Words: 4, Lines: 8, Duration: 178ms]
upload.php              [Status: 200, Size: 9214, Words: 3701, Lines: 327, Duration: 174ms]
layout.php              [Status: 200, Size: 0, Words: 1, Lines: 1, Duration: 182ms]
logout.php              [Status: 200, Size: 70, Words: 6, Lines: 1, Duration: 177ms]
manage.php              [Status: 200, Size: 9214, Words: 3701, Lines: 327, Duration: 171ms]
LICENSE                 [Status: 200, Size: 34524, Words: 5707, Lines: 663, Duration: 175ms]
reset.php               [Status: 200, Size: 9214, Words: 3701, Lines: 327, Duration: 167ms]

Create an account

Sign in

Upload a file

http://file.era.htb/download.php?id=7126arrow-up-right

Open Burp Suite

Download the file uploaded

Put FUZZ in the parameter id

Download the two files

Separate users from hashes with a :. Use this command to do it in nvim :%s/|/:/g

Update security questions from user admin

Login with security questions as admin

Shell interactiva estable

User flag

circle-check

Create a shell.c file

https://github.com/NUAA-WatchDog/linux-elf-binary-signerarrow-up-right

Root flag

circle-check

Last updated