Uploaded image for project: 'Tika'
  1. Tika
  2. TIKA-4111

iWork keynote file with wrong extension not detected properly

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Minor
    • Resolution: Fixed
    • 2.8.0
    • 2.9.0
    • detector
    • None

    Description

      Attached keynote file, without the *.key extension, should be detected as "application/vnd.apple.keynote.13" but is being detected as "application/vnd.apple.unknown.13". 

      The IWork13PackageParser.detect(ZipFile) method iterates over zip entries and calls detectIfPossible(ZipEntry) multiple times. Inside the last method, the check for "Index/MasterSlide-" or "Index/Slide-" files should work, they are found inside the attached file. But since those entries can appear in arbitrary order, the "Index/Document.iwa" entry is found before and then "application/vnd.apple.unknown.13" is returned. The fix is simply returning null when "Index/Document.iwa" entry is found.

       

      Attachments

        1. keynote
          330 kB
          Luís Filipe Nassif

        Activity

          People

            lfcnassif Luís Filipe Nassif
            lfcnassif Luís Filipe Nassif
            Votes:
            1 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: