epitools 0.4.47 → 0.4.48

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.4.47
1
+ 0.4.48
@@ -5,11 +5,11 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{epitools}
8
- s.version = "0.4.47"
8
+ s.version = "0.4.48"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["epitron"]
12
- s.date = %q{2011-06-25}
12
+ s.date = %q{2011-06-29}
13
13
  s.description = %q{Miscellaneous utility libraries to make my life easier.}
14
14
  s.email = %q{chris@ill-logic.com}
15
15
  s.extra_rdoc_files = [
@@ -34,6 +34,8 @@ Gem::Specification.new do |s|
34
34
  "lib/epitools/hexdump.rb",
35
35
  "lib/epitools/its.rb",
36
36
  "lib/epitools/lcs.rb",
37
+ "lib/epitools/mimemagic.rb",
38
+ "lib/epitools/mimemagic_tables.rb",
37
39
  "lib/epitools/niceprint.rb",
38
40
  "lib/epitools/numwords.rb",
39
41
  "lib/epitools/path.rb",
@@ -18,13 +18,11 @@ module Digest
18
18
  end
19
19
 
20
20
  ## Nonstandard library
21
- autoload :Path, 'epitools/path'
22
- autoload :Browser, 'epitools/browser'
23
- autoload :Rash, 'epitools/rash'
24
- autoload :Ratio, 'epitools/ratio'
25
- autoload :Sys, 'epitools/sys'
21
+ autoload :MimeMagic, 'epitools/mimemagic'
22
+ autoload :Path, 'epitools/path'
23
+ autoload :Browser, 'epitools/browser'
24
+ autoload :Rash, 'epitools/rash'
25
+ autoload :Ratio, 'epitools/ratio'
26
+ autoload :Sys, 'epitools/sys'
26
27
  autoload :ProgressBar, 'epitools/progressbar'
27
28
 
28
- ## Gems
29
- autoreq :MimeMagic, 'mimemagic'
30
-
@@ -0,0 +1,147 @@
1
+ #
2
+ # MimeMagic is a library to detect the mime type of a file by extension or by content.
3
+ #
4
+ # Usage
5
+ # =====
6
+ #
7
+ # require 'mimemagic'
8
+ # MimeMagic.by_extension('html').text?
9
+ # MimeMagic.by_extension('.html').child_of? 'text/plain'
10
+ # MimeMagic.by_path('filename.txt')
11
+ # MimeMagic.by_magic(File.open('test.html'))
12
+ # etc...
13
+ #
14
+ # Authors
15
+ # =======
16
+ # Daniel Mendler
17
+ #
18
+ require 'epitools/mimemagic_tables'
19
+ require 'stringio'
20
+
21
+ # Mime type detection
22
+ class MimeMagic
23
+ VERSION = '0.1.8b'
24
+
25
+ attr_reader :type, :mediatype, :subtype
26
+
27
+ # Mime type by type string
28
+ def initialize(type)
29
+ @type = type
30
+ @mediatype, @subtype = type.split('/', 2)
31
+ end
32
+
33
+ # Add custom mime type. Arguments:
34
+ # * <i>type</i>: Mime type
35
+ # * <i>options</i>: Options hash
36
+ #
37
+ # Option keys:
38
+ # * <i>:extensions</i>: String list or single string of file extensions
39
+ # * <i>:parents</i>: String list or single string of parent mime types
40
+ # * <i>:magic</i>: Mime magic specification
41
+ # * <i>:comment</i>: Comment string
42
+ def self.add(type, options)
43
+ extensions = [options[:extensions]].flatten.compact
44
+ TYPES[type] = [extensions,
45
+ [options[:parents]].flatten.compact,
46
+ options[:comment]]
47
+ extensions.each {|ext| EXTENSIONS[ext] = type }
48
+ MAGIC.unshift [type, options[:magic]] if options[:magic]
49
+ end
50
+
51
+ # Removes a mime type from the dictionary. You might want to do this if
52
+ # you're seeing impossible conflicts (for instance, application/x-gmc-link).
53
+ # * <i>type</i>: The mime type to remove. All associated extensions and magic are removed too.
54
+ def self.remove(type)
55
+ EXTENSIONS.delete_if {|ext, t| t == type }
56
+ MAGIC.delete_if {|t, m| t == type }
57
+ TYPES.delete(type)
58
+ end
59
+
60
+ # Returns true if type is a text format
61
+ def text?; mediatype == 'text' || child_of?('text/plain'); end
62
+
63
+ # Mediatype shortcuts
64
+ def image?; mediatype == 'image'; end
65
+ def audio?; mediatype == 'audio'; end
66
+ def video?; mediatype == 'video'; end
67
+
68
+ # Returns true if type is child of parent type
69
+ def child_of?(parent)
70
+ MimeMagic.child?(type, parent)
71
+ end
72
+
73
+ # Get string list of file extensions
74
+ def extensions
75
+ TYPES.key?(type) ? TYPES[type][0] : []
76
+ end
77
+
78
+ # Get mime comment
79
+ def comment
80
+ (TYPES.key?(type) ? TYPES[type][2] : nil).to_s
81
+ end
82
+
83
+ # Lookup mime type by file extension
84
+ def self.by_extension(ext)
85
+ ext = ext.to_s.downcase
86
+ mime = ext[0..0] == '.' ? EXTENSIONS[ext[1..-1]] : EXTENSIONS[ext]
87
+ mime && new(mime)
88
+ end
89
+
90
+ # Lookup mime type by filename
91
+ def self.by_path(path)
92
+ by_extension(File.extname(path))
93
+ end
94
+
95
+ # Lookup mime type by magic content analysis.
96
+ # This is a slow operation.
97
+ def self.by_magic(io)
98
+ if !(io.respond_to?(:seek) && io.respond_to?(:read))
99
+ io = StringIO.new(io.to_s, 'rb:binary')
100
+ end
101
+ mime = MAGIC.find {|type, matches| magic_match(io, matches) }
102
+ mime && new(mime[0])
103
+ end
104
+
105
+ # Return type as string
106
+ def to_s
107
+ type
108
+ end
109
+
110
+ # Allow comparison with string
111
+ def ==(x)
112
+ type == x.to_s
113
+ end
114
+
115
+ # allow comparison with hashes
116
+ def hash
117
+ type.hash
118
+ end
119
+
120
+ # allow comparison with something else
121
+ def eql?(other)
122
+ self.type == other.type
123
+ end
124
+
125
+ private
126
+
127
+ def self.child?(child, parent)
128
+ child == parent || TYPES.key?(child) && TYPES[child][1].any? {|p| child?(p, parent) }
129
+ end
130
+
131
+ def self.magic_match(io, matches)
132
+ matches.any? do |offset, value, children|
133
+ match = if Range === offset
134
+ io.seek(offset.begin)
135
+ io.read(offset.end - offset.begin + value.length).include?(value)
136
+ else
137
+ io.seek(offset)
138
+ value == io.read(value.length)
139
+ end
140
+ match && (!children || magic_match(io, children))
141
+ end
142
+ rescue
143
+ false
144
+ end
145
+
146
+ private_class_method :magic_match
147
+ end
@@ -0,0 +1,1614 @@
1
+ # Generated from freedesktop.org.xml
2
+ class MimeMagic
3
+ private
4
+ EXTENSIONS = {
5
+ '123' => 'application/vnd.lotus-1-2-3',
6
+ '3ds' => 'image/x-3ds',
7
+ '3g2' => 'video/3gpp2',
8
+ '3ga' => 'video/3gpp',
9
+ '3gp' => 'video/3gpp',
10
+ '3gp2' => 'video/3gpp2',
11
+ '3gpp' => 'video/3gpp',
12
+ '3gpp2' => 'video/3gpp2',
13
+ '602' => 'application/x-t602',
14
+ '669' => 'audio/x-mod',
15
+ '7z' => 'application/x-7z-compressed',
16
+ 'a' => 'application/x-archive',
17
+ 'aac' => 'audio/mp4',
18
+ 'abw' => 'application/x-abiword',
19
+ 'abw.crashed' => 'application/x-abiword',
20
+ 'abw.gz' => 'application/x-abiword',
21
+ 'ac3' => 'audio/ac3',
22
+ 'ace' => 'application/x-ace',
23
+ 'adb' => 'text/x-adasrc',
24
+ 'ads' => 'text/x-adasrc',
25
+ 'afm' => 'application/x-font-afm',
26
+ 'ag' => 'image/x-applix-graphics',
27
+ 'ai' => 'application/illustrator',
28
+ 'aif' => 'audio/x-aiff',
29
+ 'aifc' => 'audio/x-aiff',
30
+ 'aiff' => 'audio/x-aiff',
31
+ 'al' => 'application/x-perl',
32
+ 'alz' => 'application/x-alz',
33
+ 'amr' => 'audio/AMR',
34
+ 'ani' => 'application/x-navi-animation',
35
+ 'anx' => 'application/annodex',
36
+ 'ape' => 'audio/x-ape',
37
+ 'arj' => 'application/x-arj',
38
+ 'arw' => 'image/x-sony-arw',
39
+ 'as' => 'application/x-applix-spreadsheet',
40
+ 'asc' => 'application/pgp-encrypted',
41
+ 'asf' => 'video/x-ms-asf',
42
+ 'asp' => 'application/x-asp',
43
+ 'ass' => 'text/x-ssa',
44
+ 'asx' => 'audio/x-ms-asx',
45
+ 'atom' => 'application/atom+xml',
46
+ 'au' => 'audio/basic',
47
+ 'avi' => 'video/x-msvideo',
48
+ 'aw' => 'application/x-applix-word',
49
+ 'awb' => 'audio/AMR-WB',
50
+ 'awk' => 'application/x-awk',
51
+ 'axa' => 'audio/annodex',
52
+ 'axv' => 'video/annodex',
53
+ 'bak' => 'application/x-trash',
54
+ 'bcpio' => 'application/x-bcpio',
55
+ 'bdf' => 'application/x-font-bdf',
56
+ 'bdm' => 'video/mp2t',
57
+ 'bdmv' => 'video/mp2t',
58
+ 'bib' => 'text/x-bibtex',
59
+ 'bin' => 'application/octet-stream',
60
+ 'blend' => 'application/x-blender',
61
+ 'blender' => 'application/x-blender',
62
+ 'bmp' => 'image/bmp',
63
+ 'bz' => 'application/x-bzip',
64
+ 'bz2' => 'application/x-bzip',
65
+ 'c' => 'text/x-c++src',
66
+ 'c++' => 'text/x-c++src',
67
+ 'cab' => 'application/vnd.ms-cab-compressed',
68
+ 'cb7' => 'application/x-cb7',
69
+ 'cbl' => 'text/x-cobol',
70
+ 'cbr' => 'application/x-cbr',
71
+ 'cbt' => 'application/x-cbt',
72
+ 'cbz' => 'application/x-cbz',
73
+ 'cc' => 'text/x-c++src',
74
+ 'cdf' => 'application/x-netcdf',
75
+ 'cdr' => 'application/vnd.corel-draw',
76
+ 'cer' => 'application/pkix-cert',
77
+ 'cert' => 'application/x-x509-ca-cert',
78
+ 'cgm' => 'image/cgm',
79
+ 'chm' => 'application/x-chm',
80
+ 'chrt' => 'application/x-kchart',
81
+ 'class' => 'application/x-java',
82
+ 'clpi' => 'video/mp2t',
83
+ 'cls' => 'text/x-tex',
84
+ 'cmake' => 'text/x-cmake',
85
+ 'cob' => 'text/x-cobol',
86
+ 'cpi' => 'video/mp2t',
87
+ 'cpio' => 'application/x-cpio',
88
+ 'cpio.gz' => 'application/x-cpio-compressed',
89
+ 'cpp' => 'text/x-c++src',
90
+ 'cr2' => 'image/x-canon-cr2',
91
+ 'crl' => 'application/pkix-crl',
92
+ 'crt' => 'application/x-x509-ca-cert',
93
+ 'crw' => 'image/x-canon-crw',
94
+ 'cs' => 'text/x-csharp',
95
+ 'csh' => 'application/x-csh',
96
+ 'css' => 'text/css',
97
+ 'cssl' => 'text/css',
98
+ 'csv' => 'text/csv',
99
+ 'cue' => 'application/x-cue',
100
+ 'cur' => 'image/x-win-bitmap',
101
+ 'cxx' => 'text/x-c++src',
102
+ 'd' => 'text/x-dsrc',
103
+ 'dar' => 'application/x-dar',
104
+ 'dbf' => 'application/x-dbf',
105
+ 'dc' => 'application/x-dc-rom',
106
+ 'dcl' => 'text/x-dcl',
107
+ 'dcm' => 'application/dicom',
108
+ 'dcr' => 'image/x-kodak-dcr',
109
+ 'dds' => 'image/x-dds',
110
+ 'deb' => 'application/x-deb',
111
+ 'der' => 'application/x-x509-ca-cert',
112
+ 'desktop' => 'application/x-desktop',
113
+ 'dia' => 'application/x-dia-diagram',
114
+ 'diff' => 'text/x-patch',
115
+ 'divx' => 'video/x-msvideo',
116
+ 'djv' => 'image/vnd.djvu',
117
+ 'djvu' => 'image/vnd.djvu',
118
+ 'dmg' => 'application/x-apple-diskimage',
119
+ 'dng' => 'image/x-adobe-dng',
120
+ 'doc' => 'application/msword',
121
+ 'docbook' => 'application/docbook+xml',
122
+ 'docm' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
123
+ 'docx' => 'application/vnd.openxmlformats-officedocument.wordprocessingml.document',
124
+ 'dot' => 'application/msword-template',
125
+ 'dsl' => 'text/x-dsl',
126
+ 'dtd' => 'application/xml-dtd',
127
+ 'dtx' => 'text/x-tex',
128
+ 'dv' => 'video/dv',
129
+ 'dvi' => 'application/x-dvi',
130
+ 'dvi.bz2' => 'application/x-bzdvi',
131
+ 'dvi.gz' => 'application/x-gzdvi',
132
+ 'dwg' => 'image/vnd.dwg',
133
+ 'dxf' => 'image/vnd.dxf',
134
+ 'e' => 'text/x-eiffel',
135
+ 'egon' => 'application/x-egon',
136
+ 'eif' => 'text/x-eiffel',
137
+ 'el' => 'text/x-emacs-lisp',
138
+ 'emf' => 'image/x-emf',
139
+ 'eml' => 'message/rfc822',
140
+ 'emp' => 'application/vnd.emusic-emusic_package',
141
+ 'ent' => 'application/xml-external-parsed-entity',
142
+ 'eps' => 'image/x-eps',
143
+ 'eps.bz2' => 'image/x-bzeps',
144
+ 'eps.gz' => 'image/x-gzeps',
145
+ 'epsf' => 'image/x-eps',
146
+ 'epsf.bz2' => 'image/x-bzeps',
147
+ 'epsf.gz' => 'image/x-gzeps',
148
+ 'epsi' => 'image/x-eps',
149
+ 'epsi.bz2' => 'image/x-bzeps',
150
+ 'epsi.gz' => 'image/x-gzeps',
151
+ 'epub' => 'application/epub+zip',
152
+ 'erl' => 'text/x-erlang',
153
+ 'es' => 'application/ecmascript',
154
+ 'etheme' => 'application/x-e-theme',
155
+ 'etx' => 'text/x-setext',
156
+ 'exe' => 'application/x-ms-dos-executable',
157
+ 'exr' => 'image/x-exr',
158
+ 'ez' => 'application/andrew-inset',
159
+ 'f' => 'text/x-fortran',
160
+ 'f4a' => 'audio/mp4',
161
+ 'f4b' => 'audio/x-m4b',
162
+ 'f4v' => 'video/mp4',
163
+ 'f90' => 'text/x-fortran',
164
+ 'f95' => 'text/x-fortran',
165
+ 'fb2' => 'application/x-fictionbook+xml',
166
+ 'fig' => 'image/x-xfig',
167
+ 'fits' => 'image/fits',
168
+ 'fl' => 'application/x-fluid',
169
+ 'flac' => 'audio/flac',
170
+ 'flc' => 'video/x-flic',
171
+ 'fli' => 'video/x-flic',
172
+ 'flv' => 'video/x-flv',
173
+ 'flw' => 'application/x-kivio',
174
+ 'fo' => 'text/x-xslfo',
175
+ 'fodg' => 'application/vnd.oasis.opendocument.graphics-flat-xml',
176
+ 'fodp' => 'application/vnd.oasis.opendocument.presentation-flat-xml',
177
+ 'fods' => 'application/vnd.oasis.opendocument.spreadsheet-flat-xml',
178
+ 'fodt' => 'application/vnd.oasis.opendocument.text-flat-xml',
179
+ 'for' => 'text/x-fortran',
180
+ 'fxm' => 'video/x-javafx',
181
+ 'g3' => 'image/fax-g3',
182
+ 'gb' => 'application/x-gameboy-rom',
183
+ 'gba' => 'application/x-gba-rom',
184
+ 'gcrd' => 'text/directory',
185
+ 'ged' => 'application/x-gedcom',
186
+ 'gedcom' => 'application/x-gedcom',
187
+ 'gem' => 'application/x-tar',
188
+ 'gen' => 'application/x-genesis-rom',
189
+ 'gf' => 'application/x-tex-gf',
190
+ 'gg' => 'application/x-sms-rom',
191
+ 'gif' => 'image/gif',
192
+ 'glade' => 'application/x-glade',
193
+ 'gmo' => 'application/x-gettext-translation',
194
+ 'gnc' => 'application/x-gnucash',
195
+ 'gnd' => 'application/gnunet-directory',
196
+ 'gnucash' => 'application/x-gnucash',
197
+ 'gnumeric' => 'application/x-gnumeric',
198
+ 'gnuplot' => 'application/x-gnuplot',
199
+ 'go' => 'text/x-go',
200
+ 'gp' => 'application/x-gnuplot',
201
+ 'gpg' => 'application/pgp-encrypted',
202
+ 'gplt' => 'application/x-gnuplot',
203
+ 'gra' => 'application/x-graphite',
204
+ 'gsf' => 'application/x-font-type1',
205
+ 'gsm' => 'audio/x-gsm',
206
+ 'gtar' => 'application/x-tar',
207
+ 'gv' => 'text/vnd.graphviz',
208
+ 'gvp' => 'text/x-google-video-pointer',
209
+ 'gz' => 'application/x-gzip',
210
+ 'h' => 'text/x-chdr',
211
+ 'h++' => 'text/x-c++hdr',
212
+ 'h4' => 'application/x-hdf',
213
+ 'h5' => 'application/x-hdf',
214
+ 'hdf' => 'application/x-hdf',
215
+ 'hdf4' => 'application/x-hdf',
216
+ 'hdf5' => 'application/x-hdf',
217
+ 'hh' => 'text/x-c++hdr',
218
+ 'hp' => 'text/x-c++hdr',
219
+ 'hpgl' => 'application/vnd.hp-hpgl',
220
+ 'hpp' => 'text/x-c++hdr',
221
+ 'hs' => 'text/x-haskell',
222
+ 'htm' => 'text/html',
223
+ 'html' => 'text/html',
224
+ 'hwp' => 'application/x-hwp',
225
+ 'hwt' => 'application/x-hwt',
226
+ 'hxx' => 'text/x-c++hdr',
227
+ 'ica' => 'application/x-ica',
228
+ 'icb' => 'image/x-tga',
229
+ 'icc' => 'application/vnd.iccprofile',
230
+ 'icm' => 'application/vnd.iccprofile',
231
+ 'icns' => 'image/x-icns',
232
+ 'ico' => 'image/vnd.microsoft.icon',
233
+ 'ics' => 'text/calendar',
234
+ 'idl' => 'text/x-idl',
235
+ 'ief' => 'image/ief',
236
+ 'iff' => 'image/x-iff',
237
+ 'ilbm' => 'image/x-ilbm',
238
+ 'ime' => 'text/x-iMelody',
239
+ 'imy' => 'text/x-iMelody',
240
+ 'ins' => 'text/x-tex',
241
+ 'iptables' => 'text/x-iptables',
242
+ 'iso' => 'application/x-cd-image',
243
+ 'iso9660' => 'application/x-cd-image',
244
+ 'it' => 'audio/x-it',
245
+ 'it87' => 'application/x-it87',
246
+ 'j2k' => 'image/jp2',
247
+ 'jad' => 'text/vnd.sun.j2me.app-descriptor',
248
+ 'jar' => 'application/x-java-archive',
249
+ 'java' => 'text/x-java',
250
+ 'jceks' => 'application/x-java-jce-keystore',
251
+ 'jks' => 'application/x-java-keystore',
252
+ 'jng' => 'image/x-jng',
253
+ 'jnlp' => 'application/x-java-jnlp-file',
254
+ 'jp2' => 'image/jp2',
255
+ 'jpc' => 'image/jp2',
256
+ 'jpe' => 'image/jpeg',
257
+ 'jpeg' => 'image/jpeg',
258
+ 'jpf' => 'image/jp2',
259
+ 'jpg' => 'image/jpeg',
260
+ 'jpr' => 'application/x-jbuilder-project',
261
+ 'jpx' => 'application/x-jbuilder-project',
262
+ 'js' => 'application/javascript',
263
+ 'k25' => 'image/x-kodak-k25',
264
+ 'kar' => 'audio/midi',
265
+ 'karbon' => 'application/x-karbon',
266
+ 'kdc' => 'image/x-kodak-kdc',
267
+ 'kdelnk' => 'application/x-desktop',
268
+ 'kexi' => 'application/x-kexiproject-sqlite2',
269
+ 'kexic' => 'application/x-kexi-connectiondata',
270
+ 'kexis' => 'application/x-kexiproject-shortcut',
271
+ 'kfo' => 'application/x-kformula',
272
+ 'kil' => 'application/x-killustrator',
273
+ 'kino' => 'application/smil',
274
+ 'kml' => 'application/vnd.google-earth.kml+xml',
275
+ 'kmz' => 'application/vnd.google-earth.kmz',
276
+ 'kon' => 'application/x-kontour',
277
+ 'kpm' => 'application/x-kpovmodeler',
278
+ 'kpr' => 'application/x-kpresenter',
279
+ 'kpt' => 'application/x-kpresenter',
280
+ 'kra' => 'application/x-krita',
281
+ 'ks' => 'application/x-java-keystore',
282
+ 'ksp' => 'application/x-kspread',
283
+ 'kud' => 'application/x-kugar',
284
+ 'kwd' => 'application/x-kword',
285
+ 'kwt' => 'application/x-kword',
286
+ 'la' => 'application/x-shared-library-la',
287
+ 'latex' => 'text/x-tex',
288
+ 'ldif' => 'text/x-ldif',
289
+ 'lha' => 'application/x-lha',
290
+ 'lhs' => 'text/x-literate-haskell',
291
+ 'lhz' => 'application/x-lhz',
292
+ 'log' => 'text/x-log',
293
+ 'lrz' => 'application/x-lrzip',
294
+ 'ltx' => 'text/x-tex',
295
+ 'lua' => 'text/x-lua',
296
+ 'lwo' => 'image/x-lwo',
297
+ 'lwob' => 'image/x-lwo',
298
+ 'lws' => 'image/x-lws',
299
+ 'ly' => 'text/x-lilypond',
300
+ 'lyx' => 'application/x-lyx',
301
+ 'lz' => 'application/x-lzip',
302
+ 'lzh' => 'application/x-lha',
303
+ 'lzma' => 'application/x-lzma',
304
+ 'lzo' => 'application/x-lzop',
305
+ 'm' => 'text/x-objcsrc',
306
+ 'm15' => 'audio/x-mod',
307
+ 'm2t' => 'video/mp2t',
308
+ 'm2ts' => 'video/mp2t',
309
+ 'm3u' => 'audio/x-mpegurl',
310
+ 'm3u8' => 'audio/x-mpegurl',
311
+ 'm4' => 'application/x-m4',
312
+ 'm4a' => 'audio/mp4',
313
+ 'm4b' => 'audio/x-m4b',
314
+ 'm4v' => 'video/mp4',
315
+ 'mab' => 'application/x-markaby',
316
+ 'man' => 'application/x-troff-man',
317
+ 'manifest' => 'text/cache-manifest',
318
+ 'mbox' => 'application/mbox',
319
+ 'md' => 'application/x-genesis-rom',
320
+ 'mdb' => 'application/vnd.ms-access',
321
+ 'mdi' => 'image/vnd.ms-modi',
322
+ 'me' => 'text/x-troff-me',
323
+ 'med' => 'audio/x-mod',
324
+ 'metalink' => 'application/metalink+xml',
325
+ 'mgp' => 'application/x-magicpoint',
326
+ 'mid' => 'audio/midi',
327
+ 'midi' => 'audio/midi',
328
+ 'mif' => 'application/x-mif',
329
+ 'minipsf' => 'audio/x-minipsf',
330
+ 'mka' => 'audio/x-matroska',
331
+ 'mkv' => 'video/x-matroska',
332
+ 'ml' => 'text/x-ocaml',
333
+ 'mli' => 'text/x-ocaml',
334
+ 'mm' => 'text/x-troff-mm',
335
+ 'mmf' => 'application/x-smaf',
336
+ 'mml' => 'application/mathml+xml',
337
+ 'mng' => 'video/x-mng',
338
+ 'mo' => 'application/x-gettext-translation',
339
+ 'mo3' => 'audio/x-mo3',
340
+ 'moc' => 'text/x-moc',
341
+ 'mod' => 'audio/x-mod',
342
+ 'mof' => 'text/x-mof',
343
+ 'moov' => 'video/quicktime',
344
+ 'mov' => 'video/quicktime',
345
+ 'movie' => 'video/x-sgi-movie',
346
+ 'mp+' => 'audio/x-musepack',
347
+ 'mp2' => 'audio/mp2',
348
+ 'mp3' => 'audio/mpeg',
349
+ 'mp4' => 'video/mp4',
350
+ 'mpc' => 'audio/x-musepack',
351
+ 'mpe' => 'video/mpeg',
352
+ 'mpeg' => 'video/mpeg',
353
+ 'mpg' => 'video/mpeg',
354
+ 'mpga' => 'audio/mpeg',
355
+ 'mpl' => 'video/mp2t',
356
+ 'mpls' => 'video/mp2t',
357
+ 'mpp' => 'audio/x-musepack',
358
+ 'mrl' => 'text/x-mrml',
359
+ 'mrml' => 'text/x-mrml',
360
+ 'mrw' => 'image/x-minolta-mrw',
361
+ 'ms' => 'text/x-troff-ms',
362
+ 'msi' => 'application/x-msi',
363
+ 'msod' => 'image/x-msod',
364
+ 'msx' => 'application/x-msx-rom',
365
+ 'mtm' => 'audio/x-mod',
366
+ 'mts' => 'video/mp2t',
367
+ 'mup' => 'text/x-mup',
368
+ 'mxf' => 'application/mxf',
369
+ 'n64' => 'application/x-n64-rom',
370
+ 'nb' => 'application/mathematica',
371
+ 'nc' => 'application/x-netcdf',
372
+ 'nds' => 'application/x-nintendo-ds-rom',
373
+ 'nef' => 'image/x-nikon-nef',
374
+ 'nes' => 'application/x-nes-rom',
375
+ 'nfo' => 'text/x-nfo',
376
+ 'not' => 'text/x-mup',
377
+ 'nsc' => 'application/x-netshow-channel',
378
+ 'nsv' => 'video/x-nsv',
379
+ 'o' => 'application/x-object',
380
+ 'obj' => 'application/x-tgif',
381
+ 'ocl' => 'text/x-ocl',
382
+ 'oda' => 'application/oda',
383
+ 'odb' => 'application/vnd.oasis.opendocument.database',
384
+ 'odc' => 'application/vnd.oasis.opendocument.chart',
385
+ 'odf' => 'application/vnd.oasis.opendocument.formula',
386
+ 'odg' => 'application/vnd.oasis.opendocument.graphics',
387
+ 'odi' => 'application/vnd.oasis.opendocument.image',
388
+ 'odm' => 'application/vnd.oasis.opendocument.text-master',
389
+ 'odp' => 'application/vnd.oasis.opendocument.presentation',
390
+ 'ods' => 'application/vnd.oasis.opendocument.spreadsheet',
391
+ 'odt' => 'application/vnd.oasis.opendocument.text',
392
+ 'oga' => 'audio/ogg',
393
+ 'ogg' => 'audio/ogg',
394
+ 'ogm' => 'video/x-ogm+ogg',
395
+ 'ogv' => 'video/ogg',
396
+ 'ogx' => 'application/ogg',
397
+ 'old' => 'application/x-trash',
398
+ 'oleo' => 'application/x-oleo',
399
+ 'ooc' => 'text/x-ooc',
400
+ 'opml' => 'text/x-opml+xml',
401
+ 'ora' => 'image/openraster',
402
+ 'orf' => 'image/x-olympus-orf',
403
+ 'otc' => 'application/vnd.oasis.opendocument.chart-template',
404
+ 'otf' => 'application/vnd.oasis.opendocument.formula-template',
405
+ 'otg' => 'application/vnd.oasis.opendocument.graphics-template',
406
+ 'oth' => 'application/vnd.oasis.opendocument.text-web',
407
+ 'otp' => 'application/vnd.oasis.opendocument.presentation-template',
408
+ 'ots' => 'application/vnd.oasis.opendocument.spreadsheet-template',
409
+ 'ott' => 'application/vnd.oasis.opendocument.text-template',
410
+ 'owl' => 'application/rdf+xml',
411
+ 'oxps' => 'application/oxps',
412
+ 'oxt' => 'application/vnd.openofficeorg.extension',
413
+ 'p' => 'text/x-pascal',
414
+ 'p10' => 'application/pkcs10',
415
+ 'p12' => 'application/x-pkcs12',
416
+ 'p7b' => 'application/x-pkcs7-certificates',
417
+ 'p7s' => 'application/pkcs7-signature',
418
+ 'p8' => 'application/pkcs8',
419
+ 'pack' => 'application/x-java-pack200',
420
+ 'pak' => 'application/x-pak',
421
+ 'par2' => 'application/x-par2',
422
+ 'pas' => 'text/x-pascal',
423
+ 'patch' => 'text/x-patch',
424
+ 'pbm' => 'image/x-portable-bitmap',
425
+ 'pcd' => 'image/x-photo-cd',
426
+ 'pcf' => 'application/x-font-pcf',
427
+ 'pcf.gz' => 'application/x-font-pcf',
428
+ 'pcf.z' => 'application/x-font-pcf',
429
+ 'pcl' => 'application/vnd.hp-pcl',
430
+ 'pcx' => 'image/x-pcx',
431
+ 'pdb' => 'application/x-aportisdoc',
432
+ 'pdc' => 'application/x-aportisdoc',
433
+ 'pdf' => 'application/pdf',
434
+ 'pdf.bz2' => 'application/x-bzpdf',
435
+ 'pdf.gz' => 'application/x-gzpdf',
436
+ 'pdf.xz' => 'application/x-xzpdf',
437
+ 'pef' => 'image/x-pentax-pef',
438
+ 'pem' => 'application/x-x509-ca-cert',
439
+ 'perl' => 'application/x-perl',
440
+ 'pfa' => 'application/x-font-type1',
441
+ 'pfb' => 'application/x-font-type1',
442
+ 'pfx' => 'application/x-pkcs12',
443
+ 'pgm' => 'image/x-portable-graymap',
444
+ 'pgn' => 'application/x-chess-pgn',
445
+ 'pgp' => 'application/pgp-encrypted',
446
+ 'php' => 'application/x-php',
447
+ 'php3' => 'application/x-php',
448
+ 'php4' => 'application/x-php',
449
+ 'pict' => 'image/x-pict',
450
+ 'pict1' => 'image/x-pict',
451
+ 'pict2' => 'image/x-pict',
452
+ 'pk' => 'application/x-tex-pk',
453
+ 'pkipath' => 'application/pkix-pkipath',
454
+ 'pkr' => 'application/pgp-keys',
455
+ 'pl' => 'application/x-perl',
456
+ 'pla' => 'audio/x-iriver-pla',
457
+ 'pln' => 'application/x-planperfect',
458
+ 'pls' => 'audio/x-scpls',
459
+ 'pm' => 'application/x-perl',
460
+ 'png' => 'image/png',
461
+ 'pnm' => 'image/x-portable-anymap',
462
+ 'pntg' => 'image/x-macpaint',
463
+ 'po' => 'text/x-gettext-translation',
464
+ 'por' => 'application/x-spss-por',
465
+ 'pot' => 'application/vnd.ms-powerpoint',
466
+ 'ppm' => 'image/x-portable-pixmap',
467
+ 'pps' => 'application/vnd.ms-powerpoint',
468
+ 'ppsx' => 'application/vnd.openxmlformats-officedocument.presentationml.slideshow',
469
+ 'ppt' => 'application/vnd.ms-powerpoint',
470
+ 'pptm' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
471
+ 'pptx' => 'application/vnd.openxmlformats-officedocument.presentationml.presentation',
472
+ 'ppz' => 'application/vnd.ms-powerpoint',
473
+ 'prc' => 'application/x-palm-database',
474
+ 'ps' => 'application/postscript',
475
+ 'ps.bz2' => 'application/x-bzpostscript',
476
+ 'ps.gz' => 'application/x-gzpostscript',
477
+ 'psd' => 'image/vnd.adobe.photoshop',
478
+ 'psf' => 'application/x-font-linux-psf',
479
+ 'psf.gz' => 'application/x-gz-font-linux-psf',
480
+ 'psflib' => 'audio/x-psflib',
481
+ 'psid' => 'audio/prs.sid',
482
+ 'psw' => 'application/x-pocket-word',
483
+ 'pw' => 'application/x-pw',
484
+ 'py' => 'text/x-python',
485
+ 'pyc' => 'application/x-python-bytecode',
486
+ 'pyo' => 'application/x-python-bytecode',
487
+ 'qif' => 'application/x-qw',
488
+ 'qt' => 'video/quicktime',
489
+ 'qtif' => 'image/x-quicktime',
490
+ 'qtl' => 'application/x-quicktime-media-link',
491
+ 'qtvr' => 'video/quicktime',
492
+ 'ra' => 'audio/vnd.rn-realaudio',
493
+ 'raf' => 'image/x-fuji-raf',
494
+ 'ram' => 'application/ram',
495
+ 'rar' => 'application/x-rar',
496
+ 'ras' => 'image/x-cmu-raster',
497
+ 'raw' => 'image/x-panasonic-raw',
498
+ 'rax' => 'audio/vnd.rn-realaudio',
499
+ 'rb' => 'application/x-ruby',
500
+ 'rdf' => 'application/rdf+xml',
501
+ 'rdfs' => 'application/rdf+xml',
502
+ 'reg' => 'text/x-ms-regedit',
503
+ 'rej' => 'application/x-reject',
504
+ 'rgb' => 'image/x-rgb',
505
+ 'rle' => 'image/rle',
506
+ 'rm' => 'application/vnd.rn-realmedia',
507
+ 'rmj' => 'application/vnd.rn-realmedia',
508
+ 'rmm' => 'application/vnd.rn-realmedia',
509
+ 'rms' => 'application/vnd.rn-realmedia',
510
+ 'rmvb' => 'application/vnd.rn-realmedia',
511
+ 'rmx' => 'application/vnd.rn-realmedia',
512
+ 'rnc' => 'application/relax-ng-compact-syntax',
513
+ 'rng' => 'application/xml',
514
+ 'roff' => 'text/troff',
515
+ 'rp' => 'image/vnd.rn-realpix',
516
+ 'rpm' => 'application/x-rpm',
517
+ 'rss' => 'application/rss+xml',
518
+ 'rt' => 'text/vnd.rn-realtext',
519
+ 'rtf' => 'application/rtf',
520
+ 'rtx' => 'text/richtext',
521
+ 'rv' => 'video/vnd.rn-realvideo',
522
+ 'rvx' => 'video/vnd.rn-realvideo',
523
+ 'rw2' => 'image/x-panasonic-raw2',
524
+ 's3m' => 'audio/x-s3m',
525
+ 'sam' => 'application/x-amipro',
526
+ 'sami' => 'application/x-sami',
527
+ 'sav' => 'application/x-spss-sav',
528
+ 'scm' => 'text/x-scheme',
529
+ 'sda' => 'application/vnd.stardivision.draw',
530
+ 'sdc' => 'application/vnd.stardivision.calc',
531
+ 'sdd' => 'application/vnd.stardivision.impress',
532
+ 'sdp' => 'application/vnd.stardivision.impress',
533
+ 'sds' => 'application/vnd.stardivision.chart',
534
+ 'sdw' => 'application/vnd.stardivision.writer',
535
+ 'sgf' => 'application/x-go-sgf',
536
+ 'sgi' => 'image/x-sgi',
537
+ 'sgl' => 'application/vnd.stardivision.writer',
538
+ 'sgm' => 'text/sgml',
539
+ 'sgml' => 'text/sgml',
540
+ 'sh' => 'application/x-shellscript',
541
+ 'shape' => 'application/x-dia-shape',
542
+ 'shar' => 'application/x-shar',
543
+ 'shn' => 'application/x-shorten',
544
+ 'siag' => 'application/x-siag',
545
+ 'sid' => 'audio/prs.sid',
546
+ 'sik' => 'application/x-trash',
547
+ 'sis' => 'application/vnd.symbian.install',
548
+ 'sisx' => 'x-epoc/x-sisx-app',
549
+ 'sit' => 'application/x-stuffit',
550
+ 'siv' => 'application/sieve',
551
+ 'sk' => 'image/x-skencil',
552
+ 'sk1' => 'image/x-skencil',
553
+ 'skr' => 'application/pgp-keys',
554
+ 'slk' => 'text/spreadsheet',
555
+ 'smaf' => 'application/x-smaf',
556
+ 'smc' => 'application/x-snes-rom',
557
+ 'smd' => 'application/vnd.stardivision.mail',
558
+ 'smf' => 'application/vnd.stardivision.math',
559
+ 'smi' => 'application/smil',
560
+ 'smil' => 'application/smil',
561
+ 'sml' => 'application/smil',
562
+ 'sms' => 'application/x-sms-rom',
563
+ 'snd' => 'audio/basic',
564
+ 'so' => 'application/x-sharedlib',
565
+ 'spc' => 'application/x-pkcs7-certificates',
566
+ 'spd' => 'application/x-font-speedo',
567
+ 'spec' => 'text/x-rpm-spec',
568
+ 'spl' => 'application/x-shockwave-flash',
569
+ 'spx' => 'audio/ogg',
570
+ 'sql' => 'text/x-sql',
571
+ 'sr2' => 'image/x-sony-sr2',
572
+ 'src' => 'application/x-wais-source',
573
+ 'srf' => 'image/x-sony-srf',
574
+ 'srt' => 'application/x-subrip',
575
+ 'ssa' => 'text/x-ssa',
576
+ 'stc' => 'application/vnd.sun.xml.calc.template',
577
+ 'std' => 'application/vnd.sun.xml.draw.template',
578
+ 'sti' => 'application/vnd.sun.xml.impress.template',
579
+ 'stm' => 'audio/x-stm',
580
+ 'stw' => 'application/vnd.sun.xml.writer.template',
581
+ 'sty' => 'text/x-tex',
582
+ 'sub' => 'text/x-microdvd',
583
+ 'sun' => 'image/x-sun-raster',
584
+ 'sv' => 'text/x-svsrc',
585
+ 'sv4cpio' => 'application/x-sv4cpio',
586
+ 'sv4crc' => 'application/x-sv4crc',
587
+ 'svg' => 'image/svg+xml',
588
+ 'svgz' => 'image/svg+xml-compressed',
589
+ 'svh' => 'text/x-svhdr',
590
+ 'swf' => 'application/x-shockwave-flash',
591
+ 'swm' => 'application/x-ms-wim',
592
+ 'sxc' => 'application/vnd.sun.xml.calc',
593
+ 'sxd' => 'application/vnd.sun.xml.draw',
594
+ 'sxg' => 'application/vnd.sun.xml.writer.global',
595
+ 'sxi' => 'application/vnd.sun.xml.impress',
596
+ 'sxm' => 'application/vnd.sun.xml.math',
597
+ 'sxw' => 'application/vnd.sun.xml.writer',
598
+ 'sylk' => 'text/spreadsheet',
599
+ 't' => 'text/troff',
600
+ 't2t' => 'text/x-txt2tags',
601
+ 'tar' => 'application/x-tar',
602
+ 'tar.bz' => 'application/x-bzip-compressed-tar',
603
+ 'tar.bz2' => 'application/x-bzip-compressed-tar',
604
+ 'tar.gz' => 'application/x-compressed-tar',
605
+ 'tar.lrz' => 'application/x-lrzip-compressed-tar',
606
+ 'tar.lzma' => 'application/x-lzma-compressed-tar',
607
+ 'tar.lzo' => 'application/x-tzo',
608
+ 'tar.xz' => 'application/x-xz-compressed-tar',
609
+ 'tar.z' => 'application/x-tarz',
610
+ 'taz' => 'application/x-compressed-tar',
611
+ 'tbz' => 'application/x-bzip-compressed-tar',
612
+ 'tbz2' => 'application/x-bzip-compressed-tar',
613
+ 'tcl' => 'text/x-tcl',
614
+ 'tex' => 'text/x-tex',
615
+ 'texi' => 'text/x-texinfo',
616
+ 'texinfo' => 'text/x-texinfo',
617
+ 'tga' => 'image/x-tga',
618
+ 'tgz' => 'application/x-compressed-tar',
619
+ 'theme' => 'application/x-theme',
620
+ 'themepack' => 'application/x-windows-themepack',
621
+ 'tif' => 'image/tiff',
622
+ 'tiff' => 'image/tiff',
623
+ 'tk' => 'text/x-tcl',
624
+ 'tlrz' => 'application/x-lrzip-compressed-tar',
625
+ 'tlz' => 'application/x-lzma-compressed-tar',
626
+ 'tnef' => 'application/vnd.ms-tnef',
627
+ 'tnf' => 'application/vnd.ms-tnef',
628
+ 'toc' => 'application/x-cdrdao-toc',
629
+ 'torrent' => 'application/x-bittorrent',
630
+ 'tpic' => 'image/x-tga',
631
+ 'tr' => 'text/troff',
632
+ 'ts' => 'text/vnd.trolltech.linguist',
633
+ 'tsv' => 'text/tab-separated-values',
634
+ 'tta' => 'audio/x-tta',
635
+ 'ttc' => 'application/x-font-ttf',
636
+ 'ttf' => 'application/x-font-ttf',
637
+ 'ttx' => 'application/x-font-ttx',
638
+ 'txt' => 'text/plain',
639
+ 'txz' => 'application/x-xz-compressed-tar',
640
+ 'tzo' => 'application/x-tzo',
641
+ 'ufraw' => 'application/x-ufraw',
642
+ 'ui' => 'application/x-designer',
643
+ 'uil' => 'text/x-uil',
644
+ 'ult' => 'audio/x-mod',
645
+ 'uni' => 'audio/x-mod',
646
+ 'uri' => 'text/x-uri',
647
+ 'url' => 'text/x-uri',
648
+ 'ustar' => 'application/x-ustar',
649
+ 'v' => 'text/x-verilog',
650
+ 'vala' => 'text/x-vala',
651
+ 'vapi' => 'text/x-vala',
652
+ 'vcf' => 'text/directory',
653
+ 'vcs' => 'text/calendar',
654
+ 'vct' => 'text/directory',
655
+ 'vda' => 'image/x-tga',
656
+ 'vhd' => 'text/x-vhdl',
657
+ 'vhdl' => 'text/x-vhdl',
658
+ 'viv' => 'video/vivo',
659
+ 'vivo' => 'video/vivo',
660
+ 'vlc' => 'audio/x-mpegurl',
661
+ 'vob' => 'video/mpeg',
662
+ 'voc' => 'audio/x-voc',
663
+ 'vor' => 'application/vnd.stardivision.writer',
664
+ 'vst' => 'image/x-tga',
665
+ 'wav' => 'audio/x-wav',
666
+ 'wax' => 'audio/x-ms-asx',
667
+ 'wb1' => 'application/x-quattropro',
668
+ 'wb2' => 'application/x-quattropro',
669
+ 'wb3' => 'application/x-quattropro',
670
+ 'wbmp' => 'image/vnd.wap.wbmp',
671
+ 'wcm' => 'application/vnd.ms-works',
672
+ 'wdb' => 'application/vnd.ms-works',
673
+ 'webm' => 'video/webm',
674
+ 'wim' => 'application/x-ms-wim',
675
+ 'wk1' => 'application/vnd.lotus-1-2-3',
676
+ 'wk3' => 'application/vnd.lotus-1-2-3',
677
+ 'wk4' => 'application/vnd.lotus-1-2-3',
678
+ 'wks' => 'application/vnd.lotus-1-2-3',
679
+ 'wma' => 'audio/x-ms-wma',
680
+ 'wmf' => 'image/x-wmf',
681
+ 'wml' => 'text/vnd.wap.wml',
682
+ 'wmls' => 'text/vnd.wap.wmlscript',
683
+ 'wmv' => 'video/x-ms-wmv',
684
+ 'wmx' => 'audio/x-ms-asx',
685
+ 'wp' => 'application/vnd.wordperfect',
686
+ 'wp4' => 'application/vnd.wordperfect',
687
+ 'wp5' => 'application/vnd.wordperfect',
688
+ 'wp6' => 'application/vnd.wordperfect',
689
+ 'wpd' => 'application/vnd.wordperfect',
690
+ 'wpg' => 'application/x-wpg',
691
+ 'wpl' => 'application/vnd.ms-wpl',
692
+ 'wpp' => 'application/vnd.wordperfect',
693
+ 'wps' => 'application/vnd.ms-works',
694
+ 'wri' => 'application/x-mswrite',
695
+ 'wrl' => 'model/vrml',
696
+ 'wv' => 'audio/x-wavpack',
697
+ 'wvc' => 'audio/x-wavpack-correction',
698
+ 'wvp' => 'audio/x-wavpack',
699
+ 'wvx' => 'audio/x-ms-asx',
700
+ 'x3f' => 'image/x-sigma-x3f',
701
+ 'xac' => 'application/x-gnucash',
702
+ 'xbel' => 'application/x-xbel',
703
+ 'xbl' => 'application/xml',
704
+ 'xbm' => 'image/x-xbitmap',
705
+ 'xcf' => 'image/x-xcf',
706
+ 'xcf.bz2' => 'image/x-compressed-xcf',
707
+ 'xcf.gz' => 'image/x-compressed-xcf',
708
+ 'xhtml' => 'application/xhtml+xml',
709
+ 'xi' => 'audio/x-xi',
710
+ 'xla' => 'application/vnd.ms-excel',
711
+ 'xlc' => 'application/vnd.ms-excel',
712
+ 'xld' => 'application/vnd.ms-excel',
713
+ 'xlf' => 'application/x-xliff',
714
+ 'xliff' => 'application/x-xliff',
715
+ 'xll' => 'application/vnd.ms-excel',
716
+ 'xlm' => 'application/vnd.ms-excel',
717
+ 'xls' => 'application/vnd.ms-excel',
718
+ 'xlsm' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
719
+ 'xlsx' => 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet',
720
+ 'xlt' => 'application/vnd.ms-excel',
721
+ 'xlw' => 'application/vnd.ms-excel',
722
+ 'xm' => 'audio/x-xm',
723
+ 'xmf' => 'audio/x-xmf',
724
+ 'xmi' => 'text/x-xmi',
725
+ 'xml' => 'application/xml',
726
+ 'xpi' => 'application/x-xpinstall',
727
+ 'xpm' => 'image/x-xpixmap',
728
+ 'xps' => 'application/oxps',
729
+ 'xsd' => 'application/xml',
730
+ 'xsl' => 'application/xslt+xml',
731
+ 'xslfo' => 'text/x-xslfo',
732
+ 'xslt' => 'application/xslt+xml',
733
+ 'xspf' => 'application/xspf+xml',
734
+ 'xul' => 'application/vnd.mozilla.xul+xml',
735
+ 'xwd' => 'image/x-xwindowdump',
736
+ 'xz' => 'application/x-xz',
737
+ 'yaml' => 'application/x-yaml',
738
+ 'yml' => 'application/x-yaml',
739
+ 'z' => 'application/x-compress',
740
+ 'zabw' => 'application/x-abiword',
741
+ 'zip' => 'application/zip',
742
+ 'zoo' => 'application/x-zoo',
743
+ }
744
+ TYPES = {
745
+ 'application/andrew-inset' => [%w(ez), %w(), "ATK inset"],
746
+ 'application/annodex' => [%w(anx), %w(), "Annodex exchange format"],
747
+ 'application/atom+xml' => [%w(atom), %w(application/xml), "Atom syndication feed"],
748
+ 'application/dicom' => [%w(dcm), %w(), "DICOM image"],
749
+ 'application/docbook+xml' => [%w(docbook), %w(application/xml), "DocBook document"],
750
+ 'application/ecmascript' => [%w(es), %w(text/plain), "ECMAScript program"],
751
+ 'application/epub+zip' => [%w(epub), %w(application/zip), "electronic book document"],
752
+ 'application/gnunet-directory' => [%w(gnd), %w(), "GNUnet search file"],
753
+ 'application/illustrator' => [%w(ai), %w(), "Adobe Illustrator document"],
754
+ 'application/javascript' => [%w(js), %w(text/x-csrc), "JavaScript program"],
755
+ 'application/mathematica' => [%w(nb), %w(text/plain), "Mathematica Notebook"],
756
+ 'application/mathml+xml' => [%w(mml), %w(application/xml), "MathML document"],
757
+ 'application/mbox' => [%w(mbox), %w(text/plain), "mailbox file"],
758
+ 'application/metalink+xml' => [%w(metalink), %w(application/xml), "Metalink file"],
759
+ 'application/msword' => [%w(doc), %w(application/x-ole-storage), "Word document"],
760
+ 'application/msword-template' => [%w(dot), %w(application/msword), "Word template"],
761
+ 'application/mxf' => [%w(mxf), %w(), "MXF video"],
762
+ 'application/octet-stream' => [%w(bin), %w(), "unknown"],
763
+ 'application/oda' => [%w(oda), %w(), "ODA document"],
764
+ 'application/ogg' => [%w(ogx), %w(), "Ogg multimedia file"],
765
+ 'application/oxps' => [%w(oxps xps), %w(application/zip), "XPS document"],
766
+ 'application/pdf' => [%w(pdf), %w(), "PDF document"],
767
+ 'application/pgp-encrypted' => [%w(asc gpg pgp), %w(), "PGP/MIME-encrypted message header"],
768
+ 'application/pgp-keys' => [%w(asc pkr skr), %w(text/plain), "PGP keys"],
769
+ 'application/pkcs10' => [%w(p10), %w(), "PKCS#10 certification request"],
770
+ 'application/pkcs7-signature' => [%w(p7s), %w(text/plain), "detached S/MIME signature"],
771
+ 'application/pkcs8' => [%w(p8), %w(), "PKCS#8 private key"],
772
+ 'application/pkix-cert' => [%w(cer), %w(), "X.509 certificate"],
773
+ 'application/pkix-crl' => [%w(crl), %w(), "Certificate revocation list"],
774
+ 'application/pkix-pkipath' => [%w(pkipath), %w(), "PkiPath certification path"],
775
+ 'application/postscript' => [%w(ps), %w(text/plain), "PS document"],
776
+ 'application/ram' => [%w(ram), %w(), "RealMedia Metafile"],
777
+ 'application/rdf+xml' => [%w(owl rdf rdfs), %w(application/xml), "RDF file"],
778
+ 'application/relax-ng-compact-syntax' => [%w(rnc), %w(text/plain), "RELAX NG XML schema"],
779
+ 'application/rss+xml' => [%w(rss), %w(application/xml), "RSS summary"],
780
+ 'application/rtf' => [%w(rtf), %w(text/plain), "RTF document"],
781
+ 'application/sdp' => [%w(sdp), %w(), "SDP multicast stream file"],
782
+ 'application/sieve' => [%w(siv), %w(application/xml), "Sieve mail filter script"],
783
+ 'application/smil' => [%w(kino smi smil sml), %w(application/xml), "SMIL document"],
784
+ 'application/vnd.apple.mpegurl' => [%w(m3u m3u8), %w(), "HTTP Live Streaming playlist"],
785
+ 'application/vnd.corel-draw' => [%w(cdr), %w(), "Corel Draw drawing"],
786
+ 'application/vnd.emusic-emusic_package' => [%w(emp), %w(), "eMusic download package"],
787
+ 'application/vnd.google-earth.kml+xml' => [%w(kml), %w(application/xml), "KML geographic data"],
788
+ 'application/vnd.google-earth.kmz' => [%w(kmz), %w(application/zip), "KML geographic compressed data"],
789
+ 'application/vnd.hp-hpgl' => [%w(hpgl), %w(), "HPGL file"],
790
+ 'application/vnd.hp-pcl' => [%w(pcl), %w(), "PCL file"],
791
+ 'application/vnd.iccprofile' => [%w(icc icm), %w(), "ICC profile"],
792
+ 'application/vnd.lotus-1-2-3' => [%w(123 wk1 wk3 wk4 wks), %w(), "Lotus 1-2-3 spreadsheet"],
793
+ 'application/vnd.mozilla.xul+xml' => [%w(xul), %w(application/xml), "XUL interface document"],
794
+ 'application/vnd.ms-access' => [%w(mdb), %w(), "JET database"],
795
+ 'application/vnd.ms-cab-compressed' => [%w(cab), %w(), "Microsoft Cabinet archive"],
796
+ 'application/vnd.ms-excel' => [%w(xla xlc xld xll xlm xls xlt xlw), %w(), "Excel spreadsheet"],
797
+ 'application/vnd.ms-powerpoint' => [%w(pot pps ppt ppz), %w(), "PowerPoint presentation"],
798
+ 'application/vnd.ms-tnef' => [%w(tnef tnf), %w(), "TNEF message"],
799
+ 'application/vnd.ms-works' => [%w(wcm wdb wks wps), %w(application/x-ole-storage), "Microsoft Works document"],
800
+ 'application/vnd.ms-wpl' => [%w(wpl), %w(), "WPL playlist"],
801
+ 'application/vnd.oasis.opendocument.chart' => [%w(odc), %w(application/zip), "ODC chart"],
802
+ 'application/vnd.oasis.opendocument.chart-template' => [%w(otc), %w(application/zip), "ODC template"],
803
+ 'application/vnd.oasis.opendocument.database' => [%w(odb), %w(application/zip), "ODB database"],
804
+ 'application/vnd.oasis.opendocument.formula' => [%w(odf), %w(application/zip), "ODF formula"],
805
+ 'application/vnd.oasis.opendocument.formula-template' => [%w(otf), %w(application/zip), "ODF template"],
806
+ 'application/vnd.oasis.opendocument.graphics' => [%w(odg), %w(application/zip), "ODG drawing"],
807
+ 'application/vnd.oasis.opendocument.graphics-flat-xml' => [%w(fodg), %w(application/xml), "ODG drawing (Flat XML)"],
808
+ 'application/vnd.oasis.opendocument.graphics-template' => [%w(otg), %w(application/zip), "ODG template"],
809
+ 'application/vnd.oasis.opendocument.image' => [%w(odi), %w(application/zip), "ODI image"],
810
+ 'application/vnd.oasis.opendocument.presentation' => [%w(odp), %w(application/zip), "ODP presentation"],
811
+ 'application/vnd.oasis.opendocument.presentation-flat-xml' => [%w(fodp), %w(application/xml), "ODP presentation (Flat XML)"],
812
+ 'application/vnd.oasis.opendocument.presentation-template' => [%w(otp), %w(application/zip), "ODP template"],
813
+ 'application/vnd.oasis.opendocument.spreadsheet' => [%w(ods), %w(application/zip), "ODS spreadsheet"],
814
+ 'application/vnd.oasis.opendocument.spreadsheet-flat-xml' => [%w(fods), %w(application/xml), "ODS spreadsheet (Flat XML)"],
815
+ 'application/vnd.oasis.opendocument.spreadsheet-template' => [%w(ots), %w(application/zip), "ODS template"],
816
+ 'application/vnd.oasis.opendocument.text' => [%w(odt), %w(application/zip), "ODT document"],
817
+ 'application/vnd.oasis.opendocument.text-flat-xml' => [%w(fodt), %w(application/xml), "ODT document (Flat XML)"],
818
+ 'application/vnd.oasis.opendocument.text-master' => [%w(odm), %w(application/zip), "ODM document"],
819
+ 'application/vnd.oasis.opendocument.text-template' => [%w(ott), %w(application/zip), "ODT template"],
820
+ 'application/vnd.oasis.opendocument.text-web' => [%w(oth), %w(application/zip), "OTH template"],
821
+ 'application/vnd.openofficeorg.extension' => [%w(oxt), %w(application/zip), "OpenOffice.org extension"],
822
+ 'application/vnd.openxmlformats-officedocument.presentationml.presentation' => [%w(pptm pptx), %w(application/zip), "PowerPoint 2007 presentation"],
823
+ 'application/vnd.openxmlformats-officedocument.presentationml.slideshow' => [%w(ppsx), %w(application/zip), "PowerPoint 2007 show"],
824
+ 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' => [%w(xlsm xlsx), %w(application/zip), "Excel 2007 spreadsheet"],
825
+ 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' => [%w(docm docx), %w(application/zip), "Word 2007 document"],
826
+ 'application/vnd.rn-realmedia' => [%w(rm rmj rmm rms rmvb rmx), %w(), "RealMedia document"],
827
+ 'application/vnd.stardivision.calc' => [%w(sdc), %w(), "StarCalc spreadsheet"],
828
+ 'application/vnd.stardivision.chart' => [%w(sds), %w(), "StarChart chart"],
829
+ 'application/vnd.stardivision.draw' => [%w(sda), %w(), "StarDraw drawing"],
830
+ 'application/vnd.stardivision.impress' => [%w(sdd sdp), %w(), "StarImpress presentation"],
831
+ 'application/vnd.stardivision.mail' => [%w(smd), %w(), "StarMail email"],
832
+ 'application/vnd.stardivision.math' => [%w(smf), %w(), "StarMath formula"],
833
+ 'application/vnd.stardivision.writer' => [%w(sdw sgl vor), %w(), "StarWriter document"],
834
+ 'application/vnd.sun.xml.calc' => [%w(sxc), %w(application/zip), "OpenOffice Calc spreadsheet"],
835
+ 'application/vnd.sun.xml.calc.template' => [%w(stc), %w(application/zip), "OpenOffice Calc template"],
836
+ 'application/vnd.sun.xml.draw' => [%w(sxd), %w(application/zip), "OpenOffice Draw drawing"],
837
+ 'application/vnd.sun.xml.draw.template' => [%w(std), %w(application/zip), "OpenOffice Draw template"],
838
+ 'application/vnd.sun.xml.impress' => [%w(sxi), %w(application/zip), "OpenOffice Impress presentation"],
839
+ 'application/vnd.sun.xml.impress.template' => [%w(sti), %w(application/zip), "OpenOffice Impress template"],
840
+ 'application/vnd.sun.xml.math' => [%w(sxm), %w(application/zip), "OpenOffice Math formula"],
841
+ 'application/vnd.sun.xml.writer' => [%w(sxw), %w(application/zip), "OpenOffice Writer document"],
842
+ 'application/vnd.sun.xml.writer.global' => [%w(sxg), %w(application/zip), "OpenOffice Writer global document"],
843
+ 'application/vnd.sun.xml.writer.template' => [%w(stw), %w(application/zip), "OpenOffice Writer template"],
844
+ 'application/vnd.symbian.install' => [%w(sis), %w(), "SIS package"],
845
+ 'application/vnd.wordperfect' => [%w(wp wp4 wp5 wp6 wpd wpp), %w(), "WordPerfect document"],
846
+ 'application/x-7z-compressed' => [%w(7z), %w(), "7-zip archive"],
847
+ 'application/x-abiword' => [%w(abw abw.crashed abw.gz zabw), %w(application/xml), "AbiWord document"],
848
+ 'application/x-ace' => [%w(ace), %w(), "ACE archive"],
849
+ 'application/x-alz' => [%w(alz), %w(), "Alzip archive"],
850
+ 'application/x-amipro' => [%w(sam), %w(), "Lotus AmiPro document"],
851
+ 'application/x-aportisdoc' => [%w(pdb pdc), %w(application/x-palm-database), "AportisDoc document"],
852
+ 'application/x-apple-diskimage' => [%w(dmg), %w(), "Apple disk image"],
853
+ 'application/x-applix-spreadsheet' => [%w(as), %w(), "Applix Spreadsheets spreadsheet"],
854
+ 'application/x-applix-word' => [%w(aw), %w(), "Applix Words document"],
855
+ 'application/x-archive' => [%w(a), %w(), "AR archive"],
856
+ 'application/x-arj' => [%w(arj), %w(), "ARJ archive"],
857
+ 'application/x-asp' => [%w(asp), %w(text/plain), "ASP page"],
858
+ 'application/x-awk' => [%w(awk), %w(application/x-executable text/plain), "AWK script"],
859
+ 'application/x-bcpio' => [%w(bcpio), %w(), "BCPIO document"],
860
+ 'application/x-bittorrent' => [%w(torrent), %w(), "BitTorrent seed file"],
861
+ 'application/x-blender' => [%w(blend blend blender), %w(), "Blender scene"],
862
+ 'application/x-bzdvi' => [%w(dvi.bz2), %w(), "TeX DVI document (bzip-compressed)"],
863
+ 'application/x-bzip' => [%w(bz bz2), %w(), "Bzip archive"],
864
+ 'application/x-bzip-compressed-tar' => [%w(tar.bz tar.bz2 tbz tbz2), %w(application/x-bzip), "Tar archive (bzip-compressed)"],
865
+ 'application/x-bzpdf' => [%w(pdf.bz2), %w(), "PDF document (bzip-compressed)"],
866
+ 'application/x-bzpostscript' => [%w(ps.bz2), %w(), "PostScript document (bzip-compressed)"],
867
+ 'application/x-cb7' => [%w(cb7), %w(application/x-7z-compressed), "comic book archive"],
868
+ 'application/x-cbr' => [%w(cbr), %w(application/x-rar), "comic book archive"],
869
+ 'application/x-cbt' => [%w(cbt), %w(application/x-tar), "comic book archive"],
870
+ 'application/x-cbz' => [%w(cbz), %w(application/zip), "comic book archive"],
871
+ 'application/x-cd-image' => [%w(iso iso9660), %w(), "raw CD image"],
872
+ 'application/x-cdrdao-toc' => [%w(toc), %w(text/plain), "CD Table Of Contents"],
873
+ 'application/x-chess-pgn' => [%w(pgn), %w(text/plain), "PGN chess game notation"],
874
+ 'application/x-chm' => [%w(chm), %w(), "CHM document"],
875
+ 'application/x-cisco-vpn-settings' => [%w(pcf), %w(), "Cisco VPN Settings"],
876
+ 'application/x-compress' => [%w(z), %w(), "UNIX-compressed file"],
877
+ 'application/x-compressed-tar' => [%w(tar.gz taz tgz), %w(), "Tar archive (gzip-compressed)"],
878
+ 'application/x-cpio' => [%w(cpio), %w(), "CPIO archive"],
879
+ 'application/x-cpio-compressed' => [%w(cpio.gz), %w(), "CPIO archive (gzip-compressed)"],
880
+ 'application/x-csh' => [%w(csh), %w(application/x-shellscript text/plain), "C shell script"],
881
+ 'application/x-cue' => [%w(cue), %w(text/plain), "CD image cuesheet"],
882
+ 'application/x-dar' => [%w(dar), %w(), "DAR archive"],
883
+ 'application/x-dbf' => [%w(dbf), %w(), "Xbase document"],
884
+ 'application/x-dc-rom' => [%w(dc), %w(), "Dreamcast ROM"],
885
+ 'application/x-deb' => [%w(deb), %w(), "Debian package"],
886
+ 'application/x-designer' => [%w(ui), %w(application/xml), "Qt Designer file"],
887
+ 'application/x-desktop' => [%w(desktop kdelnk), %w(text/plain), "desktop configuration file"],
888
+ 'application/x-dia-diagram' => [%w(dia), %w(application/xml), "Dia diagram"],
889
+ 'application/x-dia-shape' => [%w(shape), %w(application/xml), "Dia shape"],
890
+ 'application/x-dvi' => [%w(dvi), %w(), "TeX DVI document"],
891
+ 'application/x-e-theme' => [%w(etheme), %w(), "Enlightenment theme"],
892
+ 'application/x-egon' => [%w(egon), %w(), "Egon Animator animation"],
893
+ 'application/x-fictionbook+xml' => [%w(fb2), %w(application/xml), "FictionBook document"],
894
+ 'application/x-fluid' => [%w(fl), %w(text/plain), "FLTK Fluid file"],
895
+ 'application/x-font-afm' => [%w(afm), %w(), "Adobe font metrics"],
896
+ 'application/x-font-bdf' => [%w(bdf), %w(), "BDF font"],
897
+ 'application/x-font-linux-psf' => [%w(psf), %w(), "Linux PSF console font"],
898
+ 'application/x-font-otf' => [%w(otf), %w(), "OpenType font"],
899
+ 'application/x-font-pcf' => [%w(pcf pcf.gz pcf.z), %w(), "PCF font"],
900
+ 'application/x-font-speedo' => [%w(spd), %w(), "Speedo font"],
901
+ 'application/x-font-ttf' => [%w(ttc ttf), %w(), "TrueType font"],
902
+ 'application/x-font-ttx' => [%w(ttx), %w(text/xml), "TrueType XML font"],
903
+ 'application/x-font-type1' => [%w(gsf pfa pfb), %w(application/postscript), "Postscript type-1 font"],
904
+ 'application/x-gameboy-rom' => [%w(gb), %w(), "Game Boy ROM"],
905
+ 'application/x-gba-rom' => [%w(gba), %w(), "Game Boy Advance ROM"],
906
+ 'application/x-gedcom' => [%w(ged gedcom), %w(), "GEDCOM family history"],
907
+ 'application/x-genesis-rom' => [%w(gen md), %w(), "Genesis ROM"],
908
+ 'application/x-gettext-translation' => [%w(gmo mo), %w(), "translated messages (machine-readable)"],
909
+ 'application/x-glade' => [%w(glade), %w(application/xml), "Glade project"],
910
+ 'application/x-gnucash' => [%w(gnc gnucash xac), %w(), "GnuCash financial data"],
911
+ 'application/x-gnumeric' => [%w(gnumeric), %w(), "Gnumeric spreadsheet"],
912
+ 'application/x-gnuplot' => [%w(gnuplot gp gplt), %w(text/plain), "Gnuplot document"],
913
+ 'application/x-go-sgf' => [%w(sgf), %w(text/plain), "SGF record"],
914
+ 'application/x-graphite' => [%w(gra), %w(), "Graphite scientific graph"],
915
+ 'application/x-gz-font-linux-psf' => [%w(psf.gz), %w(application/x-gzip), "Linux PSF console font (gzip-compressed)"],
916
+ 'application/x-gzdvi' => [%w(dvi.gz), %w(application/x-gzip), "TeX DVI document (gzip-compressed)"],
917
+ 'application/x-gzip' => [%w(gz), %w(), "Gzip archive"],
918
+ 'application/x-gzpdf' => [%w(pdf.gz), %w(application/x-gzip), "PDF document (gzip-compressed)"],
919
+ 'application/x-gzpostscript' => [%w(ps.gz), %w(application/x-gzip), "PostScript document (gzip-compressed)"],
920
+ 'application/x-hdf' => [%w(h4 h5 hdf hdf4 hdf5), %w(), "HDF document"],
921
+ 'application/x-hwp' => [%w(hwp), %w(), "Haansoft Hangul document"],
922
+ 'application/x-hwt' => [%w(hwt), %w(), "Haansoft Hangul document template"],
923
+ 'application/x-ica' => [%w(ica), %w(text/plain), "Citrix ICA settings file"],
924
+ 'application/x-it87' => [%w(it87), %w(text/plain), "IT 8.7 color calibration file"],
925
+ 'application/x-java' => [%w(class), %w(), "Java class"],
926
+ 'application/x-java-archive' => [%w(jar), %w(), "Java archive"],
927
+ 'application/x-java-jce-keystore' => [%w(jceks), %w(), "Java JCE keystore"],
928
+ 'application/x-java-jnlp-file' => [%w(jnlp), %w(application/xml), "JNLP file"],
929
+ 'application/x-java-keystore' => [%w(jks ks), %w(), "Java keystore"],
930
+ 'application/x-java-pack200' => [%w(pack), %w(), "Pack200 Java archive"],
931
+ 'application/x-jbuilder-project' => [%w(jpr jpx), %w(), "JBuilder project"],
932
+ 'application/x-karbon' => [%w(karbon), %w(), "Karbon14 drawing"],
933
+ 'application/x-kchart' => [%w(chrt), %w(), "KChart chart"],
934
+ 'application/x-kexi-connectiondata' => [%w(kexic), %w(), "Kexi settings for database server connection"],
935
+ 'application/x-kexiproject-shortcut' => [%w(kexis), %w(), "shortcut to Kexi project on database server"],
936
+ 'application/x-kexiproject-sqlite2' => [%w(kexi), %w(application/x-sqlite2), "Kexi database file-based project"],
937
+ 'application/x-kexiproject-sqlite3' => [%w(kexi), %w(application/x-sqlite3), "Kexi database file-based project"],
938
+ 'application/x-kformula' => [%w(kfo), %w(), "KFormula formula"],
939
+ 'application/x-killustrator' => [%w(kil), %w(), "KIllustrator drawing"],
940
+ 'application/x-kivio' => [%w(flw), %w(), "Kivio flowchart"],
941
+ 'application/x-kontour' => [%w(kon), %w(), "Kontour drawing"],
942
+ 'application/x-kpovmodeler' => [%w(kpm), %w(), "KPovModeler scene"],
943
+ 'application/x-kpresenter' => [%w(kpr kpt), %w(), "KPresenter presentation"],
944
+ 'application/x-krita' => [%w(kra), %w(), "Krita document"],
945
+ 'application/x-kspread' => [%w(ksp), %w(), "KSpread spreadsheet"],
946
+ 'application/x-kugar' => [%w(kud), %w(), "Kugar document"],
947
+ 'application/x-kword' => [%w(kwd kwt), %w(), "KWord document"],
948
+ 'application/x-lha' => [%w(lha lzh), %w(), "LHA archive"],
949
+ 'application/x-lhz' => [%w(lhz), %w(), "LHZ archive"],
950
+ 'application/x-lrzip' => [%w(lrz), %w(), "Lrzip archive"],
951
+ 'application/x-lrzip-compressed-tar' => [%w(tar.lrz tlrz), %w(application/x-lrzip), "Tar archive (lrzip-compressed)"],
952
+ 'application/x-lyx' => [%w(lyx), %w(text/plain), "LyX document"],
953
+ 'application/x-lzip' => [%w(lz), %w(), "Lzip archive"],
954
+ 'application/x-lzma' => [%w(lzma), %w(), "LZMA archive"],
955
+ 'application/x-lzma-compressed-tar' => [%w(tar.lzma tlz), %w(), "Tar archive (LZMA-compressed)"],
956
+ 'application/x-lzop' => [%w(lzo), %w(), "LZO archive"],
957
+ 'application/x-m4' => [%w(m4), %w(text/plain), "M4 macro"],
958
+ 'application/x-magicpoint' => [%w(mgp), %w(text/plain), "MagicPoint presentation"],
959
+ 'application/x-markaby' => [%w(mab), %w(application/x-ruby), "Markaby script"],
960
+ 'application/x-mif' => [%w(mif), %w(), "Adobe FrameMaker MIF document"],
961
+ 'application/x-ms-dos-executable' => [%w(exe), %w(), "DOS/Windows executable"],
962
+ 'application/x-ms-wim' => [%w(swm wim), %w(), "Windows Imaging Format Disk Image"],
963
+ 'application/x-msi' => [%w(msi), %w(application/x-ole-storage), "Windows Installer package"],
964
+ 'application/x-mswrite' => [%w(wri), %w(), "WRI document"],
965
+ 'application/x-msx-rom' => [%w(msx), %w(), "MSX ROM"],
966
+ 'application/x-n64-rom' => [%w(n64), %w(), "Nintendo64 ROM"],
967
+ 'application/x-navi-animation' => [%w(ani), %w(), "Windows animated cursor"],
968
+ 'application/x-nes-rom' => [%w(nes), %w(), "NES ROM"],
969
+ 'application/x-netcdf' => [%w(cdf nc), %w(), "Unidata NetCDF document"],
970
+ 'application/x-netshow-channel' => [%w(nsc), %w(video/x-ms-asf), "Windows Media Station file"],
971
+ 'application/x-nintendo-ds-rom' => [%w(nds), %w(), "Nintendo DS ROM"],
972
+ 'application/x-object' => [%w(o), %w(), "object code"],
973
+ 'application/x-oleo' => [%w(oleo), %w(), "GNU Oleo spreadsheet"],
974
+ 'application/x-pak' => [%w(pak), %w(), "PAK archive"],
975
+ 'application/x-palm-database' => [%w(pdb prc), %w(), "Palm OS database"],
976
+ 'application/x-par2' => [%w(par2 par2), %w(), "Parchive archive"],
977
+ 'application/x-perl' => [%w(al perl pl pm), %w(application/x-executable text/plain), "Perl script"],
978
+ 'application/x-php' => [%w(php php3 php4), %w(text/plain), "PHP script"],
979
+ 'application/x-pkcs12' => [%w(p12 pfx), %w(), "PKCS#12 certificate bundle"],
980
+ 'application/x-pkcs7-certificates' => [%w(p7b spc), %w(), "PKCS#7 certificate bundle"],
981
+ 'application/x-planperfect' => [%w(pln), %w(), "PlanPerfect spreadsheet"],
982
+ 'application/x-pocket-word' => [%w(psw), %w(), "Pocket Word document"],
983
+ 'application/x-pw' => [%w(pw), %w(), "Pathetic Writer document"],
984
+ 'application/x-python-bytecode' => [%w(pyc pyo), %w(), "Python bytecode"],
985
+ 'application/x-quattropro' => [%w(wb1 wb2 wb3), %w(), "Quattro Pro spreadsheet"],
986
+ 'application/x-quicktime-media-link' => [%w(qtl), %w(video/quicktime), "QuickTime metalink playlist"],
987
+ 'application/x-qw' => [%w(qif), %w(), "Quicken document"],
988
+ 'application/x-rar' => [%w(rar), %w(), "RAR archive"],
989
+ 'application/x-reject' => [%w(rej), %w(text/plain), "rejected patch"],
990
+ 'application/x-rpm' => [%w(rpm), %w(), "RPM package"],
991
+ 'application/x-ruby' => [%w(rb), %w(application/x-executable text/plain), "Ruby script"],
992
+ 'application/x-sami' => [%w(sami smi), %w(text/plain), "SAMI subtitles"],
993
+ 'application/x-shar' => [%w(shar), %w(), "shell archive"],
994
+ 'application/x-shared-library-la' => [%w(la), %w(text/plain), "libtool shared library"],
995
+ 'application/x-sharedlib' => [%w(so), %w(), "shared library"],
996
+ 'application/x-shellscript' => [%w(sh), %w(application/x-executable text/plain), "shell script"],
997
+ 'application/x-shockwave-flash' => [%w(spl swf), %w(), "Shockwave Flash file"],
998
+ 'application/x-shorten' => [%w(shn), %w(), "Shorten audio"],
999
+ 'application/x-siag' => [%w(siag), %w(), "Siag spreadsheet"],
1000
+ 'application/x-smaf' => [%w(mmf smaf), %w(), "SMAF audio"],
1001
+ 'application/x-sms-rom' => [%w(gg sms), %w(), "Sega Master System/Game Gear ROM"],
1002
+ 'application/x-snes-rom' => [%w(smc), %w(), "Super NES ROM"],
1003
+ 'application/x-spss-por' => [%w(por), %w(), "SPSS Portable Data File"],
1004
+ 'application/x-spss-sav' => [%w(sav), %w(), "SPSS Data File"],
1005
+ 'application/x-stuffit' => [%w(sit), %w(), "StuffIt archive"],
1006
+ 'application/x-subrip' => [%w(srt), %w(text/plain), "SubRip subtitles"],
1007
+ 'application/x-sv4cpio' => [%w(sv4cpio), %w(), "SV4 CPIO archive"],
1008
+ 'application/x-sv4crc' => [%w(sv4crc), %w(), "SV4 CPIO archive (with CRC)"],
1009
+ 'application/x-t602' => [%w(602), %w(), "T602 document"],
1010
+ 'application/x-tar' => [%w(gem gtar tar), %w(), "Tar archive"],
1011
+ 'application/x-tarz' => [%w(tar.z), %w(), "Tar archive (compressed)"],
1012
+ 'application/x-tex-gf' => [%w(gf), %w(), "generic font file"],
1013
+ 'application/x-tex-pk' => [%w(pk), %w(), "packed font file"],
1014
+ 'application/x-tgif' => [%w(obj), %w(), "TGIF document"],
1015
+ 'application/x-theme' => [%w(theme), %w(application/x-desktop), "theme"],
1016
+ 'application/x-trash' => [%w(bak old sik), %w(), "backup file"],
1017
+ 'application/x-troff-man' => [%w(man), %w(text/plain), "Troff document (with manpage macros)"],
1018
+ 'application/x-tzo' => [%w(tar.lzo tzo), %w(), "Tar archive (LZO-compressed)"],
1019
+ 'application/x-ufraw' => [%w(ufraw), %w(text/xml), "UFRaw ID image"],
1020
+ 'application/x-ustar' => [%w(ustar), %w(), "Ustar archive"],
1021
+ 'application/x-wais-source' => [%w(src), %w(), "WAIS source code"],
1022
+ 'application/x-windows-themepack' => [%w(themepack), %w(application/vnd.ms-cab-compressed), "Microsoft Windows theme pack"],
1023
+ 'application/x-wpg' => [%w(wpg), %w(), "WordPerfect/Drawperfect image"],
1024
+ 'application/x-x509-ca-cert' => [%w(cert crt der pem), %w(), "DER/PEM/Netscape-encoded X.509 certificate"],
1025
+ 'application/x-xbel' => [%w(xbel), %w(application/xml), "XBEL bookmarks"],
1026
+ 'application/x-xliff' => [%w(xlf xliff), %w(application/xml), "XLIFF translation file"],
1027
+ 'application/x-xpinstall' => [%w(xpi), %w(application/zip), "XPInstall installer module"],
1028
+ 'application/x-xz' => [%w(xz), %w(), "XZ archive"],
1029
+ 'application/x-xz-compressed-tar' => [%w(tar.xz txz), %w(), "Tar archive (XZ-compressed)"],
1030
+ 'application/x-xzpdf' => [%w(pdf.xz), %w(application/x-xz), "PDF document (XZ-compressed)"],
1031
+ 'application/x-yaml' => [%w(yaml yml), %w(text/plain), "YAML document"],
1032
+ 'application/x-zoo' => [%w(zoo), %w(), "Zoo archive"],
1033
+ 'application/xhtml+xml' => [%w(xhtml), %w(application/xml), "XHTML page"],
1034
+ 'application/xml' => [%w(rng xbl xml xsd), %w(text/plain), "XML document"],
1035
+ 'application/xml-dtd' => [%w(dtd), %w(text/plain), "DTD file"],
1036
+ 'application/xml-external-parsed-entity' => [%w(ent), %w(application/xml), "XML entities document"],
1037
+ 'application/xslt+xml' => [%w(xsl xslt), %w(application/xml), "XSLT stylesheet"],
1038
+ 'application/xspf+xml' => [%w(xspf), %w(application/xml), "XSPF playlist"],
1039
+ 'application/zip' => [%w(zip), %w(), "Zip archive"],
1040
+ 'audio/AMR' => [%w(amr), %w(), "AMR audio"],
1041
+ 'audio/AMR-WB' => [%w(awb), %w(), "AMR-WB audio"],
1042
+ 'audio/ac3' => [%w(ac3), %w(), "Dolby Digital audio"],
1043
+ 'audio/annodex' => [%w(axa), %w(application/annodex), "Annodex Audio"],
1044
+ 'audio/basic' => [%w(au snd), %w(), "ULAW (Sun) audio"],
1045
+ 'audio/flac' => [%w(flac), %w(), "FLAC audio"],
1046
+ 'audio/midi' => [%w(kar mid midi), %w(), "MIDI audio"],
1047
+ 'audio/mp2' => [%w(mp2), %w(), "MP2 audio"],
1048
+ 'audio/mp4' => [%w(aac f4a m4a), %w(), "MPEG-4 audio"],
1049
+ 'audio/mpeg' => [%w(mp3 mpga), %w(), "MP3 audio"],
1050
+ 'audio/ogg' => [%w(oga ogg spx), %w(application/ogg), "Ogg Audio"],
1051
+ 'audio/prs.sid' => [%w(psid sid), %w(), "Commodore 64 audio"],
1052
+ 'audio/vnd.rn-realaudio' => [%w(ra rax), %w(), "RealAudio document"],
1053
+ 'audio/x-aiff' => [%w(aif aifc aiff), %w(), "AIFF/Amiga/Mac audio"],
1054
+ 'audio/x-ape' => [%w(ape), %w(), "Monkey's audio"],
1055
+ 'audio/x-flac+ogg' => [%w(ogg), %w(audio/ogg), "Ogg FLAC audio"],
1056
+ 'audio/x-gsm' => [%w(gsm), %w(), "GSM 06.10 audio"],
1057
+ 'audio/x-iriver-pla' => [%w(pla), %w(), "iRiver Playlist"],
1058
+ 'audio/x-it' => [%w(it), %w(), "Impulse Tracker audio"],
1059
+ 'audio/x-m4b' => [%w(f4b m4b), %w(audio/mp4), "MPEG-4 audio book"],
1060
+ 'audio/x-matroska' => [%w(mka), %w(application/x-matroska), "Matroska audio"],
1061
+ 'audio/x-minipsf' => [%w(minipsf), %w(audio/x-psf), "MiniPSF audio"],
1062
+ 'audio/x-mo3' => [%w(mo3), %w(), "compressed Tracker audio"],
1063
+ 'audio/x-mod' => [%w(669 m15 med mod mtm ult uni), %w(), "Amiga SoundTracker audio"],
1064
+ 'audio/x-mpegurl' => [%w(m3u m3u8 vlc), %w(text/plain), "MP3 audio (streamed)"],
1065
+ 'audio/x-ms-asx' => [%w(asx wax wmx wvx), %w(), "Microsoft ASX playlist"],
1066
+ 'audio/x-ms-wma' => [%w(wma), %w(video/x-ms-asf), "Windows Media audio"],
1067
+ 'audio/x-musepack' => [%w(mp+ mpc mpp), %w(), "Musepack audio"],
1068
+ 'audio/x-psf' => [%w(psf), %w(), "PSF audio"],
1069
+ 'audio/x-psflib' => [%w(psflib), %w(audio/x-psf), "PSFlib audio library"],
1070
+ 'audio/x-s3m' => [%w(s3m), %w(), "Scream Tracker 3 audio"],
1071
+ 'audio/x-scpls' => [%w(pls), %w(), "MP3 ShoutCast playlist"],
1072
+ 'audio/x-speex' => [%w(spx), %w(), "Speex audio"],
1073
+ 'audio/x-speex+ogg' => [%w(ogg), %w(audio/ogg), "Ogg Speex audio"],
1074
+ 'audio/x-stm' => [%w(stm), %w(), "Scream Tracker audio"],
1075
+ 'audio/x-tta' => [%w(tta), %w(), "TrueAudio audio"],
1076
+ 'audio/x-voc' => [%w(voc), %w(), "VOC audio"],
1077
+ 'audio/x-vorbis+ogg' => [%w(ogg), %w(audio/ogg), "Ogg Vorbis audio"],
1078
+ 'audio/x-wav' => [%w(wav), %w(), "WAV audio"],
1079
+ 'audio/x-wavpack' => [%w(wv wvp), %w(), "WavPack audio"],
1080
+ 'audio/x-wavpack-correction' => [%w(wvc), %w(), "WavPack audio correction file"],
1081
+ 'audio/x-xi' => [%w(xi), %w(), "Scream Tracker instrument"],
1082
+ 'audio/x-xm' => [%w(xm), %w(), "FastTracker II audio"],
1083
+ 'audio/x-xmf' => [%w(xmf), %w(), "XMF audio"],
1084
+ 'image/bmp' => [%w(bmp), %w(), "Windows BMP image"],
1085
+ 'image/cgm' => [%w(cgm), %w(), "Computer Graphics Metafile"],
1086
+ 'image/fax-g3' => [%w(g3), %w(), "CCITT G3 fax"],
1087
+ 'image/fits' => [%w(fits), %w(), "FITS document"],
1088
+ 'image/gif' => [%w(gif), %w(), "GIF image"],
1089
+ 'image/ief' => [%w(ief), %w(), "IEF image"],
1090
+ 'image/jp2' => [%w(j2k jp2 jpc jpf jpx), %w(), "JPEG-2000 image"],
1091
+ 'image/jpeg' => [%w(jpeg jpg jpe), %w(), "JPEG image"],
1092
+ 'image/openraster' => [%w(ora), %w(), "OpenRaster archiving image"],
1093
+ 'image/png' => [%w(png), %w(), "PNG image"],
1094
+ 'image/rle' => [%w(rle), %w(), "Run Length Encoded bitmap image"],
1095
+ 'image/svg+xml' => [%w(svg), %w(application/xml), "SVG image"],
1096
+ 'image/svg+xml-compressed' => [%w(svgz), %w(application/x-gzip), "compressed SVG image"],
1097
+ 'image/tiff' => [%w(tif tiff), %w(), "TIFF image"],
1098
+ 'image/vnd.adobe.photoshop' => [%w(psd), %w(), "Photoshop image"],
1099
+ 'image/vnd.djvu' => [%w(djv djvu), %w(), "DjVu image"],
1100
+ 'image/vnd.dwg' => [%w(dwg), %w(), "AutoCAD image"],
1101
+ 'image/vnd.dxf' => [%w(dxf), %w(), "DXF vector image"],
1102
+ 'image/vnd.microsoft.icon' => [%w(ico), %w(), "Microsoft icon"],
1103
+ 'image/vnd.ms-modi' => [%w(mdi), %w(), "Microsoft Document Imaging format"],
1104
+ 'image/vnd.rn-realpix' => [%w(rp), %w(), "RealPix document"],
1105
+ 'image/vnd.wap.wbmp' => [%w(wbmp), %w(), "WBMP image"],
1106
+ 'image/x-3ds' => [%w(3ds), %w(), "3D Studio image"],
1107
+ 'image/x-adobe-dng' => [%w(dng), %w(image/tiff image/x-dcraw), "Adobe DNG negative"],
1108
+ 'image/x-applix-graphics' => [%w(ag), %w(), "Applix Graphics image"],
1109
+ 'image/x-bzeps' => [%w(eps.bz2 epsf.bz2 epsi.bz2), %w(), "EPS image (bzip-compressed)"],
1110
+ 'image/x-canon-cr2' => [%w(cr2), %w(image/tiff image/x-dcraw), "Canon CR2 raw image"],
1111
+ 'image/x-canon-crw' => [%w(crw), %w(image/x-dcraw), "Canon CRW raw image"],
1112
+ 'image/x-cmu-raster' => [%w(ras), %w(), "CMU raster image"],
1113
+ 'image/x-compressed-xcf' => [%w(xcf.bz2 xcf.gz), %w(), "compressed GIMP image"],
1114
+ 'image/x-dds' => [%w(dds), %w(), "DirectDraw surface"],
1115
+ 'image/x-emf' => [%w(emf), %w(), "EMF image"],
1116
+ 'image/x-eps' => [%w(eps epsf epsi), %w(application/postscript), "EPS image"],
1117
+ 'image/x-exr' => [%w(exr), %w(), "EXR image"],
1118
+ 'image/x-fuji-raf' => [%w(raf), %w(image/x-dcraw), "Fuji RAF raw image"],
1119
+ 'image/x-gzeps' => [%w(eps.gz epsf.gz epsi.gz), %w(), "EPS image (gzip-compressed)"],
1120
+ 'image/x-icns' => [%w(icns), %w(), "MacOS X icon"],
1121
+ 'image/x-iff' => [%w(iff), %w(), "IFF image"],
1122
+ 'image/x-ilbm' => [%w(ilbm), %w(), "ILBM image"],
1123
+ 'image/x-jng' => [%w(jng), %w(), "JNG image"],
1124
+ 'image/x-kodak-dcr' => [%w(dcr), %w(image/tiff image/x-dcraw), "Kodak DCR raw image"],
1125
+ 'image/x-kodak-k25' => [%w(k25), %w(image/tiff image/x-dcraw), "Kodak K25 raw image"],
1126
+ 'image/x-kodak-kdc' => [%w(kdc), %w(image/tiff image/x-dcraw), "Kodak KDC raw image"],
1127
+ 'image/x-lwo' => [%w(lwo lwob), %w(), "LightWave object"],
1128
+ 'image/x-lws' => [%w(lws), %w(), "LightWave scene"],
1129
+ 'image/x-macpaint' => [%w(pntg), %w(), "MacPaint Bitmap image"],
1130
+ 'image/x-minolta-mrw' => [%w(mrw), %w(image/x-dcraw), "Minolta MRW raw image"],
1131
+ 'image/x-msod' => [%w(msod), %w(), "Office drawing"],
1132
+ 'image/x-nikon-nef' => [%w(nef), %w(image/tiff image/x-dcraw), "Nikon NEF raw image"],
1133
+ 'image/x-olympus-orf' => [%w(orf), %w(image/x-dcraw), "Olympus ORF raw image"],
1134
+ 'image/x-panasonic-raw' => [%w(raw), %w(image/x-dcraw), "Panasonic raw image"],
1135
+ 'image/x-panasonic-raw2' => [%w(rw2), %w(image/x-dcraw), "Panasonic raw2 image"],
1136
+ 'image/x-pcx' => [%w(pcx), %w(), "PCX image"],
1137
+ 'image/x-pentax-pef' => [%w(pef), %w(image/tiff image/x-dcraw), "Pentax PEF raw image"],
1138
+ 'image/x-photo-cd' => [%w(pcd), %w(), "PCD image"],
1139
+ 'image/x-pict' => [%w(pict pict1 pict2), %w(), "Macintosh Quickdraw/PICT drawing"],
1140
+ 'image/x-portable-anymap' => [%w(pnm), %w(), "PNM image"],
1141
+ 'image/x-portable-bitmap' => [%w(pbm), %w(image/x-portable-anymap), "PBM image"],
1142
+ 'image/x-portable-graymap' => [%w(pgm), %w(image/x-portable-anymap), "PGM image"],
1143
+ 'image/x-portable-pixmap' => [%w(ppm), %w(image/x-portable-anymap), "PPM image"],
1144
+ 'image/x-quicktime' => [%w(qif qtif), %w(), "QuickTime image"],
1145
+ 'image/x-rgb' => [%w(rgb), %w(), "RGB image"],
1146
+ 'image/x-sgi' => [%w(sgi), %w(), "SGI image"],
1147
+ 'image/x-sigma-x3f' => [%w(x3f), %w(image/x-dcraw), "Sigma X3F raw image"],
1148
+ 'image/x-skencil' => [%w(sk sk1), %w(), "Skencil document"],
1149
+ 'image/x-sony-arw' => [%w(arw), %w(image/tiff image/x-dcraw), "Sony ARW raw image"],
1150
+ 'image/x-sony-sr2' => [%w(sr2), %w(image/tiff image/x-dcraw), "Sony SR2 raw image"],
1151
+ 'image/x-sony-srf' => [%w(srf), %w(image/tiff image/x-dcraw), "Sony SRF raw image"],
1152
+ 'image/x-sun-raster' => [%w(sun), %w(), "Sun raster image"],
1153
+ 'image/x-tga' => [%w(icb tga tpic vda vst), %w(), "TGA image"],
1154
+ 'image/x-win-bitmap' => [%w(cur), %w(), "Windows cursor"],
1155
+ 'image/x-wmf' => [%w(wmf), %w(), "WMF image"],
1156
+ 'image/x-xbitmap' => [%w(xbm), %w(), "XBM image"],
1157
+ 'image/x-xcf' => [%w(xcf), %w(), "GIMP image"],
1158
+ 'image/x-xfig' => [%w(fig), %w(), "XFig image"],
1159
+ 'image/x-xpixmap' => [%w(xpm), %w(), "XPM image"],
1160
+ 'image/x-xwindowdump' => [%w(xwd), %w(), "X window image"],
1161
+ 'message/rfc822' => [%w(eml), %w(text/plain), "email message"],
1162
+ 'model/vrml' => [%w(wrl), %w(text/plain), "VRML document"],
1163
+ 'text/cache-manifest' => [%w(manifest), %w(text/plain), "Web application cache manifest"],
1164
+ 'text/calendar' => [%w(ics vcs), %w(text/plain), "VCS/ICS calendar"],
1165
+ 'text/css' => [%w(css cssl), %w(text/x-csrc), "CSS stylesheet"],
1166
+ 'text/csv' => [%w(csv), %w(text/plain), "CSV document"],
1167
+ 'text/directory' => [%w(gcrd vcf vct), %w(text/plain), "electronic business card"],
1168
+ 'text/html' => [%w(htm html), %w(text/plain), "HTML document"],
1169
+ 'text/plain' => [%w(asc txt), %w(), "plain text document"],
1170
+ 'text/richtext' => [%w(rtx), %w(text/plain), "rich text document"],
1171
+ 'text/sgml' => [%w(sgm sgml), %w(text/plain), "SGML document"],
1172
+ 'text/spreadsheet' => [%w(slk sylk), %w(text/plain), "spreadsheet interchange document"],
1173
+ 'text/tab-separated-values' => [%w(tsv), %w(text/plain), "TSV document"],
1174
+ 'text/troff' => [%w(roff t tr), %w(text/plain), "Troff document"],
1175
+ 'text/vnd.graphviz' => [%w(dot gv), %w(), "Graphviz DOT graph"],
1176
+ 'text/vnd.rn-realtext' => [%w(rt), %w(), "RealText document"],
1177
+ 'text/vnd.sun.j2me.app-descriptor' => [%w(jad), %w(), "JAD document"],
1178
+ 'text/vnd.trolltech.linguist' => [%w(ts), %w(application/xml), "message catalog"],
1179
+ 'text/vnd.wap.wml' => [%w(wml), %w(application/xml), "WML document"],
1180
+ 'text/vnd.wap.wmlscript' => [%w(wmls), %w(), "WMLScript program"],
1181
+ 'text/x-adasrc' => [%w(adb ads), %w(text/plain), "Ada source code"],
1182
+ 'text/x-bibtex' => [%w(bib), %w(text/plain), "BibTeX document"],
1183
+ 'text/x-c++hdr' => [%w(h++ hh hp hpp hxx), %w(text/x-chdr), "C++ header"],
1184
+ 'text/x-c++src' => [%w(c c++ cc cpp cxx), %w(text/x-csrc), "C++ source code"],
1185
+ 'text/x-chdr' => [%w(h), %w(text/x-csrc), "C header"],
1186
+ 'text/x-cmake' => [%w(cmake), %w(text/plain), "CMake source code"],
1187
+ 'text/x-cobol' => [%w(cbl cob), %w(text/plain), "COBOL source file"],
1188
+ 'text/x-csharp' => [%w(cs), %w(text/x-csrc), "C# source code"],
1189
+ 'text/x-csrc' => [%w(c), %w(text/plain), "C source code"],
1190
+ 'text/x-dcl' => [%w(dcl), %w(text/plain), "DCL script"],
1191
+ 'text/x-dsl' => [%w(dsl), %w(text/plain), "DSSSL document"],
1192
+ 'text/x-dsrc' => [%w(d), %w(text/x-csrc), "D source code"],
1193
+ 'text/x-eiffel' => [%w(e eif), %w(text/plain), "Eiffel source code"],
1194
+ 'text/x-emacs-lisp' => [%w(el), %w(text/plain), "Emacs Lisp source code"],
1195
+ 'text/x-erlang' => [%w(erl), %w(text/plain), "Erlang source code"],
1196
+ 'text/x-fortran' => [%w(f f90 f95 for), %w(text/plain), "Fortran source code"],
1197
+ 'text/x-gettext-translation' => [%w(po), %w(text/plain), "translation file"],
1198
+ 'text/x-gettext-translation-template' => [%w(pot), %w(text/plain), "translation template"],
1199
+ 'text/x-go' => [%w(go), %w(text/plain), "Go source code"],
1200
+ 'text/x-google-video-pointer' => [%w(gvp), %w(), "Google Video Pointer"],
1201
+ 'text/x-haskell' => [%w(hs), %w(text/plain), "Haskell source code"],
1202
+ 'text/x-iMelody' => [%w(ime imy), %w(), "iMelody ringtone"],
1203
+ 'text/x-idl' => [%w(idl), %w(text/plain), "IDL document"],
1204
+ 'text/x-iptables' => [%w(iptables), %w(text/plain), "iptables configuration file"],
1205
+ 'text/x-java' => [%w(java), %w(text/x-csrc), "Java source code"],
1206
+ 'text/x-ldif' => [%w(ldif), %w(text/plain), "LDIF address book"],
1207
+ 'text/x-lilypond' => [%w(ly), %w(text/plain), "Lilypond music sheet"],
1208
+ 'text/x-literate-haskell' => [%w(lhs), %w(text/plain), "LHS source code"],
1209
+ 'text/x-log' => [%w(log), %w(text/plain), "application log"],
1210
+ 'text/x-lua' => [%w(lua), %w(application/x-executable text/plain), "Lua script"],
1211
+ 'text/x-matlab' => [%w(m), %w(text/plain), "MATLAB script/function"],
1212
+ 'text/x-microdvd' => [%w(sub), %w(text/plain), "MicroDVD subtitles"],
1213
+ 'text/x-moc' => [%w(moc), %w(text/plain), "Qt MOC file"],
1214
+ 'text/x-mof' => [%w(mof), %w(text/x-csrc), "Managed Object Format"],
1215
+ 'text/x-mpsub' => [%w(sub), %w(text/plain), "MPSub subtitles"],
1216
+ 'text/x-mrml' => [%w(mrl mrml), %w(), "MRML playlist"],
1217
+ 'text/x-ms-regedit' => [%w(reg), %w(text/plain), "Windows Registry extract"],
1218
+ 'text/x-mup' => [%w(mup not), %w(text/plain), "Mup publication"],
1219
+ 'text/x-nfo' => [%w(nfo), %w(text/x-readme), "NFO document"],
1220
+ 'text/x-objcsrc' => [%w(m), %w(text/x-csrc), "Objective-C source code"],
1221
+ 'text/x-ocaml' => [%w(ml mli), %w(), "OCaml source code"],
1222
+ 'text/x-ocl' => [%w(ocl), %w(text/plain), "OCL file"],
1223
+ 'text/x-ooc' => [%w(ooc), %w(text/x-csrc), "OOC source code"],
1224
+ 'text/x-opml+xml' => [%w(opml), %w(application/xml), "OPML syndication feed"],
1225
+ 'text/x-pascal' => [%w(p pas), %w(text/plain), "Pascal source code"],
1226
+ 'text/x-patch' => [%w(diff patch), %w(text/plain), "differences between files"],
1227
+ 'text/x-python' => [%w(py), %w(application/x-executable text/plain), "Python script"],
1228
+ 'text/x-rpm-spec' => [%w(spec), %w(text/plain), "RPM spec file"],
1229
+ 'text/x-scheme' => [%w(scm), %w(text/plain), "Scheme source code"],
1230
+ 'text/x-setext' => [%w(etx), %w(text/plain), "Setext document"],
1231
+ 'text/x-sql' => [%w(sql), %w(text/plain), "SQL code"],
1232
+ 'text/x-ssa' => [%w(ass ssa), %w(text/plain), "SSA subtitles"],
1233
+ 'text/x-subviewer' => [%w(sub), %w(text/plain), "SubViewer subtitles"],
1234
+ 'text/x-svhdr' => [%w(svh), %w(text/x-verilog), "SystemVerilog header"],
1235
+ 'text/x-svsrc' => [%w(sv), %w(text/x-verilog), "SystemVerilog source code"],
1236
+ 'text/x-tcl' => [%w(tcl tk), %w(text/plain), "Tcl script"],
1237
+ 'text/x-tex' => [%w(cls dtx ins latex ltx sty tex), %w(text/plain), "TeX document"],
1238
+ 'text/x-texinfo' => [%w(texi texinfo), %w(text/plain), "TeXInfo document"],
1239
+ 'text/x-troff-me' => [%w(me), %w(text/plain), "Troff ME input document"],
1240
+ 'text/x-troff-mm' => [%w(mm), %w(text/plain), "Troff MM input document"],
1241
+ 'text/x-troff-ms' => [%w(ms), %w(text/plain), "Troff MS input document"],
1242
+ 'text/x-txt2tags' => [%w(t2t), %w(text/plain), "txt2tags document"],
1243
+ 'text/x-uil' => [%w(uil), %w(text/plain), "X-Motif UIL table"],
1244
+ 'text/x-uri' => [%w(uri url), %w(text/plain), "resource location"],
1245
+ 'text/x-vala' => [%w(vala vapi), %w(text/x-csrc), "Vala source code"],
1246
+ 'text/x-verilog' => [%w(v), %w(text/plain), "Verilog source code"],
1247
+ 'text/x-vhdl' => [%w(vhd vhdl), %w(text/plain), "VHDL source code"],
1248
+ 'text/x-xmi' => [%w(xmi), %w(application/xml), "XMI file"],
1249
+ 'text/x-xslfo' => [%w(fo xslfo), %w(application/xml), "XSL FO file"],
1250
+ 'video/3gpp' => [%w(3ga 3gp 3gpp), %w(video/mp4), "3GPP multimedia file"],
1251
+ 'video/3gpp2' => [%w(3g2 3gp2 3gpp2), %w(video/mp4), "3GPP2 multimedia file"],
1252
+ 'video/annodex' => [%w(axv), %w(application/annodex), "Annodex Video"],
1253
+ 'video/dv' => [%w(dv), %w(), "DV video"],
1254
+ 'video/mp2t' => [%w(bdm bdmv clpi cpi m2t m2ts mpl mpls mts ts), %w(), "MPEG-2 transport stream"],
1255
+ 'video/mp4' => [%w(f4v m4v mp4), %w(), "MPEG-4 video"],
1256
+ 'video/mpeg' => [%w(mp2 mpe mpeg mpg vob), %w(), "MPEG video"],
1257
+ 'video/ogg' => [%w(ogv), %w(application/ogg), "Ogg Video"],
1258
+ 'video/quicktime' => [%w(moov mov qt qtvr), %w(), "QuickTime video"],
1259
+ 'video/vivo' => [%w(viv vivo), %w(), "Vivo video"],
1260
+ 'video/vnd.rn-realvideo' => [%w(rv rvx), %w(), "RealVideo document"],
1261
+ 'video/webm' => [%w(webm), %w(), "WebM video"],
1262
+ 'video/x-flic' => [%w(flc fli), %w(), "FLIC animation"],
1263
+ 'video/x-flv' => [%w(flv), %w(), "Flash video"],
1264
+ 'video/x-javafx' => [%w(fxm), %w(video/x-flv), "JavaFX video"],
1265
+ 'video/x-matroska' => [%w(mkv), %w(application/x-matroska), "Matroska video"],
1266
+ 'video/x-mng' => [%w(mng), %w(), "MNG animation"],
1267
+ 'video/x-ms-asf' => [%w(asf), %w(), "ASF video"],
1268
+ 'video/x-ms-wmv' => [%w(wmv), %w(video/x-ms-asf), "Windows Media video"],
1269
+ 'video/x-msvideo' => [%w(avi divx), %w(), "AVI video"],
1270
+ 'video/x-nsv' => [%w(nsv), %w(), "NullSoft video"],
1271
+ 'video/x-ogm+ogg' => [%w(ogm), %w(video/ogg), "OGM video"],
1272
+ 'video/x-sgi-movie' => [%w(movie), %w(), "SGI video"],
1273
+ 'video/x-theora+ogg' => [%w(ogg), %w(video/ogg), "Ogg Theora video"],
1274
+ 'x-epoc/x-sisx-app' => [%w(sisx), %w(), "SISX package"],
1275
+ }
1276
+ MAGIC = [
1277
+ ['application/vnd.stardivision.writer', [[2089, "StarWriter"]]],
1278
+ ['application/docbook+xml', [[0, "<?xml", [[0..100, "-//OASIS//DTD DocBook XML"], [0..100, "-//KDE//DTD DocBook XML"]]]]],
1279
+ ['image/x-eps', [[0, "%!", [[15, "EPS"]]], [0, "\x04%!", [[16, "EPS"]]]]],
1280
+ ['image/svg+xml', [[0..256, "<!DOCTYPE svg"], [0..256, "<svg"]]],
1281
+ ['application/x-mozilla-bookmarks', [[0..64, "<!DOCTYPE NETSCAPE-Bookmark-file-1>"]]],
1282
+ ['image/x-niff', [[0, "IIN1"]]],
1283
+ ['application/prs.plucker', [[60, "DataPlkr"]]],
1284
+ ['application/x-fictionbook+xml', [[0..256, "<FictionBook"]]],
1285
+ ['application/vnd.corel-draw', []],
1286
+ ['image/x-kodak-kdc', [[242, "EASTMAN KODAK COMPANY"]]],
1287
+ ['application/x-xliff', [[0..256, "<xliff"]]],
1288
+ ['audio/x-vorbis+ogg', [[0, "OggS", [[28, "\x01vorbis"]]]]],
1289
+ ['audio/x-flac+ogg', [[0, "OggS", [[28, "fLaC"]]], [0, "OggS", [[28, "\x7FFLAC"]]]]],
1290
+ ['application/x-php', [[0..64, "<?php"]]],
1291
+ ['video/x-ogm+ogg', [[0, "OggS", [[29, "video"]]]]],
1292
+ ['video/x-theora+ogg', [[0, "OggS", [[28, "\x80theora"]]]]],
1293
+ ['application/x-pak', [[0, "PACK"]]],
1294
+ ['audio/x-speex+ogg', [[0, "OggS", [[28, "Speex "]]]]],
1295
+ ['text/x-opml+xml', [[0..256, "<opml "]]],
1296
+ ['application/atom+xml', [[0..256, "<feed "]]],
1297
+ ['application/rss+xml', [[0..256, "<rss "], [0..256, "<RSS "]]],
1298
+ ['application/vnd.apple.mpegurl', [[0, "#EXTM3U", [[0..128, "#EXT-X-TARGETDURATION"], [0..128, "#EXT-X-STREAM-INF"]]]]],
1299
+ ['application/x-kpresenter', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-kpresenter\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-kpresenter"]]]]]]],
1300
+ ['text/x-txt2tags', [[0, "%!postproc"], [0, "%!encoding"]]],
1301
+ ['application/x-quicktime-media-link', [[0, "<?xml", [[0..64, "<?quicktime"]]], [0, "RTSPtext"], [0, "rtsptext"], [0, "SMILtext"]]],
1302
+ ['application/x-kword', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-kword\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-kword"]]]]]]],
1303
+ ['application/x-kspread', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-kspread\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-kspread"]]]]]]],
1304
+ ['application/x-krita', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-krita\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-krita"]]]]]]],
1305
+ ['application/vnd.ms-wpl', [[0..256, "<?wpl"]]],
1306
+ ['application/msword', [[0, "1\xBE\x00\x00"], [0, "PO^Q`"], [0, "\xFE7\x00#"], [0, "\xDB\xA5-\x00\x00\x00"], [2112, "MSWordDoc"], [2108, "MSWordDoc"], [2112, "Microsoft Word document data"], [546, "bjbj"], [546, "jbjb"]]],
1307
+ ['application/x-kontour', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-kontour\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-kontour"]]]]]]],
1308
+ ['application/x-karbon', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-karbon\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-karbon"]]]]]]],
1309
+ ['application/x-font-type1', [[0, "LWFN"], [65, "LWFN"], [0, "%!PS-AdobeFont-1."], [6, "%!PS-AdobeFont-1."], [0, "%!FontType1-1."], [6, "%!FontType1-1."]]],
1310
+ ['application/x-killustrator', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-killustrator\u0004\u0006"]]]]]]],
1311
+ ['application/x-kformula', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-kformula\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-kformula"]]]]]]],
1312
+ ['application/x-kchart', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-kchart\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-kchart"]]]]]]],
1313
+ ['application/x-kivio', [[0, "\x1F\x8B", [[10, "KOffice", [[18, "application/x-kivio\u0004\u0006"]]]]], [0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/x-kivio"]]]]]]],
1314
+ ['application/smil', [[0..256, "<smil"]]],
1315
+ ['audio/x-ms-asx', [[0, "ASF "], [0..64, "<ASX"], [0..64, "<asx"], [0..64, "<Asx"]]],
1316
+ ['image/dpx', [[0, "SDPX"]]],
1317
+ ['video/x-flic', [[0, "\x11\xAF"], [0, "\x12\xAF"]]],
1318
+ ['image/x-quicktime', [[4, "idat"]]],
1319
+ ['video/quicktime', [[12, "mdat"], [4, "mdat"], [4, "moov"], [4, "ftypqt"]]],
1320
+ ['application/vnd.oasis.opendocument.text', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.text"]]]]]]],
1321
+ ['application/vnd.oasis.opendocument.text-template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.text-template"]]]]]]],
1322
+ ['application/vnd.oasis.opendocument.text-web', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.text-web"]]]]]]],
1323
+ ['application/vnd.oasis.opendocument.text-master', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.text-master"]]]]]]],
1324
+ ['application/vnd.oasis.opendocument.graphics', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.graphics"]]]]]]],
1325
+ ['application/vnd.oasis.opendocument.graphics-template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.graphics-template"]]]]]]],
1326
+ ['application/vnd.oasis.opendocument.presentation', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.presentation"]]]]]]],
1327
+ ['application/vnd.oasis.opendocument.presentation-template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.presentation-template"]]]]]]],
1328
+ ['application/vnd.oasis.opendocument.spreadsheet', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.spreadsheet"]]]]]]],
1329
+ ['application/vnd.oasis.opendocument.spreadsheet-template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.spreadsheet-template"]]]]]]],
1330
+ ['application/vnd.oasis.opendocument.chart', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.chart"]]]]]]],
1331
+ ['application/vnd.oasis.opendocument.chart-template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.chart-template"]]]]]]],
1332
+ ['application/vnd.oasis.opendocument.formula', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.formula"]]]]]]],
1333
+ ['application/vnd.oasis.opendocument.formula-template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.formula-template"]]]]]]],
1334
+ ['application/vnd.oasis.opendocument.image', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.oasis.opendocument.image"]]]]]]],
1335
+ ['application/vnd.symbian.install', [[8, "\x19\x04\x00\x10"]]],
1336
+ ['x-epoc/x-sisx-app', [[0, "z\x1A \x10"]]],
1337
+ ['application/vnd.wordperfect', [[1, "WPC"]]],
1338
+ ['application/x-spss-por', [[40, "ASCII SPSS PORT FILE"]]],
1339
+ ['application/x-spss-sav', [[0, "$FL2"]]],
1340
+ ['application/x-xbel', [[0..256, "<!DOCTYPE xbel"]]],
1341
+ ['application/x-7z-compressed', [[0, "7z\xBC\xAF'\x1C"]]],
1342
+ ['application/x-abiword', [[0..256, "<abiword"], [0..256, "<!DOCTYPE abiword"]]],
1343
+ ['application/x-aportisdoc', [[60, "TEXtREAd"], [60, "TEXtTlDc"]]],
1344
+ ['application/x-applix-spreadsheet', [[0, "*BEGIN SPREADSHEETS"], [0, "*BEGIN", [[7, "SPREADSHEETS"]]]]],
1345
+ ['application/x-applix-word', [[0, "*BEGIN", [[7, "WORDS"]]]]],
1346
+ ['application/x-arc', []],
1347
+ ['video/mpeg', [[0, "G?\xFF\x10"], [0, "\x00\x00\x01\xB3"], [0, "\x00\x00\x01\xBA"]]],
1348
+ ['application/x-arj', [[0, "`\xEA"]]],
1349
+ ['application/x-awk', [[0, "#!/bin/gawk"], [0, "#! /bin/gawk"], [0, "#!/usr/bin/gawk"], [0, "#! /usr/bin/gawk"], [0, "#!/usr/local/bin/gawk"], [0, "#! /usr/local/bin/gawk"], [0, "#!/bin/awk"], [0, "#! /bin/awk"], [0, "#!/usr/bin/awk"], [0, "#! /usr/bin/awk"]]],
1350
+ ['application/x-bittorrent', [[0, "d8:announce"]]],
1351
+ ['application/x-blender', [[0, "BLENDER"]]],
1352
+ ['application/x-bzip', [[0, "BZh"]]],
1353
+ ['application/x-lrzip', [[0, "LRZI"]]],
1354
+ ['application/x-cdrdao-toc', [[0, "CD_ROM\n"], [0, "CD_DA\n"], [0, "CD_ROM_XA\n"], [0, "CD_TEXT "], [0, "CATALOG \"", [[22, "\""]]]]],
1355
+ ['application/x-chess-pgn', [[0, "[Event "]]],
1356
+ ['application/x-compress', [[0, "\x1F\x9D"]]],
1357
+ ['application/x-core', [[0, "\x7FELF", [[5, "\x01", [[16, "\x04\x00"]]]]], [0, "\x7FELF", [[5, "\x02", [[16, "\x00\x04"]]]]], [0, "Core\u0001"], [0, "Core\u0002"]]],
1358
+ ['application/x-cpio', [[0, "\xC7q"], [0, "070701"], [0, "070702"], [0, "q\xC7"]]],
1359
+ ['video/mp2t', []],
1360
+ ['application/x-deb', [[0, "!<arch>", [[8, "debian"]]]]],
1361
+ ['video/dv', []],
1362
+ ['application/x-desktop', [[0..32, "[Desktop Entry]"], [0, "[Desktop Action"], [0, "[KDE Desktop Entry]"], [0, "# Config File"], [0, "# KDE Config File"]]],
1363
+ ['video/x-ms-asf', [[0, "0&\xB2u"], [0, "[Reference]"]]],
1364
+ ['application/x-dia-diagram', [[5..100, "<dia:"]]],
1365
+ ['application/x-dia-shape', [[5..100, "<shape"]]],
1366
+ ['application/x-dvi', [[0, "\xF7\x02"]]],
1367
+ ['text/xmcd', [[0, "# xmcd"]]],
1368
+ ['application/x-fluid', [[0, "# data file for the Fltk"], [0, "version"], [0, "header_name"], [0, "code_name"]]],
1369
+ ['application/x-netshow-channel', [[0, "[Address]"]]],
1370
+ ['application/x-font-bdf', [[0, "STARTFONT "]]],
1371
+ ['application/x-font-dos', [[0, "\xFFFON"], [7, "\x00EGA"], [7, "\x00VID"]]],
1372
+ ['application/x-font-framemaker', [[0, "<MakerScreenFont"]]],
1373
+ ['application/x-font-libgrx', [[0, "\x14\x02Y\x19"]]],
1374
+ ['application/x-font-linux-psf', [[0, "6\x04"]]],
1375
+ ['application/x-font-pcf', [[0, "\x01fcp"]]],
1376
+ ['application/x-font-otf', [[0, "OTTO"]]],
1377
+ ['application/x-font-speedo', [[0, "D1.0\r"]]],
1378
+ ['application/x-font-sunos-news', [[0, "StartFont"], [0, "\x13z)"], [8, "\x13z+"]]],
1379
+ ['application/x-font-tex', [[0, "\xF7\x83"], [0, "\xF7Y"], [0, "\xF7\xCA"]]],
1380
+ ['application/x-font-tex-tfm', [[2, "\x00\x11"], [2, "\x00\x12"]]],
1381
+ ['application/x-font-ttf', [[0, "FFIL"], [65, "FFIL"], [0, "\x00\x01\x00\x00\x00"]]],
1382
+ ['application/x-font-ttx', [[0..256, "<ttFont sfntVersion=\"\\x00\\x01\\x00\\x00\" ttLibVersion=\""]]],
1383
+ ['application/x-font-vfont', [[0, "FONT"]]],
1384
+ ['application/x-frame', [[0, "<MakerFile"], [0, "<MIFFile"], [0, "<MakerDictionary"], [0, "<MakerScreenFon"], [0, "<MML"], [0, "<Book"], [0, "<Maker"]]],
1385
+ ['application/x-gdbm', [[0, "\x13W\x9A\xCE"], [0, "\xCE\x9AW\x13"], [0, "GDBM"]]],
1386
+ ['application/x-glade', [[0..256, "<glade-interface"]]],
1387
+ ['application/x-gmc-link', [[0..32, "URL:"]]],
1388
+ ['application/x-gnumeric', [[0..64, "gmr:Workbook"], [0..64, "gnm:Workbook"]]],
1389
+ ['application/x-gtktalog', [[4, "gtktalog "]]],
1390
+ ['application/x-gzip', [[0, "\x1F\x8B"]]],
1391
+ ['application/x-hdf', [[0, "\x89HDF\r\n\x1A\n"], [0, "\x0E\x03\x13\x01"]]],
1392
+ ['application/x-ipod-firmware', [[0, "S T O P"]]],
1393
+ ['application/x-java', [[0, "\xCA\xFE\xBA\xBE"]]],
1394
+ ['application/x-java-jnlp-file', [[0..256, "<jnlp"]]],
1395
+ ['application/x-java-keystore', [[0, "\xED\xFE\xED\xFE"]]],
1396
+ ['application/x-java-jce-keystore', [[0, "\xCE\xCE\xCE\xCE"]]],
1397
+ ['application/x-java-pack200', [[0, "\xCA\xFE\xD0\r"]]],
1398
+ ['video/x-msvideo', [[0, "RIFF", [[8, "AVI "]]]]],
1399
+ ['video/x-nsv', [[0, "NSVf"]]],
1400
+ ['application/sdp', [[0, "v=", [[0..256, "s="]]]]],
1401
+ ['video/x-sgi-movie', [[0, "MOVI"]]],
1402
+ ['application/vnd.ms-tnef', [[0, "x\x9F>\""]]],
1403
+ ['application/gnunet-directory', [[0, "\x89GND\r\n\x1A\n"]]],
1404
+ ['application/vnd.ms-excel', [[2080, "Microsoft Excel 5.0 Worksheet"]]],
1405
+ ['application/vnd.ms-cab-compressed', [[0, "MSCF\u0000\u0000\u0000\u0000"]]],
1406
+ ['application/vnd.ms-access', [[0, "\x00\x01\x00\x00Standard Jet DB"]]],
1407
+ ['application/x-kspread-crypt', [[0, "\r\x1A'\x02"]]],
1408
+ ['application/x-ksysv-package', [[4, "KSysV", [[15, "\x01"]]]]],
1409
+ ['application/vnd.lotus-1-2-3', [[0, "\x00\x00\x02\x00\x06\x04\x06\x00\b\x00\x00\x00\x00\x00"]]],
1410
+ ['application/x-kword-crypt', [[0, "\r\x1A'\x01"]]],
1411
+ ['application/x-lha', [[2, "-lh -"], [2, "-lh0-"], [2, "-lh1-"], [2, "-lh2-"], [2, "-lh3-"], [2, "-lh4-"], [2, "-lh5-"], [2, "-lh40-"], [2, "-lhd-"], [2, "-lz4-"], [2, "-lz5-"], [2, "-lzs-"]]],
1412
+ ['application/xslt+xml', [[0..256, "<xsl:stylesheet"]]],
1413
+ ['application/x-lyx', [[0, "#LyX"]]],
1414
+ ['application/x-lzip', [[0, "LZIP"]]],
1415
+ ['application/x-lzop', [[0, "\x89LZO\x00\r\n\x1A\n"]]],
1416
+ ['application/x-macbinary', [[102, "mBIN"]]],
1417
+ ['application/x-matroska', [[0, "\x1AE\xDF\xA3", [[5..65, "B\x82", [[8..75, "matroska"]]]]]]],
1418
+ ['video/webm', [[0, "\x1AE\xDF\xA3", [[5..65, "B\x82", [[8..75, "webm"]]]]]]],
1419
+ ['application/mxf', [[0..256, "\x06\x0E+4\x02\x05\x01\x01\r\x01\x02\x01\x01\x02"]]],
1420
+ ['application/vnd.emusic-emusic_package', [[0, "nF7YLao"]]],
1421
+ ['application/x-ms-dos-executable', [[0, "MZ"]]],
1422
+ ['application/x-mswinurl', [[1, "InternetShortcut"], [1, "DEFAULT", [[11, "BASEURL="]]]]],
1423
+ ['application/x-nautilus-link', [[0..32, "<nautilus_object nautilus_link"]]],
1424
+ ['application/x-object', [[0, "\x7FELF", [[5, "\x01", [[16, "\x01\x00"]]]]], [0, "\x7FELF", [[5, "\x02", [[16, "\x00\x01"]]]]]]],
1425
+ ['application/annodex', [[0, "OggS", [[28, "fishead\u0000", [[56..512, "CMML\u0000\u0000\u0000\u0000"]]]]]]],
1426
+ ['video/annodex', [[0, "OggS", [[28, "fishead\u0000", [[56..512, "CMML\u0000\u0000\u0000\u0000"]]]]]]],
1427
+ ['audio/annodex', [[0, "OggS", [[28, "fishead\u0000", [[56..512, "CMML\u0000\u0000\u0000\u0000"]]]]]]],
1428
+ ['application/ogg', [[0, "OggS"]]],
1429
+ ['audio/ogg', [[0, "OggS"]]],
1430
+ ['video/ogg', [[0, "OggS"]]],
1431
+ ['application/x-go-sgf', [[0, "(;FF[3]"], [0, "(;FF[4]"]]],
1432
+ ['application/x-t602', [[0, "@CT 0"], [0, "@CT 1"], [0, "@CT 2"]]],
1433
+ ['video/x-flv', [[0, "FLV"]]],
1434
+ ['audio/x-speex', [[0, "Speex"]]],
1435
+ ['application/x-gedcom', [[0, "0 HEAD"]]],
1436
+ ['application/x-cisco-vpn-settings', [[0, "[main]", [[0..256, "AuthType="]]]]],
1437
+ ['application/x-ole-storage', [[0, "\xD0\xCF\x11\xE0\xA1\xB1\x1A\xE1"], [0, "\xD0\xCF\x11\xE0"]]],
1438
+ ['application/x-oleo', [[31, "Oleo"]]],
1439
+ ['application/vnd.iccprofile', [[36, "acsp"]]],
1440
+ ['application/x-par2', [[0, "PAR2"]]],
1441
+ ['application/x-pef-executable', [[0, "Joy!"]]],
1442
+ ['application/x-perl', [[0, "eval \"exec /usr/local/bin/perl"], [1..16, "/bin/perl"], [1..16, "/bin/env perl"]]],
1443
+ ['application/rtf', [[0, "{\\rtf"]]],
1444
+ ['application/x-pocket-word', [[0, "{\\pwi"]]],
1445
+ ['application/x-python-bytecode', [[0, "\x99N\r\n"]]],
1446
+ ['application/epub+zip', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/epub+zip"]]]]]]],
1447
+ ['application/x-rar', [[0, "Rar!"]]],
1448
+ ['text/x-iptables', [[0..256, "/etc/sysconfig/iptables"], [0..256, "*filter", [[0..256, ":INPUT", [[0..256, ":FORWARD", [[0..256, ":OUTPUT"]]]]]]], [0..256, "-A INPUT", [[0..256, "-A FORWARD", [[0..256, "-A OUTPUT"]]]]], [0..256, "-P INPUT", [[0..256, "-P FORWARD", [[0..256, "-P OUTPUT"]]]]]]],
1449
+ ['application/x-alz', [[0, "ALZ"]]],
1450
+ ['application/x-rpm', [[0, "\xED\xAB\xEE\xDB"]]],
1451
+ ['text/x-tex', [[1, "documentclass"]]],
1452
+ ['application/x-sc', [[38, "Spreadsheet"]]],
1453
+ ['application/x-sharedlib', [[0, "\x7FELF", [[5, "\x01", [[16, "\x03\x00"]]]]], [0, "\x7FELF", [[5, "\x02", [[16, "\x00\x03"]]]]], [0, "\x83\x01"]]],
1454
+ ['application/x-shellscript', [[10, "# This is a shell archive"], [1..16, "/bin/bash"], [1..16, "/bin/nawk"], [1..16, "/bin/zsh"], [1..16, "/bin/sh"], [1..16, "/bin/ksh"], [0, "#!/usr/bin/env sh"], [0, "#!/usr/bin/env bash"], [0, "#!/usr/bin/env zsh"], [0, "#!/usr/bin/env ksh"]]],
1455
+ ['application/x-shockwave-flash', [[0, "FWS"], [0, "CWS"]]],
1456
+ ['application/x-shorten', [[0, "ajkg"]]],
1457
+ ['image/x-skencil', [[0, "##Sketch"]]],
1458
+ ['application/x-stuffit', [[0, "StuffIt "], [0, "SIT!"]]],
1459
+ ['application/x-subrip', [[0, "1", [[0..256, " --> "]]]]],
1460
+ ['application/x-sami', [[0..256, "<SAMI>"]]],
1461
+ ['text/x-microdvd', [[0, "{1}"], [0, "{0}"], [0..6, "}{"]]],
1462
+ ['text/x-mpsub', [[0..256, "FORMAT="]]],
1463
+ ['text/x-ssa', [[0..256, "[Script Info]"], [0..256, "Dialogue: "]]],
1464
+ ['text/x-subviewer', [[0, "[INFORMATION]"]]],
1465
+ ['text/x-iMelody', [[0, "BEGIN:IMELODY"]]],
1466
+ ['application/x-smaf', [[0, "MMMD"]]],
1467
+ ['text/x-mrml', [[0, "<mrml "]]],
1468
+ ['audio/x-xmf', [[0, "XMF_"], [0, "XMF_2.00\x00\x00\x00\x02"]]],
1469
+ ['application/x-tar', [[257, "ustar\u0000"], [257, "ustar \u0000"]]],
1470
+ ['application/x-tgif', [[0, "%TGIF"]]],
1471
+ ['text/troff', [[0, ".\\\""], [0, "'\\\""], [0, "'.\\\""], [0, "\\\""]]],
1472
+ ['application/x-xz', [[0, "\xFD7zXZ\x00"]]],
1473
+ ['application/x-zoo', [[20, "\xDC\xA7\xC4\xFD"]]],
1474
+ ['text/x-rpm-spec', [[0, "Summary: "], [0, "%define "]]],
1475
+ ['text/x-lua', [[0, "/bin/lua"], [0, "/bin/env lua"]]],
1476
+ ['audio/ac3', [[0, "\vw"]]],
1477
+ ['audio/AMR', [[0, "#!AMR\n"], [0, "#!AMR_MC1.0\n"]]],
1478
+ ['audio/AMR-WB', [[0, "#!AMR-WB\n"], [0, "#!AMR-WB_MC1.0\n"]]],
1479
+ ['text/x-python', [[0, "#!/bin/python"], [0, "#! /bin/python"], [0, "eval \"exec /bin/python"], [0, "#!/usr/bin/python"], [0, "#! /usr/bin/python"], [0, "eval \"exec /usr/bin/python"], [0, "#!/usr/local/bin/python"], [0, "#! /usr/local/bin/python"], [0, "eval \"exec /usr/local/bin/python"], [1..16, "/bin/env python"]]],
1480
+ ['audio/prs.sid', [[0, "PSID"]]],
1481
+ ['audio/x-adpcm', [[0, ".snd", [[12, "\x00\x00\x00\x17"]]], [0, ".sd\x00", [[12, "\x01\x00\x00\x00"], [12, "\x02\x00\x00\x00"], [12, "\x03\x00\x00\x00"], [12, "\x04\x00\x00\x00"], [12, "\x05\x00\x00\x00"], [12, "\x06\x00\x00\x00"], [12, "\a\x00\x00\x00"], [12, "\x17\x00\x00\x00"]]]]],
1482
+ ['audio/x-aifc', [[8, "AIFC"]]],
1483
+ ['audio/x-aiff', [[8, "AIFF"], [8, "AIFC"], [8, "8SVX"]]],
1484
+ ['audio/x-ape', [[0, "MAC "]]],
1485
+ ['audio/x-it', [[0, "IMPM"]]],
1486
+ ['audio/flac', [[0, "fLaC"]]],
1487
+ ['text/x-google-video-pointer', [[0, "#.download.the.free.Google.Video.Player"], [0, "# download the free Google Video Player"]]],
1488
+ ['audio/x-wavpack-correction', [[0, "wvpk"]]],
1489
+ ['audio/midi', [[0, "MThd"]]],
1490
+ ['audio/x-mo3', [[0, "MO3"]]],
1491
+ ['audio/mp4', [[4, "ftypM4A"]]],
1492
+ ['video/mp4', [[4, "ftypisom"], [4, "ftypmp42"], [4, "ftypMSNV"], [4, "ftypM4V "], [4, "ftypf4v "]]],
1493
+ ['audio/x-m4b', [[4, "ftypM4B"]]],
1494
+ ['video/3gpp', [[4, "ftyp3ge"], [4, "ftyp3gg"], [4, "ftyp3gp"], [4, "ftyp3gs"]]],
1495
+ ['video/3gpp2', [[4, "ftyp3g2"]]],
1496
+ ['audio/mpeg', [[0, "\x00\x00\xFF\xFB"], [0, "ID3"]]],
1497
+ ['audio/x-mpegurl', [[0, "#EXTM3U"]]],
1498
+ ['application/postscript', [[0, "\x04%!"], [0, "%!"]]],
1499
+ ['application/pgp-signature', [[0, "-----BEGIN PGP SIGNED MESSAGE-----"], [0, "-----BEGIN PGP SIGNATURE-----"]]],
1500
+ ['audio/x-psf', [[0, "PSF"]]],
1501
+ ['audio/x-musepack', [[0, "MP+"]]],
1502
+ ['application/vnd.rn-realmedia', [[0, ".RMF"]]],
1503
+ ['text/x-patch', [[0, "diff\t"], [0, "diff "], [0, "***\t"], [0, "*** "], [0, "=== "], [0, "--- "], [0, "Only in\t"], [0, "Only in "], [0, "Common subdirectories: "], [0, "Index:"]]],
1504
+ ['audio/x-s3m', [[44, "SCRM"]]],
1505
+ ['audio/x-scpls', [[0, "[playlist]"], [0, "[Playlist]"], [0, "[PLAYLIST]"]]],
1506
+ ['text/x-matlab', [[0, "function"]]],
1507
+ ['audio/x-wav', [[8, "WAVE"], [8, "WAV "]]],
1508
+ ['audio/x-xi', [[0, "Extended Intrument:"]]],
1509
+ ['audio/x-xm', [[0, "Extended Module:"]]],
1510
+ ['audio/x-tta', [[0, "TTA1"]]],
1511
+ ['image/bmp', [[0, "BM", [[14, "\f"], [14, "@"], [14, "("]]]]],
1512
+ ['image/gif', [[0, "GIF8"]]],
1513
+ ['image/jpeg', [[0, "\xFF\xD8\xFF"], [0, "\xFF\xD8"]]],
1514
+ ['image/jp2', [[4, "jP"], [0, "\xFFO\xFFQ\x00"], [3, "\fjP "]]],
1515
+ ['image/openraster', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "image/openraster"]]]]]]],
1516
+ ['image/x-dds', [[0, "DDS"]]],
1517
+ ['image/x-xcursor', [[0, "Xcur"]]],
1518
+ ['image/x-exr', [[0, "v/1\x01"]]],
1519
+ ['image/x-canon-crw', [[0, "II\u001A\u0000\u0000\u0000HEAPCCDR"]]],
1520
+ ['image/x-fuji-raf', [[0, "FUJIFILMCCD-RAW "]]],
1521
+ ['application/pgp-keys', [[0, "-----BEGIN PGP PUBLIC KEY BLOCK-----"], [0, "-----BEGIN PGP PRIVATE KEY BLOCK-----"], [0, "\x95\x01"], [0, "\x95\x00"], [0, "\x99\x00"], [0, "\x99\x01"]]],
1522
+ ['image/x-minolta-mrw', [[0, "\x00MRM"]]],
1523
+ ['image/x-olympus-orf', [[0, "IIRO\b\u0000\u0000\u0000"]]],
1524
+ ['image/x-panasonic-raw', [[0, "IIU\u0000\b\u0000\u0000\u0000"]]],
1525
+ ['image/x-panasonic-raw2', [[0, "IIU\u0000\u0018\u0000\u0000\u0000"]]],
1526
+ ['image/x-sigma-x3f', [[0, "FOVb"]]],
1527
+ ['image/png', [[0, "\x89PNG"]]],
1528
+ ['application/pgp-encrypted', [[0, "-----BEGIN PGP MESSAGE-----"]]],
1529
+ ['image/tiff', [[0, "MM\u0000*"], [0, "II*\u0000"]]],
1530
+ ['image/vnd.dxf', [[0..64, "\nHEADER\n"], [0..64, "\r\nHEADER\r\n"]]],
1531
+ ['image/vnd.ms-modi', [[0, "EP*\x00"]]],
1532
+ ['image/x-applix-graphics', [[0, "*BEGIN", [[7, "GRAPHICS"]]]]],
1533
+ ['application/dicom', [[128, "DICM"]]],
1534
+ ['audio/x-iriver-pla', [[4, "iriver UMS PLA"]]],
1535
+ ['image/x-dib', [[0, "(\x00\x00\x00"]]],
1536
+ ['image/vnd.djvu', [[0, "AT&TFORM", [[12, "DJVM"], [12, "DJVU"]]], [0, "FORM", [[8, "DJVM"], [8, "DJVU"]]]]],
1537
+ ['application/x-hwp', [[0, "HWP Document File"]]],
1538
+ ['application/xspf+xml', [[0..64, "<playlist version=\"1"]]],
1539
+ ['image/fits', [[0, "SIMPLE ="]]],
1540
+ ['image/x-fpx', [[0, "FPix"]]],
1541
+ ['image/vnd.microsoft.icon', [[0, "\x00\x00\x01\x00", [[5, "\x00"]]]]],
1542
+ ['image/x-icns', [[0, "icns"]]],
1543
+ ['application/pdf', [[0..1024, "%PDF-"]]],
1544
+ ['image/x-pcx', [[0, "\n", [[1, "\x00"], [1, "\x02"], [1, "\x03"], [1, "\x05"]]]]],
1545
+ ['image/x-portable-bitmap', [[0, "P1", [[2, "\n", [[3, "#"]]]]], [0, "P4", [[2, "\n", [[3, "#"]]]]]]],
1546
+ ['image/x-portable-graymap', [[0, "P2", [[2, "\n", [[3, "#"]]]]], [0, "P5", [[2, "\n", [[3, "#"]]]]]]],
1547
+ ['image/x-portable-pixmap', [[0, "P3", [[2, "\n", [[3, "#"]]]]], [0, "P6", [[2, "\n", [[3, "#"]]]]]]],
1548
+ ['image/vnd.adobe.photoshop', []],
1549
+ ['image/x-sun-raster', [[0, "Y\xA6j\x95"]]],
1550
+ ['text/x-mup', [[0, "//!Mup"]]],
1551
+ ['image/x-win-bitmap', [[0, "\x00\x00\x02\x00", [[5, "\x00"]]]]],
1552
+ ['application/x-navi-animation', [[0, "RIFF", [[8, "ACON"]]]]],
1553
+ ['image/x-emf', [[0, "\x01\x00\x00\x00", [[40, " EMF", [[44, "\x00\x00\x01\x00", [[58, "\x00\x00"]]]]]]]]],
1554
+ ['image/x-wmf', [[0, "\xD7\xCD\xC6\x9A", [[22, "\x01\x00", [[24, "\t\x00"]]]]], [0, "\x01\x00", [[2, "\t\x00"]]]]],
1555
+ ['image/x-xcf', [[0, "gimp xcf file"]]],
1556
+ ['image/x-xfig', [[0, "#FIG"]]],
1557
+ ['image/x-xpixmap', [[0, "/* XPM"]]],
1558
+ ['message/news', [[0, "Article"], [0, "Path:"], [0, "Xref:"]]],
1559
+ ['message/rfc822', [[0, "#! rnews"], [0, "Forward to"], [0, "From:"], [0, "N#! rnews"], [0, "Pipe to"], [0, "Received:"], [0, "Relay-Version:"], [0, "Return-Path:"], [0, "Return-path:"], [0, "Subject: "]]],
1560
+ ['text/calendar', [[0, "BEGIN:VCALENDAR"], [0, "begin:vcalendar"]]],
1561
+ ['text/directory', [[0, "BEGIN:VCARD"], [0, "begin:vcard"]]],
1562
+ ['application/metalink+xml', [[0..256, "<metalink"]]],
1563
+ ['text/plain', [[0, "This is TeX,"], [0, "This is METAFONT,"]]],
1564
+ ['application/x-it87', [[0, "IT8.7"]]],
1565
+ ['application/mathematica', [[0, "(************** Content-type: application/mathematica"], [100..256, "This notebook can be used on any computer system with Mathematica"], [10..256, "This is a Mathematica Notebook file. It contains ASCII text"]]],
1566
+ ['application/mac-binhex40', [[11, "must be converted with BinHex"]]],
1567
+ ['text/spreadsheet', [[0, "ID;"]]],
1568
+ ['text/vnd.graphviz', [[0, "digraph "], [0, "strict digraph "], [0, "graph "], [0, "strict graph "]]],
1569
+ ['text/vnd.sun.j2me.app-descriptor', [[0, "MIDlet-"]]],
1570
+ ['application/x-ace', [[7, "**ACE**"]]],
1571
+ ['text/x-ms-regedit', [[0, "REGEDIT"], [0, "Windows Registry Editor Version 5.00"], [0, "\xFF\xFEW\x00i\x00n\x00d\x00o\x00w\x00s\x00 \x00R\x00e\x00g\x00i\x00s\x00t\x00r\x00y\x00 \x00E\x00d\x00i\x00t\x00o\x00r\x00"]]],
1572
+ ['text/x-makefile', [[0, "#!/usr/bin/make"], [0, "#! /usr/bin/make"]]],
1573
+ ['text/x-emacs-lisp', [[0, "\n("], [0, ";ELC\u0013\u0000\u0000\u0000"]]],
1574
+ ['text/html', [[0..256, "<!DOCTYPE HTML"], [0..256, "<!doctype html"], [0..256, "<HEAD"], [0..256, "<head"], [0..256, "<TITLE"], [0..256, "<title"], [0..256, "<HTML"], [0..256, "<html"], [0..256, "<SCRIPT"], [0..256, "<script"], [0, "<BODY"], [0, "<body"], [0, "<!--"], [0, "<h1"], [0, "<H1"], [0, "<!doctype HTML"], [0, "<!DOCTYPE html"]]],
1575
+ ['text/x-ldif', [[0, "dn: cn="], [0, "dn: mail="]]],
1576
+ ['audio/x-wavpack', [[0, "wvpk"]]],
1577
+ ['application/x-archive', [[0, "<ar>"], [0, "!<arch>"]]],
1578
+ ['audio/x-riff', [[0, "RIFF"]]],
1579
+ ['video/x-javafx', [[0, "FLV"]]],
1580
+ ['application/zip', [[0, "PK\u0003\u0004"]]],
1581
+ ['audio/basic', [[0, ".snd"]]],
1582
+ ['application/xml', [[0, "<?xml"], [0, "<!--"]]],
1583
+ ['application/x-executable', [[0, "\x7FELF", [[5, "\x01", [[16, "\x02\x00"]]]]], [0, "\x7FELF", [[5, "\x02", [[16, "\x00\x02"]]]]], [0, "MZ"], [0, "\x1CR"], [0, "\x10\x01"], [0, "\x11\x01"], [0, "\x83\x01"]]],
1584
+ ['text/x-objcsrc', [[0, "#import"]]],
1585
+ ['text/x-csrc', [[0, "/*"], [0, "//"], [0, "#include"]]],
1586
+ ['application/mbox', [[0, "From "]]],
1587
+ ['image/x-tga', [[1, "\x01\x01"], [1, "\x019"], [1, "\x00\x03"], [1, "\x00\n"], [1, "\x00\v"], [1, "\x00\x02"]]],
1588
+ ['text/x-matlab', [[0, "%"]]],
1589
+ ['text/x-tex', [[0, "%"]]],
1590
+ ['text/x-matlab', [[0, "##"]]],
1591
+ ['application/x-designer', [[0..256, "<ui"], [0..256, "<UI"]]],
1592
+ ['text/vnd.trolltech.linguist', [[0..256, "<TS"]]],
1593
+ ['application/x-ruby', [[1..16, "/bin/env ruby"], [1..16, "/bin/ruby"]]],
1594
+ ['application/x-ms-wim', [[0, "MSWIM\u0000\u0000\u0000"]]],
1595
+ ['application/x-dar', [[0, "\x00\x00\x00{"]]],
1596
+ ['application/x-csh', [[1..16, "/bin/tcsh"], [1..16, "/bin/csh"], [0, "#!/usr/bin/env csh"], [0, "#!/usr/bin/env tcsh"]]],
1597
+ ['audio/x-stm', [[20, "!Scream!\u001A"], [20, "!SCREAM!\u001A"], [20, "BMOD2STM\u001A"]]],
1598
+ ['application/vnd.sun.xml.writer.template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.writer"]]]]]]],
1599
+ ['application/vnd.sun.xml.writer.global', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.writer"]]]]]]],
1600
+ ['application/vnd.sun.xml.writer', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.writer"]]]]]]],
1601
+ ['application/vnd.sun.xml.math', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.math"]]]]]]],
1602
+ ['application/vnd.sun.xml.impress.template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.impress"]]]]]]],
1603
+ ['application/vnd.sun.xml.impress', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.impress"]]]]]]],
1604
+ ['application/vnd.sun.xml.draw.template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.draw"]]]]]]],
1605
+ ['application/vnd.sun.xml.draw', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.draw"]]]]]]],
1606
+ ['application/vnd.sun.xml.calc.template', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.calc"]]]]]]],
1607
+ ['application/vnd.sun.xml.calc', [[0, "PK\u0003\u0004", [[30, "mimetype", [[38, "application/vnd.sun.xml.calc"]]]]]]],
1608
+ ['application/x-yaml', [[0, "%YAML"]]],
1609
+ ['text/x-bibtex', [[0, "% This file was created with JabRef"]]],
1610
+ ['application/x-sqlite3', [[0, "SQLite format 3"]]],
1611
+ ['application/x-sqlite2', [[0, "** This file contains an SQLite"]]],
1612
+ ['text/cache-manifest', [[0, "CACHE MANIFEST", [[14, " "], [14, "\t"], [14, "\n"], [14, "\r"]]]]],
1613
+ ]
1614
+ end