Skip navigation.

exploreopera

| Help

Sign up | Help

HMODULE win32

This week, I have worked on a project.. and I had to test routine that I wrote in assembly ...

For a test, I used LoadLibraryEx to load in memory a DLL asking to windows to load dll into memory without applying relocations, import tables and without run DllEntryPoint code...

LoadLibraryEx can be invoked using the parameter LOAD_LIBRARY_AS_DATAFILE how flag ..

HMODULE LoadLibraryEx(
  LPCTSTR lpFileName,
  HANDLE hFile,
  DWORD dwFlags
);


and the library is loaded in memory how a block of data, but with differences..

The o.s. doesn't create the sections available into PE header.. and the HMODULE (in WIN32 normally it match with the base address of object) has set latest bit.. (and if used how pointer.. the first byte is Z of 'MZ' signature)... .... it will used internally from MS to understand how get an image in memory?

IMAGEHLP.ImageRvaToVa256 byte games

Write a comment

You must be logged in to write a comment. if you're not a registered member, please sign up.