Forums before death by AOL, social media and spammers... "We can't have nice things"
|    comp.lang.asm.x86    |    Ahh, the lost art of x86 assembly    |    4,675 messages    |
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
|    Message 2,947 of 4,675    |
|    Davs to firr    |
|    Re: code for flushing imports to .idata     |
|    22 Aug 17 22:01:41    |
   
   From: johndemeert0@nospicedham.gmail.com   
      
   On Saturday, August 19, 2017 at 9:30:02 PM UTC+8, firr wrote:   
   > I think i need some code that would work like   
   > that   
   >   
   > AddImportsForModule("KERNEL32.DLL", "ExitProcess", "GetModuleHandleA",   
   "GetProcAddress");   
   >   
   > AddImportsForModule("msvcrt.dll", "fopen", "free", "printf", "exit",   
   "fclose", "fread");   
   >   
   >   
   >   
   > well maybe it would be more like   
   >   
   > char* import_names[] = {"fopen", "free", "printf", "exit", "fclose",   
   "fread");   
   >   
   > AddImportsForModule("msvcrt.dll", import_names);   
   >   
   > but this is detail   
   >   
   > the code just need to build binary block of .idata section that i can flush   
   to exe file   
   > when flushing exe to disk in my assembler   
   >   
   > im howewer a bit confused how weirdly this .idata binary is build, so maybe   
   some hints on that?   
   >   
   > btw some best info i found on this topic is here   
   >   
   > https://github.com/macton/x64-fasm-examples/blob/master/Window   
   /00_BasicOS/00_pe_return_03.asm   
   >   
   > or around here, so if someone would like to focus on this and give me some   
   hints may use it   
   >   
   > tnx   
      
   find the function for kernel32.dll and c function you can expand it using   
   user32.dll   
      
   --- SoupGate-Win32 v1.05   
    * Origin: you cannot sedate... all the things you hate (1:229/2)   
|
[   << oldest   |   < older   |   list   |   newer >   |   newest >>   ]
(c) 1994, bbs@darkrealms.ca