2001-09-29 00:14:13 +04:00
|
|
|
/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2017-07-06 15:00:35 +03:00
|
|
|
|
2000-02-09 06:59:58 +03:00
|
|
|
/*
|
2017-07-06 15:00:35 +03:00
|
|
|
* This interface allows any module to access the encoder/decoder
|
2000-02-09 06:59:58 +03:00
|
|
|
* routines for RFC822 headers. This will allow any mail/news module
|
|
|
|
* to call on these routines.
|
|
|
|
*/
|
|
|
|
#ifndef nsMimeTypes_h_
|
|
|
|
#define nsMimeTypes_h_
|
|
|
|
|
|
|
|
/* Defines for various MIME content-types and encodings.
|
|
|
|
Whenever you type in a content-type, you should use one of these defines
|
|
|
|
instead, to help catch typos, and make central management of them easier.
|
|
|
|
*/
|
|
|
|
|
2013-01-09 01:40:47 +04:00
|
|
|
#define ANY_WILDCARD "*/*"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define AUDIO_WILDCARD "audio/*"
|
|
|
|
#define IMAGE_WILDCARD "image/*"
|
|
|
|
|
|
|
|
#define APPLICATION_APPLEFILE "application/applefile"
|
|
|
|
#define APPLICATION_BINHEX "application/mac-binhex40"
|
|
|
|
#define APPLICATION_MACBINARY "application/x-macbinary"
|
|
|
|
#define APPLICATION_COMPRESS "application/x-compress"
|
|
|
|
#define APPLICATION_COMPRESS2 "application/compress"
|
|
|
|
#define APPLICATION_FORTEZZA_CKL "application/x-fortezza-ckl"
|
|
|
|
#define APPLICATION_FORTEZZA_KRL "application/x-fortezza-krl"
|
|
|
|
#define APPLICATION_GZIP "application/x-gzip"
|
|
|
|
#define APPLICATION_GZIP2 "application/gzip"
|
2002-03-01 02:54:58 +03:00
|
|
|
#define APPLICATION_GZIP3 "application/x-gunzip"
|
2015-09-22 19:55:23 +03:00
|
|
|
#define APPLICATION_BROTLI "application/brotli"
|
2002-03-14 03:51:28 +03:00
|
|
|
#define APPLICATION_ZIP "application/zip"
|
2001-03-25 01:57:35 +03:00
|
|
|
#define APPLICATION_HTTP_INDEX_FORMAT "application/http-index-format"
|
2009-11-21 02:12:42 +03:00
|
|
|
#define APPLICATION_ECMASCRIPT "application/ecmascript"
|
|
|
|
#define APPLICATION_JAVASCRIPT "application/javascript"
|
|
|
|
#define APPLICATION_XJAVASCRIPT "application/x-javascript"
|
2011-08-08 22:32:07 +04:00
|
|
|
#define APPLICATION_JSON "application/json"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define APPLICATION_NETSCAPE_REVOCATION "application/x-netscape-revocation"
|
|
|
|
#define APPLICATION_NS_PROXY_AUTOCONFIG "application/x-ns-proxy-autoconfig"
|
|
|
|
#define APPLICATION_NS_JAVASCRIPT_AUTOCONFIG "application/x-javascript-config"
|
|
|
|
#define APPLICATION_OCTET_STREAM "application/octet-stream"
|
|
|
|
#define APPLICATION_PGP "application/pgp"
|
|
|
|
#define APPLICATION_PGP2 "application/x-pgp-message"
|
|
|
|
#define APPLICATION_POSTSCRIPT "application/postscript"
|
2001-11-19 23:25:53 +03:00
|
|
|
#define APPLICATION_PDF "application/pdf"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define APPLICATION_PRE_ENCRYPTED "application/pre-encrypted"
|
2004-08-08 05:31:02 +04:00
|
|
|
#define APPLICATION_RDF "application/rdf+xml"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define APPLICATION_UUENCODE "application/x-uuencode"
|
|
|
|
#define APPLICATION_UUENCODE2 "application/x-uue"
|
|
|
|
#define APPLICATION_UUENCODE3 "application/uuencode"
|
|
|
|
#define APPLICATION_UUENCODE4 "application/uue"
|
|
|
|
#define APPLICATION_X509_CA_CERT "application/x-x509-ca-cert"
|
|
|
|
#define APPLICATION_X509_SERVER_CERT "application/x-x509-server-cert"
|
|
|
|
#define APPLICATION_X509_EMAIL_CERT "application/x-x509-email-cert"
|
|
|
|
#define APPLICATION_X509_USER_CERT "application/x-x509-user-cert"
|
|
|
|
#define APPLICATION_X509_CRL "application/x-pkcs7-crl"
|
|
|
|
#define APPLICATION_XPKCS7_MIME "application/x-pkcs7-mime"
|
2002-04-12 08:26:40 +04:00
|
|
|
#define APPLICATION_PKCS7_MIME "application/pkcs7-mime"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define APPLICATION_XPKCS7_SIGNATURE "application/x-pkcs7-signature"
|
2002-08-06 17:29:12 +04:00
|
|
|
#define APPLICATION_PKCS7_SIGNATURE "application/pkcs7-signature"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define APPLICATION_WWW_FORM_URLENCODED "application/x-www-form-urlencoded"
|
|
|
|
#define APPLICATION_OLEOBJECT "application/oleobject"
|
|
|
|
#define APPLICATION_OLEOBJECT2 "application/x-oleobject"
|
|
|
|
#define APPLICATION_JAVAARCHIVE "application/java-archive"
|
|
|
|
#define APPLICATION_MARIMBA "application/marimba"
|
2015-06-02 22:42:19 +03:00
|
|
|
#define APPLICATION_WEB_MANIFEST "application/manifest+json"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define APPLICATION_XMARIMBA "application/x-marimba"
|
2000-05-08 09:09:21 +04:00
|
|
|
#define APPLICATION_XPINSTALL "application/x-xpinstall"
|
2009-11-21 02:12:42 +03:00
|
|
|
#define APPLICATION_XML "application/xml"
|
|
|
|
#define APPLICATION_XHTML_XML "application/xhtml+xml"
|
2011-05-28 16:34:36 +04:00
|
|
|
#define APPLICATION_XSLT_XML "application/xslt+xml"
|
2009-11-30 01:18:53 +03:00
|
|
|
#define APPLICATION_MATHML_XML "application/mathml+xml"
|
2009-11-21 02:12:42 +03:00
|
|
|
#define APPLICATION_RDF_XML "application/rdf+xml"
|
2016-09-28 17:48:17 +03:00
|
|
|
#define APPLICATION_WAPXHTML_XML "application/vnd.wap.xhtml+xml"
|
2015-07-23 18:38:33 +03:00
|
|
|
#define APPLICATION_PACKAGE "application/package"
|
2000-02-09 06:59:58 +03:00
|
|
|
|
|
|
|
#define AUDIO_BASIC "audio/basic"
|
2009-01-16 12:07:26 +03:00
|
|
|
#define AUDIO_OGG "audio/ogg"
|
|
|
|
#define AUDIO_WAV "audio/x-wav"
|
2010-06-09 03:31:27 +04:00
|
|
|
#define AUDIO_WEBM "audio/webm"
|
2012-09-05 03:22:34 +04:00
|
|
|
#define AUDIO_MP3 "audio/mpeg"
|
2012-12-18 12:49:58 +04:00
|
|
|
#define AUDIO_MP4 "audio/mp4"
|
2013-03-22 06:56:22 +04:00
|
|
|
#define AUDIO_AMR "audio/amr"
|
2014-12-03 00:37:00 +03:00
|
|
|
#define AUDIO_FLAC "audio/flac"
|
2014-03-19 10:52:45 +04:00
|
|
|
#define AUDIO_3GPP "audio/3gpp"
|
2015-10-27 10:12:26 +03:00
|
|
|
#define AUDIO_3GPP2 "audio/3gpp2"
|
2014-02-05 19:09:08 +04:00
|
|
|
#define AUDIO_MIDI "audio/x-midi"
|
2014-12-23 05:20:25 +03:00
|
|
|
#define AUDIO_MATROSKA "audio/x-matroska"
|
2017-04-13 03:40:35 +03:00
|
|
|
#define AUDIO_AAC "audio/aac"
|
2000-02-09 06:59:58 +03:00
|
|
|
|
2012-04-12 02:38:43 +04:00
|
|
|
#define BINARY_OCTET_STREAM "binary/octet-stream"
|
|
|
|
|
2000-02-09 06:59:58 +03:00
|
|
|
#define IMAGE_GIF "image/gif"
|
2013-01-09 01:40:47 +04:00
|
|
|
#define IMAGE_JPEG "image/jpeg"
|
|
|
|
#define IMAGE_JPG "image/jpg"
|
|
|
|
#define IMAGE_PJPEG "image/pjpeg"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define IMAGE_PNG "image/png"
|
2016-08-09 23:15:00 +03:00
|
|
|
#define IMAGE_APNG "image/apng"
|
2013-01-09 01:40:47 +04:00
|
|
|
#define IMAGE_X_PNG "image/x-png"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define IMAGE_PPM "image/x-portable-pixmap"
|
|
|
|
#define IMAGE_XBM "image/x-xbitmap"
|
|
|
|
#define IMAGE_XBM2 "image/x-xbm"
|
|
|
|
#define IMAGE_XBM3 "image/xbm"
|
|
|
|
#define IMAGE_ART "image/x-jg"
|
|
|
|
#define IMAGE_TIFF "image/tiff"
|
2001-11-03 10:10:51 +03:00
|
|
|
#define IMAGE_BMP "image/bmp"
|
2013-01-09 01:40:47 +04:00
|
|
|
#define IMAGE_BMP_MS "image/x-ms-bmp"
|
2001-11-03 10:10:51 +03:00
|
|
|
#define IMAGE_ICO "image/x-icon"
|
2013-01-09 01:40:47 +04:00
|
|
|
#define IMAGE_ICO_MS "image/vnd.microsoft.icon"
|
|
|
|
#define IMAGE_ICON_MS "image/icon"
|
2001-12-18 01:07:03 +03:00
|
|
|
#define IMAGE_MNG "video/x-mng"
|
|
|
|
#define IMAGE_JNG "image/x-jng"
|
2009-11-21 02:12:42 +03:00
|
|
|
#define IMAGE_SVG_XML "image/svg+xml"
|
2000-02-09 06:59:58 +03:00
|
|
|
|
|
|
|
#define MESSAGE_EXTERNAL_BODY "message/external-body"
|
|
|
|
#define MESSAGE_NEWS "message/news"
|
|
|
|
#define MESSAGE_RFC822 "message/rfc822"
|
|
|
|
|
|
|
|
#define MULTIPART_ALTERNATIVE "multipart/alternative"
|
|
|
|
#define MULTIPART_APPLEDOUBLE "multipart/appledouble"
|
|
|
|
#define MULTIPART_DIGEST "multipart/digest"
|
2014-03-06 19:51:23 +04:00
|
|
|
#define MULTIPART_FORM_DATA "multipart/form-data"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define MULTIPART_HEADER_SET "multipart/header-set"
|
|
|
|
#define MULTIPART_MIXED "multipart/mixed"
|
|
|
|
#define MULTIPART_PARALLEL "multipart/parallel"
|
|
|
|
#define MULTIPART_SIGNED "multipart/signed"
|
|
|
|
#define MULTIPART_RELATED "multipart/related"
|
2001-06-05 02:59:22 +04:00
|
|
|
#define MULTIPART_MIXED_REPLACE "multipart/x-mixed-replace"
|
|
|
|
#define MULTIPART_BYTERANGES "multipart/byteranges"
|
|
|
|
|
2000-02-09 06:59:58 +03:00
|
|
|
#define SUN_ATTACHMENT "x-sun-attachment"
|
|
|
|
|
|
|
|
#define TEXT_ENRICHED "text/enriched"
|
|
|
|
#define TEXT_CALENDAR "text/calendar"
|
|
|
|
#define TEXT_HTML "text/html"
|
|
|
|
#define TEXT_MDL "text/mdl"
|
|
|
|
#define TEXT_PLAIN "text/plain"
|
|
|
|
#define TEXT_RICHTEXT "text/richtext"
|
2013-09-26 10:25:50 +04:00
|
|
|
#define TEXT_VCARD "text/vcard"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define TEXT_CSS "text/css"
|
|
|
|
#define TEXT_JSSS "text/jsss"
|
2015-10-05 19:23:26 +03:00
|
|
|
#define TEXT_JSON "text/json"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define TEXT_XML "text/xml"
|
|
|
|
#define TEXT_RDF "text/rdf"
|
2015-10-05 19:23:26 +03:00
|
|
|
#define TEXT_VTT "text/vtt"
|
2001-03-25 20:49:38 +04:00
|
|
|
#define TEXT_XUL "application/vnd.mozilla.xul+xml"
|
2009-11-21 02:12:42 +03:00
|
|
|
#define TEXT_ECMASCRIPT "text/ecmascript"
|
|
|
|
#define TEXT_JAVASCRIPT "text/javascript"
|
|
|
|
#define TEXT_XSL "text/xsl"
|
2011-05-23 01:30:07 +04:00
|
|
|
#define TEXT_EVENT_STREAM "text/event-stream"
|
2012-07-14 10:13:20 +04:00
|
|
|
#define TEXT_CACHE_MANIFEST "text/cache-manifest"
|
2000-02-09 06:59:58 +03:00
|
|
|
|
|
|
|
#define VIDEO_MPEG "video/mpeg"
|
2012-05-18 04:20:15 +04:00
|
|
|
#define VIDEO_MP4 "video/mp4"
|
2016-03-11 14:32:30 +03:00
|
|
|
#define VIDEO_QUICKTIME "video/quicktime"
|
2010-07-26 23:35:16 +04:00
|
|
|
#define VIDEO_RAW "video/x-raw-yuv"
|
2009-01-16 12:07:26 +03:00
|
|
|
#define VIDEO_OGG "video/ogg"
|
2010-06-09 03:31:27 +04:00
|
|
|
#define VIDEO_WEBM "video/webm"
|
2012-10-10 05:11:10 +04:00
|
|
|
#define VIDEO_3GPP "video/3gpp"
|
2014-06-06 01:22:15 +04:00
|
|
|
#define VIDEO_3GPP2 "video/3gpp2"
|
2014-12-23 05:20:25 +03:00
|
|
|
#define VIDEO_MPEG_TS "video/mp2t"
|
|
|
|
#define VIDEO_AVI "video/avi"
|
|
|
|
#define VIDEO_MATROSKA "video/x-matroska"
|
2009-01-16 12:07:26 +03:00
|
|
|
#define APPLICATION_OGG "application/ogg"
|
2000-02-09 06:59:58 +03:00
|
|
|
|
|
|
|
/* x-uuencode-apple-single. QuickMail made me do this. */
|
|
|
|
#define UUENCODE_APPLE_SINGLE "x-uuencode-apple-single"
|
|
|
|
|
|
|
|
/* The standard MIME message-content-encoding values:
|
|
|
|
*/
|
|
|
|
#define ENCODING_7BIT "7bit"
|
|
|
|
#define ENCODING_8BIT "8bit"
|
|
|
|
#define ENCODING_BINARY "binary"
|
|
|
|
#define ENCODING_BASE64 "base64"
|
|
|
|
#define ENCODING_QUOTED_PRINTABLE "quoted-printable"
|
|
|
|
|
|
|
|
/* Some nonstandard encodings. Note that the names are TOTALLY RANDOM,
|
|
|
|
and code that looks for these in network-provided data must look for
|
|
|
|
all the possibilities.
|
|
|
|
*/
|
|
|
|
#define ENCODING_COMPRESS "x-compress"
|
|
|
|
#define ENCODING_COMPRESS2 "compress"
|
|
|
|
#define ENCODING_ZLIB "x-zlib"
|
|
|
|
#define ENCODING_ZLIB2 "zlib"
|
|
|
|
#define ENCODING_GZIP "x-gzip"
|
|
|
|
#define ENCODING_GZIP2 "gzip"
|
|
|
|
#define ENCODING_DEFLATE "x-deflate"
|
|
|
|
#define ENCODING_DEFLATE2 "deflate"
|
|
|
|
#define ENCODING_UUENCODE "x-uuencode"
|
|
|
|
#define ENCODING_UUENCODE2 "x-uue"
|
|
|
|
#define ENCODING_UUENCODE3 "uuencode"
|
|
|
|
#define ENCODING_UUENCODE4 "uue"
|
2003-04-10 06:19:35 +04:00
|
|
|
#define ENCODING_YENCODE "x-yencode"
|
2000-02-09 06:59:58 +03:00
|
|
|
|
|
|
|
/* Some names of parameters that various MIME headers include.
|
|
|
|
*/
|
|
|
|
#define PARAM_PROTOCOL "protocol"
|
|
|
|
#define PARAM_MICALG "micalg"
|
|
|
|
#define PARAM_MICALG_MD2 "rsa-md2"
|
|
|
|
#define PARAM_MICALG_MD5 "rsa-md5"
|
2002-10-22 18:48:14 +04:00
|
|
|
#define PARAM_MICALG_MD5_2 "md5"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define PARAM_MICALG_SHA1 "sha1"
|
|
|
|
#define PARAM_MICALG_SHA1_2 "sha-1"
|
|
|
|
#define PARAM_MICALG_SHA1_3 "rsa-sha1"
|
|
|
|
#define PARAM_MICALG_SHA1_4 "rsa-sha-1"
|
|
|
|
#define PARAM_MICALG_SHA1_5 "rsa-sha"
|
2010-02-23 08:06:29 +03:00
|
|
|
#define PARAM_MICALG_SHA256 "sha-256"
|
|
|
|
#define PARAM_MICALG_SHA256_2 "sha256"
|
|
|
|
#define PARAM_MICALG_SHA256_3 "2.16.840.1.101.3.4.2.1"
|
|
|
|
#define PARAM_MICALG_SHA384 "sha-384"
|
|
|
|
#define PARAM_MICALG_SHA384_2 "sha384"
|
|
|
|
#define PARAM_MICALG_SHA384_3 "2.16.840.1.101.3.4.2.2"
|
|
|
|
#define PARAM_MICALG_SHA512 "sha-512"
|
|
|
|
#define PARAM_MICALG_SHA512_2 "sha512"
|
|
|
|
#define PARAM_MICALG_SHA512_3 "2.16.840.1.101.3.4.2.3"
|
2000-02-09 06:59:58 +03:00
|
|
|
#define PARAM_X_MAC_CREATOR "x-mac-creator"
|
|
|
|
#define PARAM_X_MAC_TYPE "x-mac-type"
|
|
|
|
#define PARAM_FORMAT "format"
|
|
|
|
|
|
|
|
#define UNKNOWN_CONTENT_TYPE "application/x-unknown-content-type"
|
2004-01-08 06:56:02 +03:00
|
|
|
#define APPLICATION_GUESS_FROM_EXT "application/x-vnd.mozilla.guess-from-ext"
|
2002-09-04 02:10:08 +04:00
|
|
|
#define VIEWSOURCE_CONTENT_TYPE "application/x-view-source"
|
|
|
|
|
2000-02-09 06:59:58 +03:00
|
|
|
#define APPLICATION_DIRECTORY "application/directory" /* text/x-vcard is synonym */
|
2009-11-21 02:12:42 +03:00
|
|
|
#define APPLICATION_CACHED_XUL "mozilla.application/cached-xul"
|
2000-02-09 06:59:58 +03:00
|
|
|
|
|
|
|
#endif /* nsMimeTypes_h_ */
|