Shared MIME-info Database


Table of Contents

Introduction
Version
What is this spec?
Language used in this specification
Unified system
Directory layout
The source XML files
The MEDIA/SUBTYPE.xml files
The glob files
The magic files
The XMLnamespaces files
Storing the MIME type using Extended Attributes
Subclassing
Recommended checking order
Non-regular files
Security implications
User modification
Contributors
References

Introduction

Version

This is version 0.12 of the Shared MIME-info Database specification, last updated 09 Oct 2003.

What is this spec?

Many programs and desktops use the MIME system[MIME] to represent the types of files. Frequently, it is necessary to work out the correct MIME type for a file. This is generally done by examining the file's name or contents, and looking up the correct MIME type in a database.

It is also useful to store information about each type, such as a textual description of it, or a list of applications that can be used to view or edit files of that type.

For interoperability, it is useful for different programs to use the same database so that different programs agree on the type of a file and information is not duplicated. It is also helpful for application authors to only have to install new information in one place.

This specification attempts to unify the MIME database systems currently in use by GNOME[GNOME], KDE[KDE] and ROX[ROX], and provide room for future extensibility.

The MIME database does NOT store user preferences (such as a user's preferred application for handling files of a particular type). It may be used to store static information, such as that files of a certain type may be viewed with a particular application.

Language used in this specification

The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119[RFC-2119].