IPTCDigest when there is no IPTC items

Started by gmit, December 28, 2017, 08:22:03 PM

Previous topic - Next topic

gmit

Many of the photos that I look at with exiftool have the same IPTCDigest.  The value is d41d8cd98f00b204e9800998ecf8427e.  By hashing a file with nothing inside I get an MD5 has of that value (a lucky guess, reversing hashes is not generally easy). 

Some .jpg files have no IPTCDigest showing and some have the d41... value. 

Why is that?  I would think that if there is no IPTC information the value would always be the same.


StarGeek

I'd guess that some program computed the IPTCDigest of those files and saved it even though the IPTC was empty.  As you said, that hash is that of an empty value and you can see some examples of it by searching on google.

As to why save that value?  Who knows.  I've seen a lot of weird metadata over the years and it doesn't surprise me that some program out there just doesn't check to see if there is any IPTC data.
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

gmit

The issue that I am having trouble understanding is:  why do many .jpg files have the value for IPTCDigest and others don't (when both have no IPTC data).  This typically seen in a sequence of files, e.g., an image created by an iPhone which has no IPTCDigest info as reported by exiftool.  The same photo will have the IPTCDigest shown after it is touched by a photo editing program.

It may be that the iPhone doesn't create any IPTC data fields (or files?) and there is nothing to hash.  The photo program allows adding IPTC data which enough to tell exiftool to calculate a hash... and the hash is d41d8cd98f00b204e9800998ecf8427e, equal to the  MD5 hash of an empty file.

These sound like picky distinctions but they can become important in forensic cases that we investigate.  See eSleuth.com. 

StarGeek

Quote from: gmit on December 28, 2017, 09:33:00 PM
It may be that the iPhone doesn't create any IPTC data fields (or files?) and there is nothing to hash.  The photo program allows adding IPTC data which enough to tell exiftool to calculate a hash... and the hash is d41d8cd98f00b204e9800998ecf8427e, equal to the  MD5 hash of an empty file.

Don't confuse IPTCDigest, which is an actual tag inside the Photoshop group, and CurrentIPTCDigest, which is a value calculated by exiftool, not internal the file (a "pseudo-tag"), and is part of the Extra Tags group. 

When your photo program is editing the image, it adds the IPTCDigest, though not all programs will do this.  It's software dependent.  If you run exiftool -CurrentIPTCDigest File on a file that doesn't have IPTC data, exiftool won't return any results.
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

gmit

It must be that exiftool's MD5 hash calculation is triggered by an indication that there "could" be IPTC data.  This could be the case when Photoshop changes the file to indicate that IPTC data could be present even when the data fields are still empty.  According to irfanview there is no IPTC data in either of the  test files I used.  The original one from a cellphone showed showed no IPTCDigest and after that file was processed in Photoshop it did have the null hash in IPTCData.

StarGeek

Quote from: gmit on December 28, 2017, 11:13:03 PM
It must be that exiftool's MD5 hash calculation is triggered by an indication that there "could" be IPTC data.

Again, IPTCDigest is an actual tag inside of the file.  Exiftool does not calculate it.  It simply reads it and outputs the value. 

QuoteThe original one from a cellphone showed showed no IPTCDigest and after that file was processed in Photoshop it did have the null hash in IPTCData.

And there is your answer.  Photoshop is adding it to the file.
* Did you read FAQ #3 and use the command listed there?
* Please use the Code button for exiftool code/output.
 
* Please include your OS, Exiftool version, and type of file you're processing (MP4, JPG, etc).

gmit