Best EXIF Tools to Anonymize Images in Linux

A photograph showing a person on a laptop with a camera on their side.

The Exchangeable Image File Format (EXIF) is an extensive framework for storing an image’s metadata. While useful for cataloging photos, it can be a problem for privacy-conscious users. This is because EXIF contains sensitive information such as the type of camera lens and the location of where you took your photo. This article will show you some of the best tools that you can use to read, modify, and remove EXIF tags on your pictures in Linux.

Metadata Cleaner is an easy-to-use graphical utility that can remove EXIF data from your images. Based on the powerful mat2 CLI program, it provides a sleek and accessible drag-and-drop interface that can both read and delete metadata. This makes it attractive to users who don’t want to run command-line programs when anonymizing their images.

A screenshot showing the default Metadata Cleaner screen.

One of the biggest features of Metadata Cleaner is that it can also remove metadata from non-image files. For instance, the app can remove sensitive info from MP3 files, MP4 videos, and PDF documents. As such, Metadata Cleaner is a great “one-stop app” for anonymizing your digital files.

Pros

  • Comes with a sleek and accessible GUI
  • Available as a portable Flatpak app
  • Can remove metadata from non-image files

Cons

  • Doesn’t support MKV and WebM files
  • Doesn’t provide an option to create a “clean” file copy when removing metadata
  • Flatpak sandboxing can lead to issues when accessing local files

FYI: learn how you can use Flatpak to install the Telegram messenger on Linux.

ExifTool is a highly versatile command line program for reading and removing EXIF tags in Linux. It supports a wide variety of formats including XMP, JFIF, and even ID3. Further, ExifTool also supports batch processing which makes anonymizing your images both quick and easy.

A terminal showing the default output for ExifTool when ran with a command.

Exiftool can also create “metadata-only” backups of your images and create custom user tags that can include any type of text data. This makes it useful for both privacy-conscious users and data archivists who want to clean their images and preserve their metadata.

Pros

  • Supports a large number of metadata formats
  • Can export EXIF data on external backup files
  • Can do batch processing when modifying and removing EXIF data

Cons

  • Requires familiarity with the command line
  • The default output can be obtuse to new users
  • Doesn’t fully remove the EXIF metadata on some image formats

3. ImageMagick

ImageMagick is a powerhouse software suite that can strip metadata from any image file. With its identify and mogrify options, ImageMagick can read and remove any data from your images including custom user comments.

A terminal showing ImageMagick's identity utility.

One of the selling points of ImageMagick is that it does more than remove data from your images. It can create, edit, and even convert them from one format to another. This makes it a handy tool if you’re looking for an “all-in-one” tool that can handle both EXIF and image editing.

Pros

  • Can generate and convert images on the fly
  • Installed in most Linux distros as a dependency
  • Has the tools to do basic image editing on the command line

Cons

  • Doesn’t remove all metadata from a digital image
  • EXIF removal options can be limited
  • Might recompress the image after you remove its metadata

Good to know: explore more of ImageMagick’s capabilities by optimizing and resizing images from the Linux termal.

4. jhead

Jhead is a simple EXIF manipulation tool for Linux. Unlike ExifTool and ImageMagick, jhead specializes in reading and editing the headers of JPEG images. By default, it can read and remove all the standard tags out of JPEG images. This includes your camera’s sensor, make, and even your distance from the image’s subject.

A terminal showing the default output of the jhead utility while opening  an image file.

Another key feature of jhead compared to other tools is its focus on software minimalism. The developer of jhead designed the program to be as simple and self-contained as possible. Not only does this make the program run fast, but it can also be a good starting point for any new programmer who’s interested in learning about JPEG and the EXIF data structure.

Pros

  • Source code is simple and doesn’t require any additional dependencies
  • Runs fast on computers with little to no resources
  • Provides most of the features available in larger EXIF tools

Cons

  • Only works with JPEG files
  • Its simplicity can be limiting to some users
  • Can be unfriendly to non-programmers

5. Exiv2

Exiv2 is a powerful command line program for reading and removing EXIF metadata in Linux. Similar to ExifTool, it can work with several formats such as EXIF, IPTC, and ICC color data. This makes the app flexible to the types of info that you can modify making it useful for both image analysis and anonymization.

A terminal showing the default output of the Exiv2 utility while loading an image file.

Aside from that, another selling point of Exiv2 is its ability to correct any encoding errors and its shorthand notation for adjusting any EXIF metadata tag. For example, you can run exiv2 ad -Y 1 ./image.jpg to add one year on the timestamp of “image.jpg.” Ultimately, Exiv2 is a great “all-in-one” tool not only for removing metadata but also for analyzing and tweaking it.

Pros

  • Comes with several shorthand commands for quickly editing and removing EXIF data
  • Comes with a C++ library that you can use to add Exiv2 to your own programs
  • Can correct encoding errors and has a special function for fixing the ISO tags on images from Canon and Nikon cameras

Cons

  • The default output can be lacking for some users
  • Doesn’t have as much format support compared to ExifTool
  • Some distros might not have it in their repositories

Anonymizing your images by either removing or modifying their EXIF data in Linux is just the first step in reclaiming your digital privacy. Learn how you can also remove EXIF tags from your pictures on Android.

Image credit: No Revisions via Unsplash. All alterations and screenshots by Ramces Red.

Subscribe to our newsletter!

Our latest tutorials delivered straight to your inbox

Ramces Red

Ramces is a technology writer that lived with computers all his life. A prolific reader and a student of Anthropology, he is an eccentric character that writes articles about Linux and anything *nix.

Leave a Reply

Your email address will not be published. Required fields are marked *