_

have you tried analyzing an .exe but realized that PE analyzers expect you to know what 0x00400000 means...? ;-; let's make it beginner friendly & pretty (˶ˆᗜˆ˵)

normal tools are ugly(sorry) and hard to read for beginners. they just throw hex numbers at you and expect you, a beginner, to figure it out. it helps growth, but beginners can't grow from something they don't understand.

this is for the cuties who just wanna know if a file is sus without reading a 400 page manual c:

no!! PE-pal is NOT a virus scanner. it will not tell you if a file is safe or not. it will only show you the internal structure of the file and highlight suspicious elements.

  • a PE analyzer is designed to dissect and examine the internal structure of executable files.
  • a virus scanner is designed to detect and remove malicious software.

if you want to check if a file is safe, try uploading it to virustotal.

seeing an indicator in a PE analyzer does not automatically mean a file is malicious! software developers often use those exact same things for legitimate reasons. finding a sus trait in an analyzer means you should take a closer look, not that it is dangerous.

the simple version: you give PE-pal a Windows executable file. it reads the file and extracts information about its structure and what functions it uses. then it displays that info in a cute format so you don't have to stare at random hex numbers :D

"what's inside a PE file?"

  • the DOS header: the file saying "haiii, i'm an executable!" (it always starts with 4D 5A = "MZ" in text)
  • sections: containers that hold code (.text), data (.data), or other stuff. each section is encrypted or not depending on how sophisticated the malware is.
  • the import table (IAT): a list of functions the .exe is calling from Windows. like if it's calling CreateRemoteThread, that's sus because it lets you inject code into other processes.
  • strings: readable text hidden in the binary like URLs, file paths, IPs, or registry keys. malware sometimes leaves these as clues c;
  • the rich header: metadata that shows which compiler version built the file (usually hidden by malware to cover its tracks)

"what does PE-pal do with this?"

  • entropy analysis: measures how "random" each section is. normal code has patterns, encrypted/packed malware doesn't. it's a jumbled mess. (entropy > 7.0 = sus)
  • function classification: groups imported functions by behavior (networking, file system, process injection, etc.) so you can see what the malware is trying to do, in simple terms.
  • string flagging: highlights URLs, IPs, and file paths as suspicious since badly-written malware sometimes hardcodes these
  • compiler tracking: shows the compiler timeline so you can see if the file is a frankenstein of different builds

"how does the code work?"

  • you drag a file and the browser loads it into memory as bytes
  • web worker processes it and a separate JavaScript thread (worker.js) parses the PE structure without freezing the UI. it reads binary data using DataView API to extract all the things mentioned above.
  • calculations happen. entropy is calculated for each section using information theory (frequency analysis). then, functions are categorized. strings are extracted by scanning for readable ASCII text in the hex.
  • data flows back. the worker sends results to the main thread, which renders cutie charts so you can actually understand what's going on :3
  • no files leave your computer! everything happens in your browser's memory. the moment you close the tab, it'll all be gone.

tl;dr: PE-pal is a binary file translator. it reads the instructions inside your PE file and tells you what it's trying to do in a language that doesn't require a compsci degree to understand! (´ ▽` )b

paranoid? good! welcome to infosec o_o

this runs 100% in your browser. the file never leaves your pc. you won't be uploading anything to my servers. all this happens locally through javascript (ᵔ▭ᵔ)

how to use (guide 4 dummies)

01.

find a sus file

got any sus PE from trying to download free games? no? then click [ generate fake malware ] above to see a demo instantly.

02.

drag and drop!

throw it into the box on the next page!(ᵔ▭ᵔ)

03.

inspect the stuff

hover over the (???) icons to see explanations or warnings about suspicious elements. the web is your best friend here! search the function names online to learn more.

PE-pal :3
[ FILE ]

drop it here (ᵔ▭ᵔ)

.exe  .dll  .sys  .ocx

initializing... (◕‿◕)
parsing file... [............] 0%

filename.exe

ARCH SIZE TS

file anatomy map  (???) this map shows how much space each section of the PE takes up. if a section is pink and striped, it's sus! click a segment to highlight it on the hex viewer below.

section breakdown  (???) sections are containers inside the file. we check their 'entropy' (randomness). normal code has patterns. encrypted/packed malware is obfuscated (random mess). anything above 7.0 is sus.

name
entropy
size
red flags
characteristics

import table (IAT)  (???) the import table is the list of external functions the .exe is calling. if it's calling things like CreateRemoteThread or URLDownloadToFile, it may be a red flag! pink function names are usually sus, but not always. some apps genuinely need it! the web is your best friend here.

malware intent analysis  (???) here is a pie chart of the imported functions categorized by their behavior. a file that mainly imports 'process injection' functions is probably trying to hide inside another process.

string dump  (???) here is every byte scanned as we looked for readable text! pink strings are sus because they're URLs, IP addresses or file paths. some poorly-made malware has these hardcoded in plain sight. they're usually undetectable in modern malware, so don't rely on this alone.

compilation timeline (rich header)  (???) microsoft compilers secretly embed a 'rich header' between the DOS stub and PE signature. it records which compiler versions built each part of the file. malware sometimes zeroes this out to hide its origins.

raw hex viewer  (???) this shows the raw bytes of the file in hexadecimal. click a section in the map or list above to jump to it here and light it up in cyan. shows first 64KB max.

every file on ur computer is just bytes. bytes are numbers from 0 to 255. this viewer shows the raw bytes of the file you dropped in hexadecimal (base 16). one byte is exactly two hexadecimal digits, from 00 to FF.

each row has three columns: offset (where in the file this row starts, starting from zero)  →  hex bytes (the actual byte values)  →  ascii (what those bytes look like as text. a dot (".") means the byte isn't a printable character).

why hex? 1 byte is exactly 2 hexadecimal digits, and it's more compact than decimal. the very first two bytes of any .exe file are always 4D 5A. that's the MZ signature! it tells windows "haiii, i'm an executable!" (it was named after Mark Zbikowski, a DOS developer at Microsoft in 1981 !!)

click any section in the map or list above and this viewer jumps to those bytes and highlights them in cyan. you are looking at raw machine code/data that your CPU loads into memory.