Alert icon
We're changing our privacy policy. This stuff matters.  Learn more  Dismiss

Programming & Debugging: C to Assembly

Loading...

Sign in or sign up now!
14,807
Loading...
Alert icon
Sign in or sign up now!
Alert icon

Uploaded by on Jun 3, 2008

Gcc compiler lets you translate c code to assembly code.
Ollydbg lets you debug executable.
This video shows you how to do the above 2 things!

Category:

Howto & Style

Tags:

License:

Standard YouTube License

  • likes, 3 dislikes

Link to this comment:

Share to:

Uploader Comments (youhakim)

  • how to change the assembly code in one memory adress using C??

    lets say i got the adress 0x5412

    and i wanna use nop(0x90)

    im trying it with writeprocessmemory() but the program crash any solution??

  • Hi,

    You don't use any special function for that, you just open the executable file in binary, read, write mode using the fopen function and ... look for what you need to replace and replace it.

    file_pointer = fopen("file.exe", "r+ b");

    r+ : to open an existant file in read and write mode.

    b : to open a file in binary mode.

  • well can u give me an example?

    i have try it with fopen,strstr and fputs but i cant make it work

  • Ok, I've decided to make a video to demonstrate that, so stay tuned!

  • Oops! I didn't answer your question, did I?

    I didn't ignore your real question, I just assumed without reading carefully that you were talking about how to patch a program, but you were talking about how to program a "Trainer" which "changes parts of memory used by a game to for example gain more money, [weapons,] etc", I don't know where was my mind? I'll try to answer you in a future video, and if it won't fit in 10 minutes I'll send you the source code of the "trainer" I'll try to write! OK?

  • Gcc uses a line feed as the end of the line not a carriage return, line feed! it is Windows who uses carriage return, line feed.

    Mac uses a carriage return.

    sorry for the mistake!

Top Comments

  • "gcc -S -masm=intel file.c"

    This generates a Intel syntaxe file. =)

  • u got sexy accent :)

see all

All Comments (22)

Sign In or Sign Up now to post a comment!
  • you speak french? Parlez-vous Francias?

  • thanks brother

  • ollydebug FTW!! =)

  • GCC -S option... soooo usefulll.... can make faster programs using this :)

  • @Gr8gabe all translate to machine code.

  • lol

    "we don't need this code, i dont' nkwo what it does" infact ill remove it, *dellete*" "now computer "compile(he measn assemble)!" *pc crashes" "oh... god....shit...."

  • egh i hate ur voice

Loading...
0 / 00Unsaved Playlist Return to active list
    1. Your queue is empty. Add videos to your queue using this button:
      or sign in to load a different list.
    Loading...Loading...Saving...
    • Clear all videos from this list
    • Learn more