Author Topic: PDF exported from Adobe Illustrator incorrectly identified  (Read 1622 times)

crobbers

  • Newbie
  • *
  • Posts: 4
PDF exported from Adobe Illustrator incorrectly identified
« on: March 14, 2016, 04:16:22 PM »
PDF files exported from Adobe Illustrator are incorrectly identified as "application/vnd.adobe.illustrator" when the file lacks a .pdf extension. When the file has  a .pdf extension it is correctly identified as "application/pdf".

I have confirmed this on Windows and SmartOS/Solaris using version 10.00.

Code: [Select]
exiftool.exe test.pdf

ExifTool Version Number         : 10.00
File Name                       : test.pdf
Directory                       :
File Size                       : 11 MB
File Modification Date/Time     : 2016:03:02 14:41:37-08:00
File Access Date/Time           : 2016:03:02 14:41:32-08:00
File Creation Date/Time         : 2016:03:02 14:41:32-08:00
File Permissions                : rw-rw-rw-
File Type                       : PDF
File Type Extension             : pdf
MIME Type                       : application/pdf
PDF Version                     : 1.4
Linearized                      : Yes
XMP Toolkit                     : Adobe XMP Core 5.6-c111 79.158366, 2015/09/25-01:12:00
...

exiftool.exe test
ExifTool Version Number         : 10.00
File Name                       : test
Directory                       :
File Size                       : 11 MB
File Modification Date/Time     : 2016:03:02 14:41:37-08:00
File Access Date/Time           : 2016:03:02 14:41:32-08:00
File Creation Date/Time         : 2016:03:02 14:41:32-08:00
File Permissions                : rw-rw-rw-
File Type                       : AI
File Type Extension             : ai
MIME Type                       : application/vnd.adobe.illustrator
PDF Version                     : 1.4
Linearized                      : Yes
XMP Toolkit                     : Adobe XMP Core 5.6-c111 79.158366, 2015/09/25-01:12:00
...

I wouldn't think that the file extension should affect the MIME type. I can provide the pdf upon request but will withhold posting it here publicly.

Phil Harvey

  • ExifTool Author
  • Administrator
  • ExifTool Freak
  • *****
  • Posts: 16885
    • ExifTool Home Page
Re: PDF exported from Adobe Illustrator incorrectly identified
« Reply #1 on: March 15, 2016, 07:18:48 AM »
This is by design.  Illustrator writes .AI files that are indistinguishable from .PDF files as far as I can tell.  ExifTool will think they are AI files if they contain Illustrator metadata unless they have a .PDF extension.

Please tell me if you know of another way to distinguish between PDF-format Illustrator AI files and PDF files.

- Phil
...where DIR is the name of a directory/folder containing the images.  On Mac/Linux, use single quotes (') instead of double quotes (") around arguments containing a dollar sign ($).

crobbers

  • Newbie
  • *
  • Posts: 4
Re: PDF exported from Adobe Illustrator incorrectly identified
« Reply #2 on: March 15, 2016, 03:48:53 PM »
Yeah, it sounds like .AI files are basically .PDF with some extra (optional) metadata. I will rework things on my end to provide the .pdf extension. Thanks for looking into it.