Readmemory

OllyDbg Plugin API

Readmemory

Reads memory of debugged process optionally removing INT3 breakpoints. You can read memory "on the fly": if necessary, Readmemory temporaily pauses debugged application and enables read access. Returns size of memory actually read. Currently, this is either size or 0 if memory cannot be read at once.

Important note: Any access to the memory of debugged application is time-consuming. To optimize access, consider use of Havecopyofmemory.

ulong Readmemory(void *buf,ulong addr,ulong size,int mode);

Parameters:

buf - pointer to buffer of size at least size that receives copy of memory;

addr - address of memory in the memory space of debugged application;

size - size of requested memory block;

mode - mode of operation, combination of following bits:

MM_RESTORE Restore INT3 breakpoints
MM_SILENT On error, don't display error message box

Note that header declares MM_RESILENT as a combination of (MM_RESTORE|MM_SILENT).

See also: Writememory, Havecopyofmemory