Files & pages

File Type Sniffer

Runs locallyNew

Use File Type Sniffer

What it does

Drop a file to see what it really is, judged by its bytes rather than its name, and whether the name, extension or contents try to hide that. Nothing is uploaded or opened.

It runs entirely in your browser: nothing you enter is uploaded.

How to use File Type Sniffer

  1. Keep the file closed. Save the attachment or download without opening it.
  2. Drop or choose files. Drop one or more files on the box or choose them. Up to 50 files are checked per drop, each in its own card.
  3. Compare type and extension. Detected type, Kind and Extension appear at the top. A red "does not match" means the name lies about the content.
  4. Read the flags and details. Danger and Warning boxes explain each disguise or risky feature. Below them are the signature bytes, archive entries, PDF keywords and a hex dump of the first bytes.
  5. Take the next step. Follow the suggested tool, such as File Hash Calculator for a VirusTotal lookup, and drop the same file there.

Example

HTML smuggling attachment

Input
Invoice_0425.pdf.html
<html><body><script>
var data = atob('UEsDBBQAAAAIAA==');
var blob = new Blob([data], {type: 'application/zip'});
var a = document.createElement('a');
a.href = URL.createObjectURL(blob);
a.download = 'Invoice_0425.zip';
a.click();
</script></body></html>
Output (captured 2026-10-20)
Invoice_0425.pdf.html

254 B (254 bytes) · read 254 B

DETECTED TYPE
HTML document
KIND
web page text/html
EXTENSION
.html matches

.html fits HTML document.

Danger: HTML smuggling pattern: script decodes embedded data and offers it as a download (Blob/atob/msSaveOrOpenBlob).
Warning: Double extension: ".pdf" is decoration, the real extension is ".html" (a web page posing as a document, typical of phishing attachments).
Text encoding
UTF-8 or ASCII
Script and form hints
script element; atob() Base64 decoding; Blob construction; URL.createObjectURL(); forced download (download attribute)
FIRST 64 BYTES
0000  3C 68 74 6D 6C 3E 3C 62  6F 64 79 3E 3C 73 63 72  <html><body><scr
0010  69 70 74 3E 0A 76 61 72  20 64 61 74 61 20 3D 20  ipt>.var data =
0020  61 74 6F 62 28 27 55 45  73 44 42 42 51 41 41 41  atob('UEsDBBQAAA
0030  41 49 41 41 3D 3D 27 29  3B 0A 76 61 72 20 62 6C  AIAA==');.var bl
Copy hex dump

Next: HTML Attachment Analyzer (inspect scripts, forms and embedded payloads); File Hash Calculator (hash the file for VirusTotal and MalwareBazaar lookups). Open it and drop the same file there.

The first line becomes the file name and the rest its content. The sniffer reports an HTML document, flags the .pdf.html double extension and the HTML smuggling pattern (atob, Blob and a forced download), and points to the HTML Attachment Analyzer.

What it checks

SignalWhat it means
Detected type and extensionThe extension matches, does not match, is not checked or is missing. A mismatch is the core sign of a disguised file.
Code disguised as a document or imageDanger: the content is a program, shortcut or script while the name promises a harmless file. A script saved as .txt gets a warning instead.
Double extensionA name like statement.pdf.exe or invoice.pdf.html: the first extension is decoration.
Right-to-left override and invisible charactersUnicode tricks that make a name display a fake extension. The real extension is reported.
Archive contentsExecutables, scripts, shortcuts, HTML files and double extensions inside a ZIP, encrypted entries and Zip Slip paths are flagged without extracting anything.
Office macros and objectsVBA projects, Excel 4.0 macro sheets, embedded OLE objects, Equation Editor objects and password-protected documents.
PDF keywordsJavaScript with an automatic open action, /Launch, embedded files, form submission and obfuscated names.
Shortcuts and disk imagesLNK files that run command tools or point to remote locations, and ISO, IMG or VHD images used to get around download warnings.
HTML and SVGSmuggling patterns, credential forms that post elsewhere and scripts inside markup.
Appended ZIPA note when a ZIP archive sits at the end of another file: a self-extracting archive, an installer or a polyglot file that is valid in two formats.

More examples

A program inside a ZIP

Input
Statement.zip containing one file, Statement.pdf.exe
Result

ZIP archive, .zip matches. Two danger flags: it contains 1 executable, script or shortcut file (Statement.pdf.exe), and an entry name has a double extension. The Entries list marks the file "runs code".

An executable named as a photo

Input
photo.jpg, a 64-byte file that starts with the bytes 4D 5A (MZ)
Result

DOS / 16-bit executable (MZ); .jpg does not match. Danger: the executable is disguised as .jpg, a name that promises a harmless file while the content is code.

A PDF that runs JavaScript on open

Input
scan.pdf whose /OpenAction points to a /JavaScript action
Result

PDF document, .pdf matches. Danger: it contains JavaScript and an automatic action that can run it when the file opens. The Keywords row lists /JavaScript, /JS and /OpenAction.

FAQ

How does the sniffer decide what a file is?

It compares the first bytes, and fixed offsets such as 0x8001 for ISO images or 257 for TAR, with about 100 format signatures, then looks inside ZIP, OLE2, PE, LNK, PDF and RTF structures: Office parts and macros, MSI and Outlook streams, EXE or DLL and CPU type, shortcut targets and PDF action keywords. Text files are classified by markers such as a shebang line, HTML tags or PowerShell syntax.

What can it miss or get wrong?

Text formats are recognised by heuristics, so a short script can be reported as plain text, and PDF keywords inside compressed object streams are not visible to it. It describes the file type and disguise tricks but does not scan for malware, so a clean result is not a verdict.

Is the file uploaded or opened?

No. The browser reads only the byte ranges it needs from the file on your device, nothing is executed or rendered, and nothing is sent over the network.

Why can a file named .jpg or .pdf be dangerous?

Mail filters often judge a file by its extension. A program renamed to .jpg can slip past them and only needs a rename or a loader to run again, and an HTML page named .pdf may open in a browser as a fake login page.

Can I check several files at once?

Yes. Drop or choose up to 50 files; each gets its own result card, and Clear removes them all.

What should I do after a danger flag?

Do not open the file. Hash it with File Hash Calculator, look the SHA-256 up on VirusTotal or MalwareBazaar, and report the sender to your mail provider.

Terms explained

PhishDestroy research