← 返回命令列表

Linux command

mat2 命令

文件

复制后可按需替换文件名、目录或参数。

常用示例

Remove metadata from file

mat2 [file.jpg]

Check for metadata

mat2 --show [file.pdf]

Remove metadata in place

mat2 --inplace [file.docx]

Process all files in directory

mat2 [*.jpg]

Lightweight cleaning

mat2 --lightweight [video.mp4]

List supported formats

mat2 --list

Check dependencies

mat2 --check-dependencies

说明

mat2 (Metadata Anonymisation Toolkit 2) removes metadata from files to protect privacy. It strips identifying information from images, documents, audio, and video. Images may contain EXIF data with camera model, GPS coordinates, timestamps, and software used. Documents embed author names, revision history, and editing times. Audio files include artist, encoding software, and recording details. By default, mat2 creates cleaned copies with `.cleaned` inserted between the filename and extension (e.g., `file.cleaned.jpg`). Inplace mode modifies originals directly. The show option reveals metadata without modification. Supported formats include JPEG, PNG, PDF, DOCX, ODT, MP3, MP4, FLAC, and many others. Archive formats (ZIP, TAR) are processed recursively. Lightweight mode provides faster cleaning for formats like video where full processing is slow, at the cost of less thorough metadata removal.

参数

-s, --show
List harmful metadata detectable by mat2 without removing them.
--inplace
Clean files in place, without creating a backup.
-L, --lightweight
Remove some metadata, trading thoroughness for the guarantee that file data is not modified.
-l, --list
List all supported file formats.
--check-dependencies
Check if mat2 has all the dependencies it needs.
--no-sandbox
Disable bubblewrap's sandboxing.
--unknown-members _POLICY_
Policy for handling unknown members of archive-style files (abort, omit, keep).
-V, --verbose
Show more verbose status information.
-v, --version
Show version number and exit.
-h, --help
Show help message and exit.

FAQ

What is the mat2 command used for?

mat2 (Metadata Anonymisation Toolkit 2) removes metadata from files to protect privacy. It strips identifying information from images, documents, audio, and video. Images may contain EXIF data with camera model, GPS coordinates, timestamps, and software used. Documents embed author names, revision history, and editing times. Audio files include artist, encoding software, and recording details. By default, mat2 creates cleaned copies with `.cleaned` inserted between the filename and extension (e.g., `file.cleaned.jpg`). Inplace mode modifies originals directly. The show option reveals metadata without modification. Supported formats include JPEG, PNG, PDF, DOCX, ODT, MP3, MP4, FLAC, and many others. Archive formats (ZIP, TAR) are processed recursively. Lightweight mode provides faster cleaning for formats like video where full processing is slow, at the cost of less thorough metadata removal.

How do I run a basic mat2 example?

Run `mat2 [file.jpg]` in a terminal, then adjust file names, paths, flags, or remote targets for your system.

What does -s, --show do in mat2?

List harmful metadata detectable by mat2 without removing them.