LA RIPARERIA · ROME, TRASTEVERE
Binary file signatures
Recognise candidate file formats and validate their structures.
Common headers
PDF begins with 25 50 44 46 2D; PNG uses 89 50 4E 47 0D 0A 1A 0A; JPEG commonly begins FF D8 FF; ZIP local headers use 50 4B 03 04.
Containers
DOCX and XLSX both use ZIP containers; inspect internal structures to distinguish them. GIF, SQLite, OLE and RIFF also require format-specific checks. A header alone does not prove validity.
REPAIR FIRST.
Tell us what happened.
Describe the symptoms and tell us whether important data needs protecting.
