PPT Security and Privacy: Hidden Data to Check
Review active content, parser risks and hidden metadata before opening or sharing PPT files.
Active Content That Survives Superficial Deletion
PPT files, particularly those authored in PowerPoint 97–2003, retain executable and interactive elements that persist after slides are deleted or properties are cleared. The MS-PPT specification defines a binary compound document structure in which each record type—from slide layout to embedded object—carries its own permissions and hidden payloads. Unlike a static rendering, a PPT is a container of linked streams that can execute code, fetch remote resources, or expose edit history without the viewer’s awareness.
Macro-Enabled Objects and Executable Attachments
The highest-risk active content in legacy PPT files is embedded Visual Basic for Applications (VBA) macros. These are stored as ExOleObjStg or MacroObject records inside the OLE compound file. A macro can fire on open, close, or after a timed trigger even when every visible slide appears blank. The “Enable Content” dialog in PowerPoint is not a reliable gate; macros can reside in slides excluded from the slide-sorter view, in the Slide Master layer, or attached to shapes with zero opacity and no fill.
To verify macro presence without executing the file:
- Open the file with a binary-safe tool. For PPTX this is a ZIP archive; for binary PPT, use
olevbafrom theoletoolssuite. - Search the raw bytes for the hex signature
1C 00 00 00 01 00 00 00, which indicates a macro-enabled OLE stream. - Run
olevba file.pptand inspect the output. If the report containsMacroorVBAMacro, the file is unsafe to open outside a sandbox.
A file confirmed to contain macros should be opened only in an environment that disables macro execution entirely, such as LibreOffice launched with --norestore --safe, or inside an air-gapped VM with no network access.
Embedded Media and External Links
PPT permits embedding of audio, video, and hyperlinks that trigger outbound network requests on open. A file that appears self-contained can still beacon to an external server. The following record types are common carriers of hidden URIs:
- NotesSlide and Comment records: Plaintext or HTML links stored in these streams bypass visual inspection because the Notes pane or comment sidebar may be collapsed by default.
- Hyperlink records: Every shape and text run can carry a
Hyperlinkrecord pointing to a URI. Extract all URIs without rendering by runningexiftool -Hyperlink* file.pptorppt2txt file.ppt | grep -E '(http|https|ftp|file|mailto)'. - ExObjRef records: A media object reference that points to a URL rather than an embedded file. If the media data is absent from the
Datastream, playback will fetch it remotely.
To confirm no external content loads, open the file in a network-isolated environment and monitor all DNS and outbound TCP connections. Any unexpected traffic identifies a leak vector that must be neutralized before the file is shared.
Hidden Metadata Streams in the Binary Format
Binary PPT files contain metadata streams that are invisible in the Document Properties dialog and are not cleared by the “Remove Personal Information” command in older PowerPoint versions. The MS-PPT specification defines several persistent record types:
- SummaryInformation and DocumentSummaryInformation streams: OLE substreams that hold
LastPrinted,RevisionNumber,TotalEditTime,LastAuthor, and other fields. These often survive property-inspection wipes. - Thumbnail record: A bitmap preview of the first slide generated at save time. The thumbnail can contain text or images that were deleted from the main slide content, leaking drafts or confidential data.
- History record (type
0x0FA0): An undo/redo log that stores past text, object positions, and deletion operations. This record is not exposed by any standard UI and must be extracted with a hex editor or a dedicated PPT parser.
Validation step: Run olemeta file.ppt to enumerate all metadata streams. Then run strings file.ppt | grep -E '(LastAuthor|EditTime|Thumb)' to surface residual data. If any stream contains information that must not be shared, the file cannot be sanitized by deleting slides or clearing properties. The only reliable remediation is to reconstruct the presentation from scratch by copying visible slide content into a new file.
Parser Exploitation: Record Length and Recursive References
Binary PPT uses a record-chaining system in which every record carries a 4-bit recVer, a 16-bit recType, and a 32-bit recLen. Parsers that trust these fields without boundary checks are vulnerable to several classes of attack:
- Record length overflow: A
recLenvalue larger than the actual data in the stream causes the parser to read beyond the record boundary into adjacent memory.SlideLayout,MasterSlide, andExControlrecords are common targets. - Recursive object references:
ExObjRefandExObjListrecords can form cycles that exhaust stack memory in older parsers, including Microsoft Office 2003 and LibreOffice versions prior to 6.4. - Corrupt OLE sector chains: The compound file’s DIFAT, FAT, and mini-FAT structures can be manipulated so that sectors overlap, causing the parser to execute attacker-controlled code when reading
TextorShaperecords.
Mitigation: Before opening an untrusted PPT, validate the file with a tool that parses the record structure without rendering. libreoffice --headless --convert-to pdf --infilter="MS PowerPoint 97" file.ppt will crash on malformed records, revealing the file as potentially hostile. If the tool reports “unexpected end of sector chain” or “invalid record type,” no single viewer should be trusted to render it safely.
Verification Workflow for Hidden Data
The following sequence exposes the most common hidden-data categories without requiring a full reverse-engineering toolkit:
Extract all text and hyperlinks without rendering
cat file.ppt | strings -n 4 | grep -E '(http|https|ftp|file|mailto)'
This catches URIs in slide notes, comments, and shape properties that the PowerPoint UI may not display.Dump all OLE streams
olefile file.pptlists every substream, including those PowerPoint hides:MacroPreview,Thumbnail,History. Compare the stream count before and after editing to verify whether deletions actually removed data.Check for macro signatures
olevba file.pptreports all VBA code, including password-protected modules and macros on hidden slides. A non-empty result means the file is unsafe for a non-sandboxed environment.Reconstruct from clean slides
The only reliable removal method is to copy visible slide content into a new presentation (File → New → Paste Special → Unformatted Text). Do not use “Save As” or “Remove Personal Information”—these operations routinely leave residual data in unallocated sectors.
Hard Limits of Sanitization Tools
No automated tool guarantees complete removal of hidden data from binary PPT. The format’s use of slack space in the OLE compound file means that old data can persist in unallocated sectors even after all visible records are rewritten. The only safe disposal method for a PPT that has ever contained sensitive data is:
- Convert to a format that does not support embedded objects or macros, such as plain text or PDF/A-2 with embedded files disabled.
- Shred the original file by overwriting the compound file’s entire physical allocation (e.g.,
shred -n 3 file.ppton Linux).
For metadata removal, exiftool -All= file.ppt clears only the top-level metadata fields. It does not touch Thumbnail, History, or MacroPreview streams. Always verify with a hex dump after any sanitization attempt.
Reference: https://learn.microsoft.com/en-us/openspecs/officefileformats/ms-ppt/