Corruptor Advanced Cheater
Reputation: 3
Joined: 10 Aug 2011 Posts: 84
|
Posted: Sun May 31, 2026 8:00 am Post subject: Auto Assembler doesnt do lea instructions? |
|
|
32 bit application, im on 7.6.
Tried to do a small injection to gather some info, but it keeps showing errors.
| Code: | [ENABLE]
//code from here to '[DISABLE]' will be used to enable the cheat
alloc(newmem,2048)
globalalloc(scratchpad,4096)
label(data_array)
label(returnhere)
label(originalcode)
label(exit)
newmem: //this is allocated memory, you have read,write,execute access
// id in ESI
// value to enqueue in [esp+c]
mov eax, [scratchpad]
lea edi, [data_array + eax * 8]
mov [edi], esi
mov esi, [esp+c]
mov [edi+4], esi
//inc counter
inc eax
cmp eax, 510
jbe originalcode
xor eax,eax
mov [scratchpad], eax
originalcode:
pop edi
and eax,esi
pop esi
ret
exit:
jmp returnhere
scratchpad:
db 00 00 00 00
data_array:
db 00 00 00 00
"X2.exe"+AA939:
jmp newmem
returnhere:
[DISABLE]
//code from here till the end of the code will be used to disable the cheat
dealloc(newmem)
dealloc(scratchpad)
"X2.exe"+AA939:
db 5F 23 C6 5E C3
//pop edi
//and eax,esi
//pop esi
//ret |
the error pops up in the lea instruction in line 14, which looks fine to me.
oddly enough, i cant seem to get any lea instruction to get accepted exept for the most barebone ones. e.g just
| Code: | | lea edi, [edi + eax] |
gets rejected,
gets rejected, i have to go all the way down to
before it gets accepted. Im fairly certain these are legal instructions, online assemblers eat them too. Whats going on here?
|
|