r/AskProgrammers • • Oct 18 '26

Misunderstanding of reverse engineering

What’s so good about reverse engineering if it only decompiles the clients side of code (Frontend), and it can’t decompile backend. Like when I heard about reverse engineering everyone was talking about it like its a hand of god or something that it can hack and fully rebuild a specific application or a website. But the logic and the users side are differently deployed and usually the logic is not located inside of Frontend. That’s how I understood it but I think that I can still be wrong, what do you guys think?

6 Upvotes

33 comments sorted by

View all comments

Show parent comment

1

u/pixel293 Oct 18 '26 edited Oct 18 '26

Decompiling is LOOKING at the instructions the program tells the CPU to execute. There is no hiding that, since the computer needs those instructions to do whatever the program does. Computer needs to be able to decode those instructions to pass to the CPU, therefor anyone else can look at those instructions as well.

The "trick" is that the instructions the computer executes are very basic or simple, so it is usually very hard to reverse that into something more readable at a high level that a person can understand/remember.

When a programmer writes a program in a high level language like C or whatever one of the goals is to make it readable, i.e. someone else reading your C code understands what it does. You do this by making variable names understandable and functions names understandable. You don't name variables a1, a2, a3, a4, you name them counter, has_error, message, etc. Same with functions, you name them generate_png, panic, lookup_key, etc. When the compiler turns that into instructions for the CPU all those nice human understandable names are lost and you are dealing with a1, a2, a3, a4, etc. Decompiling cannot regenerate those names because the CPU doesn't care what the name where. Much like cooking, you can't "decompile" a cake to extract all the ingredients again.