A Simple way to Modify C and C++ Programs without Source Code using Notepad++


 

I found a simple way to modify C and C++ compiled executable programs without C or  C++ source code using notepad++. This method works well with Turbo C  and I have tested  this method with programs compiled with gcc5 ,gcc6 ,gcc7 and gcc8  and it works pretty good. The only limitation to this method is it does not work well with large binary programs.

The C source code for the above C program used above is given below:-


As shown in the above video after the C source code was compiled we get an executive file.
In above case we got  new.exe . When we open new.exe file in notepad++  , we get gibberish text or unreadable characters. However some words are readable . I replace tails.boum.org to kali.org
and M.Anish to kremlin in the program by editing it in notepad++  and I succeed  as shown in the video.  In this way anyone can modify a compiled program without source code.

Statements in C source code inside printf( ) and System( ) functions are mostly readable in the C binary program while opening it in  notepad++.

This can be dangerous . I replaced tails.boum.org with kali.org which is a harmless website but
we can easily replace it with a dangerous site full of viruses.

Also writing Author names in a C/C++ programs to show ownership doesn't work well. In the above video I could change it from M.Anish to kremlin.

CONCLUSION:

Developers should use digital certificates to prove ownership and  provide users with digitally signed programs or with  secure sha256 or sha512 checksums published in a trusted website.

People should avoid installing programs without proper digital signatures or atleast verify that the program has not be modified in a harmful way and always download programs from trustable sources.


Comments

Popular posts from this blog

MY PGP KEY

Unblocking Websites using my AntiCensorship Tool in C

Defeating Antivirus detection of malicious links using Googleweblight.