How to clear photos of unwanted Exif data
by Olivier Cleynen
Every time I take a picture with my digital camera, the embedded software stores a large amount of information along with the photo inside the file, contained in EXIF tags.
Some of that EXIF information, such as the date and time the photo was taken, is very useful. Some of it is only interesting to photography enthusiasts: it gives insight into the camera’s performance and the photographer’s adroitness and artistic decisions. A large bunch of the EXIF information, such as the camera distance to the focus point or how exactly the camera reacted to the software’s orders, is entirely useless. And some of that EXIF information is outright harmful.
I cannot see a good reason, indeed, for embedding the camera serial number(!) or mysterious binary blobs of information within the photo file. As the EFF explains very well, a great deal of privacy is given away when digital fingerprints are left on the photos that we share. This is especially true today when the largest companies on the Internet feast on our private information, basing their business model on tracking and reading through our lives and thoughts.
Things needn’t be this way. On a Linux system (for example, Ubuntu), erasing all EXIF data from a large batch of photos is as easy as typing:
exiv2 rm *.JPG
This, however, removes all the useful and potentially interesting information. I wrote a little script called JASESS which reads out the interesting EXIF tags, erases everything, and then puts this selected information back into the file. An EXIF sanitization of sorts.
Under any Linux distribution the script is run as follows:
- Download the little text file
- Make it executable (a right click → properties → permissions)
- Double-click on it in the same folder as your photos.
Running the script can also be made as easy as right click within your file browser, or typing a single letter in your shell prompt.
I strongly encourage anyone to at least briefly read through the script. I made great efforts to comment it extensively, so it may be understood and customized by a beginner. Naturally, feedback is always welcome.