Skip to content

What files are allowed in META-INF? #1205

Closed

Description

@dauwhe

OCF says,

All other files within the OCF Abstract Container MAY be in any location descendant from the Root Directory, provided they are not within the META-INF directory.

but also says

This directory contains the files specified in META-INF Reserved Files. Files other than the ones listed in that section MAY be included in the META-INF directory;

I just made an EPUB with a content document in META-INF. EPUBCheck did not complain, and the file worked as expected in several reading systems.

Perhaps we should delete ", provided they are not within the META-INF directory."?

Activity

  1. mattgarrish commented on Jan 7, 2019

    @mattgarrish
    Member

    Perhaps we should delete ", provided they are not within the META-INF directory."

    Or file a bug with epubcheck... ;)

    The META-INF directory is supposed to be reserved for configuration files like the ones we do list, or so I've always understood it. My vote would be to keep that separation intact and perhaps better explain what is meant by allowing other files in it (i.e., other configuration files). META-INF has never been very well introduced, to be honest, so unless people know it from jar files, etc. it's probably a bit of a head scratcher.

  2. dauwhe commented on Jan 7, 2019

    @dauwhe
    ContributorAuthor

    Or file a bug with epubcheck... ;)

    Although that makes the most sense, I'm worried about effectively invalidating existing content. But then that content would likely be broken anyway due to the differing base URI inside META-INF? It all makes my head spin.

  3. mattgarrish commented on Jan 7, 2019

    @mattgarrish
    Member

    I'm worried about effectively invalidating existing content.

    I think this one might be more theoretical than practical. In all my days picking apart epubs for accessibility, I've never seen a content file inside of META-INF. There also used to be (may still be?) bugs referencing content outside of the directory that the package document is in, and most epubs I've ever seen follow the practice of isolating the content within a subdirectory. (That came up when we were looking at multiple renditions and sharing content, so it's been a few years.)

  4. added
    Agenda+Issues that should be discussed during the next working group call.
    on Jan 16, 2019
  5. murata2makoto commented on Jan 17, 2019

    @murata2makoto
    Contributor

    The EBPAJ profile clearly recommends a different directory (/item) for all user files.

  6. dauwhe commented on Feb 13, 2019

    @dauwhe
    ContributorAuthor

    Perhaps a warning from EPUBCheck if a file referenced from a package document is in META-INF?

    All other files within the OCF Abstract Container MAY be in any location descendant from the Root Directory, provided they are not within the META-INF directory. In particular, files referenced from any Rendition of an EPUB SHOULD NOT be in META-INF.

  7. murata2makoto commented on Feb 13, 2019

    @murata2makoto
    Contributor

    Do some ebook stores use META-INF for proprietary DRM files?

  8. GarthConboy commented on Feb 14, 2019

    @GarthConboy

    @murata2makoto -- I think Dave's warning would be okay, as any such files wouldn't be listed in the Publication's Package manifest (and FWIW, I've never seen such thing happen, anyhow).

  9. mattgarrish commented on Feb 14, 2019

    @mattgarrish
    Member

    In particular, files referenced from any Rendition of an EPUB SHOULD NOT be in META-INF.

    I think this contradicts the first statement.

    How about a fuller rewrite to also focus on the "configuration" aspect. So change the the following paragraphs in 3.2 to:

    The OCF Abstract Container MUST include a directory for configuration files named META-INF that is a direct child of the container's Root Directory. Requirements for the contents of this directory are described in META-INF Directory.

    and swap your should not to a must not

    All other files within the OCF Abstract Container MAY be in any location descendant from the Root Directory, provided they are not within the META-INF directory. In particular, files referenced from any Rendition of an EPUB Publication MUST NOT be in META-INF.

    and then change the paragraph in 3.5.1 to:

    This directory is reserved for configuration files, in particular those specified in META-INF Reserved Files. OCF Processors MUST NOT fail when encountering configuration files they do not recognize.

    That should make it about as clear as we can get.

  10. murata2makoto commented on Feb 14, 2019

    @murata2makoto
    Contributor

    LCP uses META-INF/license.lcpl.

  11. GarthConboy commented on Feb 14, 2019

    @GarthConboy

    Though not referenced from the Publication's Manifest, right? Similar to Apple's old fixed layout metadata? These both would be okay as "configuration" files in META-INF.

  12. murata2makoto commented on Feb 14, 2019

    @murata2makoto
    Contributor

    @GarthConboy

    Though not referenced from the Publication's Manifest, right?

    I believe so. It is referenced by encryption.xml.

  13. added
    Status-DeferredThe issue has been deferred to another revision
    and removed
    Agenda+Issues that should be discussed during the next working group call.
    on Apr 10, 2019
  14. removed
    Status-DeferredThe issue has been deferred to another revision
    on Nov 18, 2020
  15. dauwhe commented on Nov 18, 2020

    @dauwhe
    ContributorAuthor

    Shall we clean this up in 3.3? Looks like we have a reasonable proposal.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    EPUB33Issues fixed in the EPUB 3.3 revisionSpec-EPUB3The issue affects the core EPUB 3.X Recommendation

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions