I learn Shellcode and use Vulnserver.exe. I managed to get to the point that I inject a shellcode like open a calculator or msgbox But for some reason bind shell on port 4444 does not work for me.

Here is the source code: enter image description here The shellcode is form meterpreter windows/x64/shell_bind_tcp. Please help

  • 1
    please do not post pics of text: copy/paste it with the code formating function – schroeder Apr 14 '17 at 22:12
  • what do you mean "does not work"? what happens? – schroeder Apr 14 '17 at 22:12
  • knowing how you exploited the code does not help with understanding why a network connection isn't working on the target side - you said that the exploit works - you need to look at the target's networking – schroeder Apr 14 '17 at 22:13

Based on what you gave so far, it seems you are attempting to exploit a buffer overflow.

I managed to get to the point that I inject a shellcode like open a calculator or msgbox

I'm going to assume then, that the calc or msgbox is just a payload that you used in the shellcode variable. With these, I can think of a couple of reasons why you can't get the bind shell working.

  1. The bind shell works, but firewall blocks you from connecting. Its port 4444 as you mentioned, so its possible. Use netstat on the victim machine and verify if the port is listening or not. If not, then there really is something wrong with the payload.
  2. There are bad characters in the bind shell payload. Do a bad character analysis, encode and filter them out, and try again.
  3. You are using an invalid payload. This applies if your system is 32-bit.
  4. There is a size restriction on the payload size, and you exceeded it.
  5. The payload steps on its own foot. Try putting NOPs in the first 4 to 8 bytes of your payload (Although this one is unlikely if you didn't encode your payload).

These are just the common reasons I can think of as to why your bind shell doesn't work. Hope this helps.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.