Metasploit mailing list archives

Question on SEH, PROCESS, THREAD and integrating custom C Code


From: jeffs at speakeasy.net (jeffs)
Date: Mon, 28 Jul 2008 20:57:34 -0400

First thanks for the great program.  I've been fiddling with it for 
months and finally after reading Mark Baggett's document on using 
Metasploit and AV products, it has all come together.

Here is a link to his fine document for those who are interested:

http://www.giac.org/certified_professionals/practicals/GCIH/01072.php

Yet, I have some lingering questions that maybe an enlighted soul might 
be able to answer for me.

1) I've confused over the seh, process and thread options and what one 
can do with them.

2) I have some "c" code that I would like to integrate into the 
directories so I can use it as a payload.  The nice thing about this 
exploit is that you can set time intervals for it to "phone home" and 
connects using encrypted channels.  I'd like to be able to upload it via 
meterpreter.  How does one go about taking "c" code and turning it into 
an exploit or module that can be used via the meterpreter?

3) I noticed that if I use some of the msfpayloads such as 
meterpreter/bind_tcp, the victim's machine will display an error message 
if upon execution of the binary on the victim's machine there is no 
attacking machine waiting to receive it's query.  Is there some way to 
modify the behavior of the payloads so it repeatedly queries an ip to 
connect with or somehow make the process repeating without dieing after 
one attempt?

4) I'll think of another question soon enough but thanks for any help.





Current thread: