0Pricing
Reverse Engineering & Binary Analysis Basics · Leçon

Contourner les compacteurs et atteindre l’OEP

Identifiez les compacteurs utilisés à l’exécution, trouvez le point d’entrée original et extrayez une image décompactée pour analyser statiquement et proprement les binaires protégés contre la rétro-ingénierie.

Contourner les compacteurs et atteindre l’OEP est une leçon Reverse Engineering & Binary Analysis Basics gratuite sur CoddyKit. Ceci est la leçon 4 sur 4. Tu peux lire la leçon complète ci-dessous gratuitement — puis la pratiquer en direct dans le navigateur avec un éditeur de code intégré et un tuteur IA 24/7. Elle fait partie du parcours d'apprentissage Reverse Engineering & Binary Analysis Basics, et ta progression se synchronise sur le web et l'application CoddyKit. Le cours Reverse Engineering & Binary Analysis Basics comprend 4 leçons au total.

Certaines parties de cette leçon n'ont pas encore été traduites et s'affichent en anglais.

Why Packers Block You

You understand obfuscation, can bypass anti-analysis checks, and grasp kernel-mode debugging. A common obstacle remains: packers that compress or encrypt the real code so static tools see only a stub.

What a Packer Does

A packer wraps the original program. At runtime a small unpacking stub decompresses or decrypts the real code into memory, then jumps to it.

  • Smaller file size
  • Hidden strings and imports
  • Defeats naive static analysis

Detecting a Packed Binary

Signs of packing:

  • High entropy sections (looks random)
  • Few imports, odd section names like UPX0
  • Tiny code region with a large memory allocation

Tools like Detect It Easy or PEiD flag known packers.

die target.exe
# UPX 3.96 detected; section UPX1 entropy 7.9

Static Unpacking

For well-known packers, a tool can reverse the process directly. UPX, for instance, has a built-in decompressor.

upx -d target.exe -o target_unpacked.exe

When Static Won't Work

Custom or modified packers have no public unpacker. Then you let the stub do the work: run it under a debugger until the real code is in memory, then capture it.

This is generic, manual unpacking.

The Original Entry Point

The OEP (Original Entry Point) is where the unpacked program's real execution begins. The stub jumps there after unpacking.

Finding the OEP is the key milestone: at that moment, the real code is fully unpacked in memory.

Finding the OEP: Tail Jump

Stubs typically end with a far jump or push/ret into the unpacked region (the tail jump). Set a breakpoint there; when it fires, the next instruction is the OEP.

; end of stub
popad
jmp 0x00401000   ; <- jumps to OEP

Memory Write Breakpoint Trick

Another technique: set a hardware breakpoint on execute for the region the stub writes code into. Execution stops the instant the unpacked code runs.

ESP/stack-based tricks (the 'pushad/popad' method) also locate the tail.

Dumping the Process

At the OEP, dump the in-memory image to disk with a tool like Scylla or a debugger plugin.

The dump contains decrypted code and strings, but the import table is broken because it was resolved at runtime.

Rebuilding the Import Table

The final step is IAT reconstruction: tools like Scylla scan memory for the resolved imports and rebuild a valid Import Address Table, producing a clean, statically-analyzable executable.

Multi-Layer Packing

Tough samples stack several packers. After dumping, your unpacked image may itself be packed again. Re-run detection on the dump.

Repeat the run-to-OEP-and-dump cycle until entropy drops and real strings and imports finally appear.

Quick Check

When manually unpacking, why is reaching the OEP the critical moment to dump the process?

Recap

You can now strip packers off protected binaries:

  • Detect packing via entropy, sections, and imports
  • Use known unpackers or run the stub to the OEP
  • Find the tail jump, dump at the OEP, rebuild the IAT

The result is a clean image ready for full static analysis.

Questions Fréquemment Posées

La leçon « Contourner les compacteurs et atteindre l’OEP » est-elle gratuite ?

Oui — le texte complet de « Contourner les compacteurs et atteindre l’OEP » est gratuit à lire ici sur le web. Pour la pratiquer de manière interactive (un éditeur de code intégré et un tuteur IA 24/7) et déverrouiller le reste du cours Reverse Engineering & Binary Analysis Basics, passe à CoddyKit PRO. Le cours Reverse Engineering & Binary Analysis Basics comprend 4 leçons au total.

Qu'est-ce que j'apprendrai dans « Contourner les compacteurs et atteindre l’OEP » ?

Identifiez les compacteurs utilisés à l’exécution, trouvez le point d’entrée original et extrayez une image décompactée pour analyser statiquement et proprement les binaires protégés contre la rétro-… Tu pratiques Reverse Engineering & Binary Analysis Basics avec du code pratique que tu exécutes directement dans le navigateur, et un tuteur IA 24/7 répond à tes questions au fur et à mesure que tu avances dans la leçon.

Dois-je avoir de l'expérience pour commencer Reverse Engineering & Binary Analysis Basics ?

Aucune expérience préalable n'est requise. Reverse Engineering & Binary Analysis Basics sur CoddyKit est structuré pour les débutants jusqu'aux apprenants avancés, donc tu peux commencer ici ou depuis le début et avancer à ton rythme. Ceci est la leçon 4 sur 4.

Combien de temps prend la leçon « Contourner les compacteurs et atteindre l’OEP » ?

La plupart des leçons CoddyKit prennent environ 5–10 minutes. Chacune est courte et interactive, tu progresses régulièrement et tu repiques exactement où tu t'es arrêté sur le web et l'app.

Peux-tu écrire et exécuter du code dans cette leçon Reverse Engineering & Binary Analysis Basics ?

Oui. Chaque leçon Reverse Engineering & Binary Analysis Basics inclut un éditeur de code intégré, tu écris et exécutes du vrai code directement dans ton navigateur et tu reçois des retours IA instantanés — aucune configuration locale requise.

Toutes les leçons de ce cours

  1. Comprendre les techniques d’obfuscation
  2. Contourner les mesures anti-analyse
  3. Notions de débogage en mode noyau
  4. Contourner les compacteurs et atteindre l’OEP
← Retour à Reverse Engineering & Binary Analysis Basics