
Originally Posted by
ctpsolo
Thanks for the answers so far!
Ok, my question now is how do I go along with "multi layers" of pointers?
Let's say I have a base pointer that with offset 37 takes me to another pointer with offset 40 that takes me to another pointer... yea you get it, until it takes me to the actual hack address. How would I then express it in c++ to retrieve the adress I want to change?
I looked for dll sources and found couple of interesting but none of them seems to have dealt with a lot of pointers.
I'm going to assume that you have the address in a DWORD initally.
so you say offset of 37, then offset of 40, then let's say offset of 68, and that gives us the value we are looking for
DWORD Addy = 0xFF01CD;
DWORD Value =
*( *( *( (DWORD***)Addy + 37 ) + 40) + 68 );
Ignore my explanation below if you wish, due to the cumbersome nature of multilevel pointers, and My failure with communication, The way I have said it below is EXTREMELY confusing. You have been forewarned.
As you can see, In the orange, we have type casted Addy to the type pointer to a pointer to a pointer to an DWORD, and we dereference Addy+37, which results in a value of type pointer to a pointer to a DWORD, and so on. Otherwise, i suppose you could have typecasted it to a pointer to Int multiple times to dereference it, but this way is better.
In the green, we have dereferenced, (the value contained within Addy +37), + 40.
In the purple we have dereferenced,( the value contained within (, the value contained within Addy+37, and 40,) ) + 68.