Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The "archive" MIME type definition excludes some "zip" MIME types. #140

Open
nuno-andre opened this issue Apr 22, 2021 · 2 comments
Open

Comments

@nuno-andre
Copy link

In 4.6. MIME type groups, ZIP is defined as having an application/zip essence or a zip suffix.

In the following paragraph, archive is described as having application/zip, application/x-rar-compressed or application/x-gzip as an essence, but no mention is made of the zip suffix.

Maybe a definition similar to that of scriptable would be clearer:

An archive MIME type is a ZIP-based MIME type or any MIME type whose essence is one of the following:

  • application/x-rar-compressed
  • application/x-gzip

<p>An <dfn export>archive MIME type</dfn> is any <a>MIME type</a> whose
<!--<span>type</span> is equal to "<code title>archive</code>" or-->
<a for="MIME type">essence</a> is one of the following:
<ul class="brief">
<li><code>application/x-rar-compressed</code>
<li><code>application/zip</code>
<li><code>application/x-gzip</code>
</ul>

@GPHemsley
Copy link
Member

You are correct that the archive MIME type definition does not include the full ZIP-based MIME type definition. It is possible that that was an oversight, but it's also possible that it wasn't.

ZIP-based MIME type is not actually used anywhere in the spec, and archive MIME type is only used as part of the archive type pattern matching algorithm. This algorithm, as written, is never going to detect a MIME type with an essence having a +zip suffix, so it is potentially unnecessary to include such a MIME type in the definition of archive MIME type.

(I'll leave it to someone else to make a final determination.)

@nuno-andre
Copy link
Author

So archive type is somewhat of a misnomer, because .zip files are indeed archives, but .gz isn't. Maybe compressed type would be a more appropriate name?

Cheers!

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

No branches or pull requests

2 participants