{{Header}} {{#seo: |description=Anonymize Files - Clear Metadata - Remove Location Tracking - Use the Metadata Anonymisation Toolkit v2 (MAT2) |image=Mat2icon.png }} [[File:Mat2icon.png|250px|MAT2 Icon|thumb]] {{intro| Anonymize Files - Clear Metadata - Remove Location Tracking - Use the Metadata Anonymisation Toolkit v2 (MAT2) }} = Introduction = {{mbox | image = [[File:Ambox_warning_pn.svg.png|40px]] | text = '''Warning:''' Office documents, pictures, videos and other files contain significant information in the meta tags that may de-anonymize the author. Before they are uploaded to the Internet or shared, this metadata should be removed. }} For more information about metadata, refer to the [https://packages.debian.org/{{Stable project version based on Debian codename}}/mat2 Metadata anonymisation toolkit v2 (MAT2)] Debian package or the [https://0xacab.org/jvoisin/mat2 MAT2 homepage]. Additional information can be found on the Warning page; see [[Warning#Document_Metadata|{{project_name_long}} does not clear Document Metadata]]. = Metadata Risk = Metadata attached to files cannot be used to de-anonymize the user if the guidelines in this section are followed. However, whistleblowers should be aware of a host of other metadata and techniques that can be used to narrow the search for (or identify) leakers, including: https://theintercept.com/2019/08/04/whistleblowers-surveillance-fbi-trump/
rsync
or cp
has been shown to destroy the metadata contained in the "birth" field
crtime on Linux / btime on Windows and is therefore the recommended precaution.
https://www.linuxquestions.org/questions/linux-newbie-8/how-do-i-preserve-crtime-creation-birth-time-when-copying-from-windows-ntfs-to-linux-ext4-4175625229/
Linux filesystems like EXT4 have recently been extended to include file creation time. It can be read using debugfs
https://tecadmin.net/file-creation-time-linux/
, crtime
https://github.com/planetlabs/crtime
or xstat
https://github.com/bernd-wechner/Linux-Tools/blob/master/xstat
. Dedicated tools to scrub this is preferred.
In some cases, opening and re-saving a file can help, but that will only set the "modified" time field. A lot of filesystems also store a "created" time field, which will not be affected by opening/saving. Also, some file formats will actually leak additional info about what software opened them if you open/resave them. So I wouldn't really recommend that approach. I think there exist tools that will wipe filesystem timestamp metadata; if such tools exist (I haven't looked very carefully) then they're probably preferable. -Jeremy Rand (Namecoin dev)
3
N.B. A file's ctime (time created), mtime (time modified) and atime (time accessed) metadata are not related to the crtime/brtime issue discussed above. These can be reset to the current time using touch
:
{{CodeSelect|code=
touch newfile stat
:
{{CodeSelect|code=
stat * Audio Video Interleave (.avi) * Electronic Publication (.epub) * Free Lossless Audio Codec (.flac) * Graphics Interchange Format (.gif) * Hypertext Markup Language (.html) * Portable Network Graphics (PNG) * JPEG (.jpeg, .jpg, ...) * MPEG Audio (.mp3, .mp2, .mp1, .mpa) * MPEG-4 (.mp4) * Office Openxml (.docx, .pptx, .xlsx, ...) * Ogg Vorbis (.ogg) * Open Document (.odt, .odx, .ods, ...) * Portable Document Fileformat (.pdf) * Tape ARchive (.tar, .tar.bz2, .tar.gz) * Torrent (.torrent) * Windows Media Video (.wmv) * ZIP (.zip)
MAT2 only removes metadata from your files, it does not anonymise their content, nor can it handle watermarking, steganography, or any too custom metadata field/system. If you really want to be anonymous, use file formats that do not contain any metadata, or better: use plain-text.== Use Instructions == MAT2 does not have a GUI option and must be run from the command line. For a list of available MAT2 options, launch a terminal in {{project_name_workstation_short}} and run. {{CodeSelect|code= mat2 }} Note: MAT2 does not clean files in-place. Instead, once 'dirty' files (with removable metadata) are cleaned, the clean files are created in the same directory with the {{code|.cleaned}} extension. For example, "myfile.png" will lead to a new version named "myfile.cleaned.png". Users also report that MAT2 is broken if bubblewrap is installed, since it is automatically used for MAT2 sandboxing which is currently incompatible with {{project_name_short}}
hidepid
settings.
https://forums.whonix.org/t/install-bubblewrap-by-default-to-make-use-of-mat2s-sandboxing/8177
https://0xacab.org/jvoisin/mat2/issues/120
https://github.com/containers/bubblewrap/issues/198 If this error is encountered, it can be bypassed with the --no-sandbox
flag.
= Other Tools =
* [https://packages.debian.org/search?keywords=Exiftool Exiftool] - a Perl application for editing metadata in a wide variety of files.
* [https://packages.debian.org/search?keywords=exiv2 exiv2] - a C++ application to manage image metadata.
* [https://packages.debian.org/search?keywords=jhead jhead] - a JPEG header manipulation tool.
* [https://github.com/kanzure/pdfparanoia pdfparanoia] - a tool to remove watermarks from academic papers.
* [https://github.com/firstlookmedia/pdf-redact-tools pdf-redact-tools] - Deprecated.
= See Also =
* [[Surfing Posting Blogging]]
= License =
{{JonDos}} The Metadata page contains content from the JonDonym documentation [https://web.archive.org/web/20120508222640/https://anonymous-proxy-servers.net/en/help-live-cd/jondo-live-cd9.html Anonymizing Documents and Pictures] page.
= Footnotes =
{{reflist|close=1}}
{{Footer}}
[[Category:Documentation]]