| View previous topic :: View next topic |
| Author |
Message |
syntex Cheater
Reputation: 0
Joined: 31 Jul 2007 Posts: 32
|
Posted: Thu Sep 11, 2008 12:15 pm Post subject: [Pointer] esi+exc*4-04 Offset |
|
|
Hi @ all,
I have a problem with finding a pointer, I actually dont know how to calculate the offset.
esi+ecx*4-04 this is the Offset
-> esi = 0?
-> ecx = 0?
-> *4
-> -04
(esi+ecx-04) * (4)? or what?
can somebody please explain?
thanks
|
|
| Back to top |
|
 |
ThatPage Grandmaster Cheater
Reputation: 0
Joined: 24 Oct 2007 Posts: 515
|
Posted: Thu Sep 11, 2008 12:54 pm Post subject: |
|
|
| it'll be more easy to help if you put a pic.
|
|
| Back to top |
|
 |
syntex Cheater
Reputation: 0
Joined: 31 Jul 2007 Posts: 32
|
Posted: Thu Sep 11, 2008 1:08 pm Post subject: |
|
|
cant you just tell me how to calculate it?
cause it takes ages to search that value again
|
|
| Back to top |
|
 |
ThatPage Grandmaster Cheater
Reputation: 0
Joined: 24 Oct 2007 Posts: 515
|
Posted: Thu Sep 11, 2008 1:22 pm Post subject: |
|
|
I can't say like that,but i'll post here a pic.
|
|
| Back to top |
|
 |
syntex Cheater
Reputation: 0
Joined: 31 Jul 2007 Posts: 32
|
Posted: Thu Sep 11, 2008 1:32 pm Post subject: |
|
|
This one is a easy one!
esi+ecx*4-04
my looks like this in red
|
|
| Back to top |
|
 |
Dark Byte Site Admin
Reputation: 471
Joined: 09 May 2003 Posts: 25831 Location: The netherlands
|
Posted: Thu Sep 11, 2008 1:43 pm Post subject: |
|
|
esi+ecx*4-04
esi=basepointer
ecx=element in array
-4 =adjustment in calculation. (most likely an array starting from index 1 ?)
so, the offset is ecx*4-4
remember it's all in hex, so set your calculator to hex when calculating
ecx=0 -> offset=0*4-4=-4
ecx=1 -> offset=1*4-4=0
ecx=2 -> offset=2*4-4=4
ecx=3 -> offset=3*4-4=8
ecx=4 -> offset=4*4-4=c
ecx=5 -> offset=5*4-4=10
_________________
Do not ask me about online cheats. I don't know any and wont help finding them.
Like my help? Join me on Patreon so i can keep helping |
|
| Back to top |
|
 |
syntex Cheater
Reputation: 0
Joined: 31 Jul 2007 Posts: 32
|
Posted: Thu Sep 11, 2008 1:47 pm Post subject: |
|
|
thanks Dark Byte,
Why it is like this?
ecx=5 -> offset=5*
why do you count ecx up to 5? could you explain this part?
and how it comes that you know it counts up to 5?
Thank you so much
@@@@EDIT@@@@
I see its just an example to show what happens when ecx 5*-04 happens
|
|
| Back to top |
|
 |
nog_lorp Grandmaster Cheater
Reputation: 0
Joined: 26 Feb 2006 Posts: 743
|
Posted: Thu Sep 11, 2008 2:02 pm Post subject: |
|
|
ECX is the "counter register", it is usually used to count place in loops (like "int i" in most languages).
DarkByte was just going up to 5 as an example, 5 doesn't have any special significance.
Also, it is ecx*4 - 4, ecx times 4, minus 4. The multiple (4) signifies the number of bytes in each element of the array.
What you want to do is Find What Accesses This Address, and double click the line with that code ([esi+ecx*4-04]) and see what ECX and ESI are.
_________________
Mutilated lips give a kiss on the wrist of the worm-like tips of tentacles expanding in my mind
I'm fine accepting only fresh brine you can get another drop of this yeah you wish |
|
| Back to top |
|
 |
syntex Cheater
Reputation: 0
Joined: 31 Jul 2007 Posts: 32
|
Posted: Thu Sep 11, 2008 3:20 pm Post subject: |
|
|
what about this?
so esi+ecx*4-04 = c ... im right?
1A487E20 + 00000001 * 4 - 4 = 1A487E20
00000001 * 4 - 4 = 0
this will be a hard one >.<
-> EDIT:
| Code: |
804D9B2F - 80 34 9b 4d - xor byte ptr [ebx+ebx*4],4d
804D9B33 - 80 8b 44 8e e4 89 44 - or byte ptr [ebx-761b71bc],44
804D9B3A - 8f - db 8f
804D9B3B - e4 8b - in al,8b
804D9B3D - 44 - inc esp
804D9B3E - 8e e8 - mov gs,ax
804D9B40 - 89 44 8f e8 - mov [edi+ecx*4-18],eax
804D9B44 - 8b 44 8e ec - mov eax,[esi+ecx*4-14]
804D9B48 - 89 44 8f ec - mov [edi+ecx*4-14],eax
804D9B4C - 8b 44 8e f0 - mov eax,[esi+ecx*4-10]
804D9B50 - 89 44 8f f0 - mov [edi+ecx*4-10],eax
804D9B54 - 8b 44 8e f4 - mov eax,[esi+ecx*4-0c]
804D9B58 - 89 44 8f f4 - mov [edi+ecx*4-0c],eax
804D9B5C - 8b 44 8e f8 - mov eax,[esi+ecx*4-08]
804D9B60 - 89 44 8f f8 - mov [edi+ecx*4-08],eax
804D9B64 - 8b 44 8e fc - mov eax,[esi+ecx*4-04]
804D9B68 - 89 44 8f fc - mov [edi+ecx*4-04],eax
804D9B6C - 8d 04 8d 00 00 00 00 - lea eax,[ecx*4+00000000]
804D9B73 - 03 f0 - add esi,eax
804D9B75 - 03 f8 - add edi,eax
|
| Description: |
|
| Filesize: |
36.17 KB |
| Viewed: |
11809 Time(s) |

|
| Description: |
|
| Filesize: |
21.39 KB |
| Viewed: |
11809 Time(s) |

|
|
|
| Back to top |
|
 |
|