Cheat Engine Forum Index Cheat Engine
The Official Site of Cheat Engine
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 


[C#] Invoke (inject) ASM code into process

 
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking
View previous topic :: View next topic  
Author Message
onlyu1106
How do I cheat?
Reputation: 0

Joined: 25 Nov 2015
Posts: 8

PostPosted: Sun Feb 28, 2016 6:53 am    Post subject: [C#] Invoke (inject) ASM code into process Reply with quote

In AutoIT, I use asm converter
EX:
PUSHAD()
MOV_ECX(_MEMORYREAD(0X0064577C, $MEMID))
MOV_EAX($BASE_SEND)
PUSH_EAX()
MOV_EDX(0X0048D330)
CALL_EDX()
POPAD()
RET()

The asm code will be converted to binary code, then I use:
VirtualAllocEx
WriteProcessMemory
CreateRemoteThread
WaitForSingleObject
VirtualFreeEx
CloseHandle
In C#, I tried to search more information about it, but I dont have any idea about it.....I think, the first we have to convert asm to binary code then inject it into process, but how to convert it in C#?
Back to top
View user's profile Send private message
mgostIH
Expert Cheater
Reputation: 3

Joined: 01 Jan 2016
Posts: 159

PostPosted: Sun Feb 28, 2016 12:42 pm    Post subject: Re: [C#] Invoke (inject) ASM code into process Reply with quote

onlyu1106 wrote:
In AutoIT, I use asm converter
EX:
PUSHAD()
MOV_ECX(_MEMORYREAD(0X0064577C, $MEMID))
MOV_EAX($BASE_SEND)
PUSH_EAX()
MOV_EDX(0X0048D330)
CALL_EDX()
POPAD()
RET()

The asm code will be converted to binary code, then I use:
VirtualAllocEx
WriteProcessMemory
CreateRemoteThread
WaitForSingleObject
VirtualFreeEx
CloseHandle
In C#, I tried to search more information about it, but I dont have any idea about it.....I think, the first we have to convert asm to binary code then inject it into process, but how to convert it in C#?


Cheat Engine will convert any instruction in binary code by itself, if that's what you are asking.

_________________
Do you need to ask me something? Feel free to join my discord server at: https://discord.gg/At4VZXA or ask me something in my YouTube channel: https://www.youtube.com/c/mgostIH
Back to top
View user's profile Send private message
atom0s
Moderator
Reputation: 205

Joined: 25 Jan 2006
Posts: 8586
Location: 127.0.0.1

PostPosted: Sun Feb 28, 2016 7:47 pm    Post subject: Reply with quote

There is a FASM library available for C# to inject ASM through FASM.
https://github.com/ZenLulz/Fasm.NET

Look around and you can find some more up to date similar projects though as this link is about 3 years old.

_________________
- Retired.
Back to top
View user's profile Send private message Visit poster's website
onlyu1106
How do I cheat?
Reputation: 0

Joined: 25 Nov 2015
Posts: 8

PostPosted: Mon Feb 29, 2016 5:08 pm    Post subject: Reply with quote

atom0s wrote:
There is a FASM library available for C# to inject ASM through FASM.

Look around and you can find some more up to date similar projects though as this link is about 3 years old.

Tks very much...you're always help me when I have a problem <3 xD
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    Cheat Engine Forum Index -> General Gamehacking All times are GMT - 6 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group

CE Wiki   IRC (#CEF)   Twitter
Third party websites