Page 1 of 1

Memory of another process

Posted: Fri May 16, 2025 11:03 am
by rndrei
How to read the memory of another process?
It doesn't work!

Code: Select all

*buffer = $004005
If *buffer
  value = PeekB(*buffer + 9)
  MessageRequester("read memmory " , Str(value)) 
  FreeMemory(*buffer)
Else
  MessageRequester("error","not work")
EndIf

Re: Memory of another process

Posted: Fri May 16, 2025 11:55 am
by NicTheQuick
Of course it doesn't work. You don't have the permissions to access the memory of another application. Also pointers are no absolute values but virtual ones. Just because you know the memory location of a certain value in one application, does not mean that you can use that same memory location inside another process to access the same value. There are so much things in place, beginning with address space layout randomization (ASLR) and virtual address spaces.

To get access to the memory of another process you first need to be root or an administrator on Windows, and then you first have to call an API to get access to another processes virtual address space, then you have to map your local memory addresses to the other processes memory locations using an API. And then you may can do what you want to do.

It's highly dependent on the operating system you're using.

Re: Memory of another process

Posted: Fri May 16, 2025 1:17 pm
by Fred
We don't support such question here due to avoid help malware written in PureBasic.