View previous topic :: View next topic |
Author |
Message |
Fakizun How do I cheat? Reputation: 0
Joined: 04 Sep 2017 Posts: 2
|
Posted: Mon Sep 04, 2017 3:03 am Post subject: How do you protect the allocated memory? |
|
|
1. I wrote a simple aobscan code by the template
2. Allocated 1000h memory for the code
3. The code works but occasionally crashes
4. Found out it tries to access invalid pointers
5. It shouldn't happen so I had no idea where those pointers come from
6. Accidentally found out sometimes the upper part of my codes are getting allocated
7. Some windows stuff called OLEACC.dll is violating my safe space and first few lines of my codes were being overwritten by some filthy codes
Tried putting a bunch of nops and int3 to build a great wall but it wasn't helpful. I don't think no matter how much pointer verification I put in it will be enough against the code itself being overwritten. Can I allocate my code in a safer region? I have no idea how the memory allocation works but memories overlapping doesn't sound good at all, especially with the windows dlls. |
|
Back to top |
|
|
Dark Byte Site Admin Reputation: 458
Joined: 09 May 2003 Posts: 25287 Location: The netherlands
|
Posted: Mon Sep 04, 2017 3:28 am Post subject: |
|
|
You can use alloc's 3th parameter to specify a memory region you wish to allocate at
but, does it crash when you have disabled it (at least once) or also when enabled (and never disabled)
did you have to rename cheat engine to get it to run ?
Most likely though your code injection part is called by other routines as well _________________
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 |
|
|
Fakizun How do I cheat? Reputation: 0
Joined: 04 Sep 2017 Posts: 2
|
Posted: Mon Sep 04, 2017 4:10 am Post subject: |
|
|
Dark Byte wrote: | You can use alloc's 3th parameter to specify a memory region you wish to allocate at
but, does it crash when you have disabled it (at least once) or also when enabled (and never disabled)
did you have to rename cheat engine to get it to run ?
Most likely though your code injection part is called by other routines as well |
Thank you for the input, I will try it. I actually found a reproducible crash. The crash only happens when I enable it and disabling it stops crashing. And I don't remember renaming anything. From what I see from the esp stack is that: The injected part is called properly from the expected routine, but the first few lines are corrupted so the register numbers get messed up (eg. eax becomes null) and it ends up crashing into the invalid pointers. I can try avoiding the crash by using ebx instead of eax but the worrying part is that because I am not the only one accessing this region, I might end up messing up something like an OS dll process. |
|
Back to top |
|
|
OldCheatEngineUser Whateven rank Reputation: 20
Joined: 01 Feb 2016 Posts: 1587
|
Posted: Mon Sep 04, 2017 7:30 am Post subject: |
|
|
make sure there is no other module is accessed, and no more than one thread is executing the instructions.
i ended up with something similar, and all what i did is:
tried to see what accesses the address and hook that instruction, do modification and jump return. _________________
About Me;
I Use CE Since Version 1.X, And Still Learning How To Use It Well!
Jul 26, 2020
STN wrote: | i am a sweetheart. |
|
|
Back to top |
|
|
|