MetaSpy is a powerful, multi-format metadata extractor built in Python. It supports various file types including images, audio, video, PDFs, DOCX, and binary files, making it ideal for digital forensics, file auditing, and ethical hacking investigations.
Developed by Soham
- ✅ MIME type auto-detection using
python-magic - 🖼️ EXIF extraction from images (JPEG, PNG)
- 🎵 ID3 tag reading for MP3/FLAC/etc.
- 🎥 Video metadata from MP4, MKV, AVI using
pymediainfo - 📄 PDF and DOCX metadata
- 🛠️ Binary file parsing via Hachoir
- 📤 Optional JSON export
- 💻 Clean CLI interface
- Python 3.8+
Install all dependencies via pip:
pip install python-magic Pillow mutagen pymediainfo PyPDF2 python-docx hachoir- Install the following packages to support MIME detection and media metadata extraction:
sudo apt update
sudo apt install -y libmagic1 mediainfo-
- MediaInfo CLI:
-
Download from MediaInfo official site and add it to your system PATH environment variable.
-
- libmagic binaries:
-
Download Windows binaries for libmagic from here and ensure they are accessible.
-
- Alternatively, use the Python package bundling libmagic for Windows:
- Run from the command line:
python metaspy.py <file_path> [--json]- Examples:
python metaspy.py sample.jpg
python metaspy.py document.pdf
python metaspy.py video.mp4 --json