vendor/symfony/http-foundation/File/MimeType/MimeTypeExtensionGuesser.php line 16

Open in your IDE?
  1. <?php
  2. /*
  3.  * This file is part of the Symfony package.
  4.  *
  5.  * (c) Fabien Potencier <fabien@symfony.com>
  6.  *
  7.  * For the full copyright and license information, please view the LICENSE
  8.  * file that was distributed with this source code.
  9.  */
  10. namespace Symfony\Component\HttpFoundation\File\MimeType;
  11. use Symfony\Component\Mime\MimeTypes;
  12. @trigger_error(sprintf('The "%s" class is deprecated since Symfony 4.3, use "%s" instead.'MimeTypeExtensionGuesser::class, MimeTypes::class), \E_USER_DEPRECATED);
  13. /**
  14.  * Provides a best-guess mapping of mime type to file extension.
  15.  *
  16.  * @deprecated since Symfony 4.3, use {@link MimeTypes} instead
  17.  */
  18. class MimeTypeExtensionGuesser implements ExtensionGuesserInterface
  19. {
  20.     /**
  21.      * A map of mime types and their default extensions.
  22.      *
  23.      * This list has been placed under the public domain by the Apache HTTPD project.
  24.      * This list has been updated from upstream on 2019-01-14.
  25.      *
  26.      * @see https://svn.apache.org/repos/asf/httpd/httpd/trunk/docs/conf/mime.types
  27.      */
  28.     protected $defaultExtensions = [
  29.         'application/andrew-inset' => 'ez',
  30.         'application/applixware' => 'aw',
  31.         'application/atom+xml' => 'atom',
  32.         'application/atomcat+xml' => 'atomcat',
  33.         'application/atomsvc+xml' => 'atomsvc',
  34.         'application/ccxml+xml' => 'ccxml',
  35.         'application/cdmi-capability' => 'cdmia',
  36.         'application/cdmi-container' => 'cdmic',
  37.         'application/cdmi-domain' => 'cdmid',
  38.         'application/cdmi-object' => 'cdmio',
  39.         'application/cdmi-queue' => 'cdmiq',
  40.         'application/cu-seeme' => 'cu',
  41.         'application/davmount+xml' => 'davmount',
  42.         'application/docbook+xml' => 'dbk',
  43.         'application/dssc+der' => 'dssc',
  44.         'application/dssc+xml' => 'xdssc',
  45.         'application/ecmascript' => 'ecma',
  46.         'application/emma+xml' => 'emma',
  47.         'application/epub+zip' => 'epub',
  48.         'application/exi' => 'exi',
  49.         'application/font-tdpfr' => 'pfr',
  50.         'application/gml+xml' => 'gml',
  51.         'application/gpx+xml' => 'gpx',
  52.         'application/gxf' => 'gxf',
  53.         'application/hyperstudio' => 'stk',
  54.         'application/inkml+xml' => 'ink',
  55.         'application/ipfix' => 'ipfix',
  56.         'application/java-archive' => 'jar',
  57.         'application/java-serialized-object' => 'ser',
  58.         'application/java-vm' => 'class',
  59.         'application/javascript' => 'js',
  60.         'application/json' => 'json',
  61.         'application/jsonml+json' => 'jsonml',
  62.         'application/lost+xml' => 'lostxml',
  63.         'application/mac-binhex40' => 'hqx',
  64.         'application/mac-compactpro' => 'cpt',
  65.         'application/mads+xml' => 'mads',
  66.         'application/marc' => 'mrc',
  67.         'application/marcxml+xml' => 'mrcx',
  68.         'application/mathematica' => 'ma',
  69.         'application/mathml+xml' => 'mathml',
  70.         'application/mbox' => 'mbox',
  71.         'application/mediaservercontrol+xml' => 'mscml',
  72.         'application/metalink+xml' => 'metalink',
  73.         'application/metalink4+xml' => 'meta4',
  74.         'application/mets+xml' => 'mets',
  75.         'application/mods+xml' => 'mods',
  76.         'application/mp21' => 'm21',
  77.         'application/mp4' => 'mp4s',
  78.         'application/msword' => 'doc',
  79.         'application/mxf' => 'mxf',
  80.         'application/octet-stream' => 'bin',
  81.         'application/oda' => 'oda',
  82.         'application/oebps-package+xml' => 'opf',
  83.         'application/ogg' => 'ogx',
  84.         'application/omdoc+xml' => 'omdoc',
  85.         'application/onenote' => 'onetoc',
  86.         'application/oxps' => 'oxps',
  87.         'application/patch-ops-error+xml' => 'xer',
  88.         'application/pdf' => 'pdf',
  89.         'application/pgp-encrypted' => 'pgp',
  90.         'application/pgp-signature' => 'asc',
  91.         'application/pics-rules' => 'prf',
  92.         'application/pkcs10' => 'p10',
  93.         'application/pkcs7-mime' => 'p7m',
  94.         'application/pkcs7-signature' => 'p7s',
  95.         'application/pkcs8' => 'p8',
  96.         'application/pkix-attr-cert' => 'ac',
  97.         'application/pkix-cert' => 'cer',
  98.         'application/pkix-crl' => 'crl',
  99.         'application/pkix-pkipath' => 'pkipath',
  100.         'application/pkixcmp' => 'pki',
  101.         'application/pls+xml' => 'pls',
  102.         'application/postscript' => 'ai',
  103.         'application/prs.cww' => 'cww',
  104.         'application/pskc+xml' => 'pskcxml',
  105.         'application/rdf+xml' => 'rdf',
  106.         'application/reginfo+xml' => 'rif',
  107.         'application/relax-ng-compact-syntax' => 'rnc',
  108.         'application/resource-lists+xml' => 'rl',
  109.         'application/resource-lists-diff+xml' => 'rld',
  110.         'application/rls-services+xml' => 'rs',
  111.         'application/rpki-ghostbusters' => 'gbr',
  112.         'application/rpki-manifest' => 'mft',
  113.         'application/rpki-roa' => 'roa',
  114.         'application/rsd+xml' => 'rsd',
  115.         'application/rss+xml' => 'rss',
  116.         'application/rtf' => 'rtf',
  117.         'application/sbml+xml' => 'sbml',
  118.         'application/scvp-cv-request' => 'scq',
  119.         'application/scvp-cv-response' => 'scs',
  120.         'application/scvp-vp-request' => 'spq',
  121.         'application/scvp-vp-response' => 'spp',
  122.         'application/sdp' => 'sdp',
  123.         'application/set-payment-initiation' => 'setpay',
  124.         'application/set-registration-initiation' => 'setreg',
  125.         'application/shf+xml' => 'shf',
  126.         'application/smil+xml' => 'smi',
  127.         'application/sparql-query' => 'rq',
  128.         'application/sparql-results+xml' => 'srx',
  129.         'application/srgs' => 'gram',
  130.         'application/srgs+xml' => 'grxml',
  131.         'application/sru+xml' => 'sru',
  132.         'application/ssdl+xml' => 'ssdl',
  133.         'application/ssml+xml' => 'ssml',
  134.         'application/tei+xml' => 'tei',
  135.         'application/thraud+xml' => 'tfi',
  136.         'application/timestamped-data' => 'tsd',
  137.         'application/vnd.3gpp.pic-bw-large' => 'plb',
  138.         'application/vnd.3gpp.pic-bw-small' => 'psb',
  139.         'application/vnd.3gpp.pic-bw-var' => 'pvb',
  140.         'application/vnd.3gpp2.tcap' => 'tcap',
  141.         'application/vnd.3m.post-it-notes' => 'pwn',
  142.         'application/vnd.accpac.simply.aso' => 'aso',
  143.         'application/vnd.accpac.simply.imp' => 'imp',
  144.         'application/vnd.acucobol' => 'acu',
  145.         'application/vnd.acucorp' => 'atc',
  146.         'application/vnd.adobe.air-application-installer-package+zip' => 'air',
  147.         'application/vnd.adobe.formscentral.fcdt' => 'fcdt',
  148.         'application/vnd.adobe.fxp' => 'fxp',
  149.         'application/vnd.adobe.xdp+xml' => 'xdp',
  150.         'application/vnd.adobe.xfdf' => 'xfdf',
  151.         'application/vnd.ahead.space' => 'ahead',
  152.         'application/vnd.airzip.filesecure.azf' => 'azf',
  153.         'application/vnd.airzip.filesecure.azs' => 'azs',
  154.         'application/vnd.amazon.ebook' => 'azw',
  155.         'application/vnd.americandynamics.acc' => 'acc',
  156.         'application/vnd.amiga.ami' => 'ami',
  157.         'application/vnd.android.package-archive' => 'apk',
  158.         'application/vnd.anser-web-certificate-issue-initiation' => 'cii',
  159.         'application/vnd.anser-web-funds-transfer-initiation' => 'fti',
  160.         'application/vnd.antix.game-component' => 'atx',
  161.         'application/vnd.apple.installer+xml' => 'mpkg',
  162.         'application/vnd.apple.mpegurl' => 'm3u8',
  163.         'application/vnd.aristanetworks.swi' => 'swi',
  164.         'application/vnd.astraea-software.iota' => 'iota',
  165.         'application/vnd.audiograph' => 'aep',
  166.         'application/vnd.blueice.multipass' => 'mpm',
  167.         'application/vnd.bmi' => 'bmi',
  168.         'application/vnd.businessobjects' => 'rep',
  169.         'application/vnd.chemdraw+xml' => 'cdxml',
  170.         'application/vnd.chipnuts.karaoke-mmd' => 'mmd',
  171.         'application/vnd.cinderella' => 'cdy',
  172.         'application/vnd.claymore' => 'cla',
  173.         'application/vnd.cloanto.rp9' => 'rp9',
  174.         'application/vnd.clonk.c4group' => 'c4g',
  175.         'application/vnd.cluetrust.cartomobile-config' => 'c11amc',
  176.         'application/vnd.cluetrust.cartomobile-config-pkg' => 'c11amz',
  177.         'application/vnd.commonspace' => 'csp',
  178.         'application/vnd.contact.cmsg' => 'cdbcmsg',
  179.         'application/vnd.cosmocaller' => 'cmc',
  180.         'application/vnd.crick.clicker' => 'clkx',
  181.         'application/vnd.crick.clicker.keyboard' => 'clkk',
  182.         'application/vnd.crick.clicker.palette' => 'clkp',
  183.         'application/vnd.crick.clicker.template' => 'clkt',
  184.         'application/vnd.crick.clicker.wordbank' => 'clkw',
  185.         'application/vnd.criticaltools.wbs+xml' => 'wbs',
  186.         'application/vnd.ctc-posml' => 'pml',
  187.         'application/vnd.cups-ppd' => 'ppd',
  188.         'application/vnd.curl.car' => 'car',
  189.         'application/vnd.curl.pcurl' => 'pcurl',
  190.         'application/vnd.dart' => 'dart',
  191.         'application/vnd.data-vision.rdz' => 'rdz',
  192.         'application/vnd.dece.data' => 'uvf',
  193.         'application/vnd.dece.ttml+xml' => 'uvt',
  194.         'application/vnd.dece.unspecified' => 'uvx',
  195.         'application/vnd.dece.zip' => 'uvz',
  196.         'application/vnd.denovo.fcselayout-link' => 'fe_launch',
  197.         'application/vnd.dna' => 'dna',
  198.         'application/vnd.dolby.mlp' => 'mlp',
  199.         'application/vnd.dpgraph' => 'dpg',
  200.         'application/vnd.dreamfactory' => 'dfac',
  201.         'application/vnd.ds-keypoint' => 'kpxx',
  202.         'application/vnd.dvb.ait' => 'ait',
  203.         'application/vnd.dvb.service' => 'svc',
  204.         'application/vnd.dynageo' => 'geo',
  205.         'application/vnd.ecowin.chart' => 'mag',
  206.         'application/vnd.enliven' => 'nml',
  207.         'application/vnd.epson.esf' => 'esf',
  208.         'application/vnd.epson.msf' => 'msf',
  209.         'application/vnd.epson.quickanime' => 'qam',
  210.         'application/vnd.epson.salt' => 'slt',
  211.         'application/vnd.epson.ssf' => 'ssf',
  212.         'application/vnd.eszigno3+xml' => 'es3',
  213.         'application/vnd.ezpix-album' => 'ez2',
  214.         'application/vnd.ezpix-package' => 'ez3',
  215.         'application/vnd.fdf' => 'fdf',
  216.         'application/vnd.fdsn.mseed' => 'mseed',
  217.         'application/vnd.fdsn.seed' => 'seed',
  218.         'application/vnd.flographit' => 'gph',
  219.         'application/vnd.fluxtime.clip' => 'ftc',
  220.         'application/vnd.framemaker' => 'fm',
  221.         'application/vnd.frogans.fnc' => 'fnc',
  222.         'application/vnd.frogans.ltf' => 'ltf',
  223.         'application/vnd.fsc.weblaunch' => 'fsc',
  224.         'application/vnd.fujitsu.oasys' => 'oas',
  225.         'application/vnd.fujitsu.oasys2' => 'oa2',
  226.         'application/vnd.fujitsu.oasys3' => 'oa3',
  227.         'application/vnd.fujitsu.oasysgp' => 'fg5',
  228.         'application/vnd.fujitsu.oasysprs' => 'bh2',
  229.         'application/vnd.fujixerox.ddd' => 'ddd',
  230.         'application/vnd.fujixerox.docuworks' => 'xdw',
  231.         'application/vnd.fujixerox.docuworks.binder' => 'xbd',
  232.         'application/vnd.fuzzysheet' => 'fzs',
  233.         'application/vnd.genomatix.tuxedo' => 'txd',
  234.         'application/vnd.geogebra.file' => 'ggb',
  235.         'application/vnd.geogebra.tool' => 'ggt',
  236.         'application/vnd.geometry-explorer' => 'gex',
  237.         'application/vnd.geonext' => 'gxt',
  238.         'application/vnd.geoplan' => 'g2w',
  239.         'application/vnd.geospace' => 'g3w',
  240.         'application/vnd.gmx' => 'gmx',
  241.         'application/vnd.google-earth.kml+xml' => 'kml',
  242.         'application/vnd.google-earth.kmz' => 'kmz',
  243.         'application/vnd.grafeq' => 'gqf',
  244.         'application/vnd.groove-account' => 'gac',
  245.         'application/vnd.groove-help' => 'ghf',
  246.         'application/vnd.groove-identity-message' => 'gim',
  247.         'application/vnd.groove-injector' => 'grv',
  248.         'application/vnd.groove-tool-message' => 'gtm',
  249.         'application/vnd.groove-tool-template' => 'tpl',
  250.         'application/vnd.groove-vcard' => 'vcg',
  251.         'application/vnd.hal+xml' => 'hal',
  252.         'application/vnd.handheld-entertainment+xml' => 'zmm',
  253.         'application/vnd.hbci' => 'hbci',
  254.         'application/vnd.hhe.lesson-player' => 'les',
  255.         'application/vnd.hp-hpgl' => 'hpgl',
  256.         'application/vnd.hp-hpid' => 'hpid',
  257.         'application/vnd.hp-hps' => 'hps',
  258.         'application/vnd.hp-jlyt' => 'jlt',
  259.         'application/vnd.hp-pcl' => 'pcl',
  260.         'application/vnd.hp-pclxl' => 'pclxl',
  261.         'application/vnd.hydrostatix.sof-data' => 'sfd-hdstx',
  262.         'application/vnd.ibm.minipay' => 'mpy',
  263.         'application/vnd.ibm.modcap' => 'afp',
  264.         'application/vnd.ibm.rights-management' => 'irm',
  265.         'application/vnd.ibm.secure-container' => 'sc',
  266.         'application/vnd.iccprofile' => 'icc',
  267.         'application/vnd.igloader' => 'igl',
  268.         'application/vnd.immervision-ivp' => 'ivp',
  269.         'application/vnd.immervision-ivu' => 'ivu',
  270.         'application/vnd.insors.igm' => 'igm',
  271.         'application/vnd.intercon.formnet' => 'xpw',
  272.         'application/vnd.intergeo' => 'i2g',
  273.         'application/vnd.intu.qbo' => 'qbo',
  274.         'application/vnd.intu.qfx' => 'qfx',
  275.         'application/vnd.ipunplugged.rcprofile' => 'rcprofile',
  276.         'application/vnd.irepository.package+xml' => 'irp',
  277.         'application/vnd.is-xpr' => 'xpr',
  278.         'application/vnd.isac.fcs' => 'fcs',
  279.         'application/vnd.jam' => 'jam',
  280.         'application/vnd.jcp.javame.midlet-rms' => 'rms',
  281.         'application/vnd.jisp' => 'jisp',
  282.         'application/vnd.joost.joda-archive' => 'joda',
  283.         'application/vnd.kahootz' => 'ktz',
  284.         'application/vnd.kde.karbon' => 'karbon',
  285.         'application/vnd.kde.kchart' => 'chrt',
  286.         'application/vnd.kde.kformula' => 'kfo',
  287.         'application/vnd.kde.kivio' => 'flw',
  288.         'application/vnd.kde.kontour' => 'kon',
  289.         'application/vnd.kde.kpresenter' => 'kpr',
  290.         'application/vnd.kde.kspread' => 'ksp',
  291.         'application/vnd.kde.kword' => 'kwd',
  292.         'application/vnd.kenameaapp' => 'htke',
  293.         'application/vnd.kidspiration' => 'kia',
  294.         'application/vnd.kinar' => 'kne',
  295.         'application/vnd.koan' => 'skp',
  296.         'application/vnd.kodak-descriptor' => 'sse',
  297.         'application/vnd.las.las+xml' => 'lasxml',
  298.         'application/vnd.llamagraphics.life-balance.desktop' => 'lbd',
  299.         'application/vnd.llamagraphics.life-balance.exchange+xml' => 'lbe',
  300.         'application/vnd.lotus-1-2-3' => '123',
  301.         'application/vnd.lotus-approach' => 'apr',
  302.         'application/vnd.lotus-freelance' => 'pre',
  303.         'application/vnd.lotus-notes' => 'nsf',
  304.         'application/vnd.lotus-organizer' => 'org',
  305.         'application/vnd.lotus-screencam' => 'scm',
  306.         'application/vnd.lotus-wordpro' => 'lwp',
  307.         'application/vnd.macports.portpkg' => 'portpkg',
  308.         'application/vnd.mcd' => 'mcd',
  309.         'application/vnd.medcalcdata' => 'mc1',
  310.         'application/vnd.mediastation.cdkey' => 'cdkey',
  311.         'application/vnd.mfer' => 'mwf',
  312.         'application/vnd.mfmp' => 'mfm',
  313.         'application/vnd.micrografx.flo' => 'flo',
  314.         'application/vnd.micrografx.igx' => 'igx',
  315.         'application/vnd.mif' => 'mif',
  316.         'application/vnd.mobius.daf' => 'daf',
  317.         'application/vnd.mobius.dis' => 'dis',
  318.         'application/vnd.mobius.mbk' => 'mbk',
  319.         'application/vnd.mobius.mqy' => 'mqy',
  320.         'application/vnd.mobius.msl' => 'msl',
  321.         'application/vnd.mobius.plc' => 'plc',
  322.         'application/vnd.mobius.txf' => 'txf',
  323.         'application/vnd.mophun.application' => 'mpn',
  324.         'application/vnd.mophun.certificate' => 'mpc',
  325.         'application/vnd.mozilla.xul+xml' => 'xul',
  326.         'application/vnd.ms-artgalry' => 'cil',
  327.         'application/vnd.ms-cab-compressed' => 'cab',
  328.         'application/vnd.ms-excel' => 'xls',
  329.         'application/vnd.ms-excel.addin.macroenabled.12' => 'xlam',
  330.         'application/vnd.ms-excel.sheet.binary.macroenabled.12' => 'xlsb',
  331.         'application/vnd.ms-excel.sheet.macroenabled.12' => 'xlsm',
  332.         'application/vnd.ms-excel.template.macroenabled.12' => 'xltm',
  333.         'application/vnd.ms-fontobject' => 'eot',
  334.         'application/vnd.ms-htmlhelp' => 'chm',
  335.         'application/vnd.ms-ims' => 'ims',
  336.         'application/vnd.ms-lrm' => 'lrm',
  337.         'application/vnd.ms-officetheme' => 'thmx',
  338.         'application/vnd.ms-pki.seccat' => 'cat',
  339.         'application/vnd.ms-pki.stl' => 'stl',
  340.         'application/vnd.ms-powerpoint' => 'ppt',
  341.         'application/vnd.ms-powerpoint.addin.macroenabled.12' => 'ppam',
  342.         'application/vnd.ms-powerpoint.presentation.macroenabled.12' => 'pptm',
  343.         'application/vnd.ms-powerpoint.slide.macroenabled.12' => 'sldm',
  344.         'application/vnd.ms-powerpoint.slideshow.macroenabled.12' => 'ppsm',
  345.         'application/vnd.ms-powerpoint.template.macroenabled.12' => 'potm',
  346.         'application/vnd.ms-project' => 'mpp',
  347.         'application/vnd.ms-word.document.macroenabled.12' => 'docm',
  348.         'application/vnd.ms-word.template.macroenabled.12' => 'dotm',
  349.         'application/vnd.ms-works' => 'wps',
  350.         'application/vnd.ms-wpl' => 'wpl',
  351.         'application/vnd.ms-xpsdocument' => 'xps',
  352.         'application/vnd.mseq' => 'mseq',
  353.         'application/vnd.musician' => 'mus',
  354.         'application/vnd.muvee.style' => 'msty',
  355.         'application/vnd.mynfc' => 'taglet',
  356.         'application/vnd.neurolanguage.nlu' => 'nlu',
  357.         'application/vnd.nitf' => 'ntf',
  358.         'application/vnd.noblenet-directory' => 'nnd',
  359.         'application/vnd.noblenet-sealer' => 'nns',
  360.         'application/vnd.noblenet-web' => 'nnw',
  361.         'application/vnd.nokia.n-gage.data' => 'ngdat',
  362.         'application/vnd.nokia.n-gage.symbian.install' => 'n-gage',
  363.         'application/vnd.nokia.radio-preset' => 'rpst',
  364.         'application/vnd.nokia.radio-presets' => 'rpss',
  365.         'application/vnd.novadigm.edm' => 'edm',
  366.         'application/vnd.novadigm.edx' => 'edx',
  367.         'application/vnd.novadigm.ext' => 'ext',
  368.         'application/vnd.oasis.opendocument.chart' => 'odc',
  369.         'application/vnd.oasis.opendocument.chart-template' => 'otc',
  370.         'application/vnd.oasis.opendocument.database' => 'odb',
  371.         'application/vnd.oasis.opendocument.formula' => 'odf',
  372.         'application/vnd.oasis.opendocument.formula-template' => 'odft',
  373.         'application/vnd.oasis.opendocument.graphics' => 'odg',
  374.         'application/vnd.oasis.opendocument.graphics-template' => 'otg',
  375.         'application/vnd.oasis.opendocument.image' => 'odi',
  376.         'application/vnd.oasis.opendocument.image-template' => 'oti',
  377.         'application/vnd.oasis.opendocument.presentation' => 'odp',
  378.         'application/vnd.oasis.opendocument.presentation-template' => 'otp',
  379.         'application/vnd.oasis.opendocument.spreadsheet' => 'ods',
  380.         'application/vnd.oasis.opendocument.spreadsheet-template' => 'ots',
  381.         'application/vnd.oasis.opendocument.text' => 'odt',
  382.         'application/vnd.oasis.opendocument.text-master' => 'odm',
  383.         'application/vnd.oasis.opendocument.text-template' => 'ott',
  384.         'application/vnd.oasis.opendocument.text-web' => 'oth',
  385.         'application/vnd.olpc-sugar' => 'xo',
  386.         'application/vnd.oma.dd2+xml' => 'dd2',
  387.         'application/vnd.openofficeorg.extension' => 'oxt',
  388.         'application/vnd.openxmlformats-officedocument.presentationml.presentation' => 'pptx',
  389.         'application/vnd.openxmlformats-officedocument.presentationml.slide' => 'sldx',
  390.         'application/vnd.openxmlformats-officedocument.presentationml.slideshow' => 'ppsx',
  391.         'application/vnd.openxmlformats-officedocument.presentationml.template' => 'potx',
  392.         'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' => 'xlsx',
  393.         'application/vnd.openxmlformats-officedocument.spreadsheetml.template' => 'xltx',
  394.         'application/vnd.openxmlformats-officedocument.wordprocessingml.document' => 'docx',
  395.         'application/vnd.openxmlformats-officedocument.wordprocessingml.template' => 'dotx',
  396.         'application/vnd.osgeo.mapguide.package' => 'mgp',
  397.         'application/vnd.osgi.dp' => 'dp',
  398.         'application/vnd.osgi.subsystem' => 'esa',
  399.         'application/vnd.palm' => 'pdb',
  400.         'application/vnd.pawaafile' => 'paw',
  401.         'application/vnd.pg.format' => 'str',
  402.         'application/vnd.pg.osasli' => 'ei6',
  403.         'application/vnd.picsel' => 'efif',
  404.         'application/vnd.pmi.widget' => 'wg',
  405.         'application/vnd.pocketlearn' => 'plf',
  406.         'application/vnd.powerbuilder6' => 'pbd',
  407.         'application/vnd.previewsystems.box' => 'box',
  408.         'application/vnd.proteus.magazine' => 'mgz',
  409.         'application/vnd.publishare-delta-tree' => 'qps',
  410.         'application/vnd.pvi.ptid1' => 'ptid',
  411.         'application/vnd.quark.quarkxpress' => 'qxd',
  412.         'application/vnd.realvnc.bed' => 'bed',
  413.         'application/vnd.recordare.musicxml' => 'mxl',
  414.         'application/vnd.recordare.musicxml+xml' => 'musicxml',
  415.         'application/vnd.rig.cryptonote' => 'cryptonote',
  416.         'application/vnd.rim.cod' => 'cod',
  417.         'application/vnd.rn-realmedia' => 'rm',
  418.         'application/vnd.rn-realmedia-vbr' => 'rmvb',
  419.         'application/vnd.route66.link66+xml' => 'link66',
  420.         'application/vnd.sailingtracker.track' => 'st',
  421.         'application/vnd.seemail' => 'see',
  422.         'application/vnd.sema' => 'sema',
  423.         'application/vnd.semd' => 'semd',
  424.         'application/vnd.semf' => 'semf',
  425.         'application/vnd.shana.informed.formdata' => 'ifm',
  426.         'application/vnd.shana.informed.formtemplate' => 'itp',
  427.         'application/vnd.shana.informed.interchange' => 'iif',
  428.         'application/vnd.shana.informed.package' => 'ipk',
  429.         'application/vnd.simtech-mindmapper' => 'twd',
  430.         'application/vnd.smaf' => 'mmf',
  431.         'application/vnd.smart.teacher' => 'teacher',
  432.         'application/vnd.solent.sdkm+xml' => 'sdkm',
  433.         'application/vnd.spotfire.dxp' => 'dxp',
  434.         'application/vnd.spotfire.sfs' => 'sfs',
  435.         'application/vnd.stardivision.calc' => 'sdc',
  436.         'application/vnd.stardivision.draw' => 'sda',
  437.         'application/vnd.stardivision.impress' => 'sdd',
  438.         'application/vnd.stardivision.math' => 'smf',
  439.         'application/vnd.stardivision.writer' => 'sdw',
  440.         'application/vnd.stardivision.writer-global' => 'sgl',
  441.         'application/vnd.stepmania.package' => 'smzip',
  442.         'application/vnd.stepmania.stepchart' => 'sm',
  443.         'application/vnd.sun.xml.calc' => 'sxc',
  444.         'application/vnd.sun.xml.calc.template' => 'stc',
  445.         'application/vnd.sun.xml.draw' => 'sxd',
  446.         'application/vnd.sun.xml.draw.template' => 'std',
  447.         'application/vnd.sun.xml.impress' => 'sxi',
  448.         'application/vnd.sun.xml.impress.template' => 'sti',
  449.         'application/vnd.sun.xml.math' => 'sxm',
  450.         'application/vnd.sun.xml.writer' => 'sxw',
  451.         'application/vnd.sun.xml.writer.global' => 'sxg',
  452.         'application/vnd.sun.xml.writer.template' => 'stw',
  453.         'application/vnd.sus-calendar' => 'sus',
  454.         'application/vnd.svd' => 'svd',
  455.         'application/vnd.symbian.install' => 'sis',
  456.         'application/vnd.syncml+xml' => 'xsm',
  457.         'application/vnd.syncml.dm+wbxml' => 'bdm',
  458.         'application/vnd.syncml.dm+xml' => 'xdm',
  459.         'application/vnd.tao.intent-module-archive' => 'tao',
  460.         'application/vnd.tcpdump.pcap' => 'pcap',
  461.         'application/vnd.tmobile-livetv' => 'tmo',
  462.         'application/vnd.trid.tpt' => 'tpt',
  463.         'application/vnd.triscape.mxs' => 'mxs',
  464.         'application/vnd.trueapp' => 'tra',
  465.         'application/vnd.ufdl' => 'ufd',
  466.         'application/vnd.uiq.theme' => 'utz',
  467.         'application/vnd.umajin' => 'umj',
  468.         'application/vnd.unity' => 'unityweb',
  469.         'application/vnd.uoml+xml' => 'uoml',
  470.         'application/vnd.vcx' => 'vcx',
  471.         'application/vnd.visio' => 'vsd',
  472.         'application/vnd.visionary' => 'vis',
  473.         'application/vnd.vsf' => 'vsf',
  474.         'application/vnd.wap.wbxml' => 'wbxml',
  475.         'application/vnd.wap.wmlc' => 'wmlc',
  476.         'application/vnd.wap.wmlscriptc' => 'wmlsc',
  477.         'application/vnd.webturbo' => 'wtb',
  478.         'application/vnd.wolfram.player' => 'nbp',
  479.         'application/vnd.wordperfect' => 'wpd',
  480.         'application/vnd.wqd' => 'wqd',
  481.         'application/vnd.wt.stf' => 'stf',
  482.         'application/vnd.xara' => 'xar',
  483.         'application/vnd.xfdl' => 'xfdl',
  484.         'application/vnd.yamaha.hv-dic' => 'hvd',
  485.         'application/vnd.yamaha.hv-script' => 'hvs',
  486.         'application/vnd.yamaha.hv-voice' => 'hvp',
  487.         'application/vnd.yamaha.openscoreformat' => 'osf',
  488.         'application/vnd.yamaha.openscoreformat.osfpvg+xml' => 'osfpvg',
  489.         'application/vnd.yamaha.smaf-audio' => 'saf',
  490.         'application/vnd.yamaha.smaf-phrase' => 'spf',
  491.         'application/vnd.yellowriver-custom-menu' => 'cmp',
  492.         'application/vnd.zul' => 'zir',
  493.         'application/vnd.zzazz.deck+xml' => 'zaz',
  494.         'application/voicexml+xml' => 'vxml',
  495.         'application/widget' => 'wgt',
  496.         'application/winhlp' => 'hlp',
  497.         'application/wsdl+xml' => 'wsdl',
  498.         'application/wspolicy+xml' => 'wspolicy',
  499.         'application/x-7z-compressed' => '7z',
  500.         'application/x-abiword' => 'abw',
  501.         'application/x-ace-compressed' => 'ace',
  502.         'application/x-apple-diskimage' => 'dmg',
  503.         'application/x-authorware-bin' => 'aab',
  504.         'application/x-authorware-map' => 'aam',
  505.         'application/x-authorware-seg' => 'aas',
  506.         'application/x-bcpio' => 'bcpio',
  507.         'application/x-bittorrent' => 'torrent',
  508.         'application/x-blorb' => 'blb',
  509.         'application/x-bzip' => 'bz',
  510.         'application/x-bzip2' => 'bz2',
  511.         'application/x-cbr' => 'cbr',
  512.         'application/x-cdlink' => 'vcd',
  513.         'application/x-cfs-compressed' => 'cfs',
  514.         'application/x-chat' => 'chat',
  515.         'application/x-chess-pgn' => 'pgn',
  516.         'application/x-conference' => 'nsc',
  517.         'application/x-cpio' => 'cpio',
  518.         'application/x-csh' => 'csh',
  519.         'application/x-debian-package' => 'deb',
  520.         'application/x-dgc-compressed' => 'dgc',
  521.         'application/x-director' => 'dir',
  522.         'application/x-doom' => 'wad',
  523.         'application/x-dtbncx+xml' => 'ncx',
  524.         'application/x-dtbook+xml' => 'dtb',
  525.         'application/x-dtbresource+xml' => 'res',
  526.         'application/x-dvi' => 'dvi',
  527.         'application/x-envoy' => 'evy',
  528.         'application/x-eva' => 'eva',
  529.         'application/x-font-bdf' => 'bdf',
  530.         'application/x-font-ghostscript' => 'gsf',
  531.         'application/x-font-linux-psf' => 'psf',
  532.         'application/x-font-otf' => 'otf',
  533.         'application/x-font-pcf' => 'pcf',
  534.         'application/x-font-snf' => 'snf',
  535.         'application/x-font-ttf' => 'ttf',
  536.         'application/x-font-type1' => 'pfa',
  537.         'application/x-font-woff' => 'woff',
  538.         'application/x-freearc' => 'arc',
  539.         'application/x-futuresplash' => 'spl',
  540.         'application/x-gca-compressed' => 'gca',
  541.         'application/x-glulx' => 'ulx',
  542.         'application/x-gnumeric' => 'gnumeric',
  543.         'application/x-gramps-xml' => 'gramps',
  544.         'application/x-gtar' => 'gtar',
  545.         'application/x-hdf' => 'hdf',
  546.         'application/x-install-instructions' => 'install',
  547.         'application/x-iso9660-image' => 'iso',
  548.         'application/x-java-jnlp-file' => 'jnlp',
  549.         'application/x-latex' => 'latex',
  550.         'application/x-lzh-compressed' => 'lzh',
  551.         'application/x-mie' => 'mie',
  552.         'application/x-mobipocket-ebook' => 'prc',
  553.         'application/x-ms-application' => 'application',
  554.         'application/x-ms-shortcut' => 'lnk',
  555.         'application/x-ms-wmd' => 'wmd',
  556.         'application/x-ms-wmz' => 'wmz',
  557.         'application/x-ms-xbap' => 'xbap',
  558.         'application/x-msaccess' => 'mdb',
  559.         'application/x-msbinder' => 'obd',
  560.         'application/x-mscardfile' => 'crd',
  561.         'application/x-msclip' => 'clp',
  562.         'application/x-msdownload' => 'exe',
  563.         'application/x-msmediaview' => 'mvb',
  564.         'application/x-msmetafile' => 'wmf',
  565.         'application/x-msmoney' => 'mny',
  566.         'application/x-mspublisher' => 'pub',
  567.         'application/x-msschedule' => 'scd',
  568.         'application/x-msterminal' => 'trm',
  569.         'application/x-mswrite' => 'wri',
  570.         'application/x-netcdf' => 'nc',
  571.         'application/x-nzb' => 'nzb',
  572.         'application/x-pkcs12' => 'p12',
  573.         'application/x-pkcs7-certificates' => 'p7b',
  574.         'application/x-pkcs7-certreqresp' => 'p7r',
  575.         'application/x-rar-compressed' => 'rar',
  576.         'application/x-rar' => 'rar',
  577.         'application/x-research-info-systems' => 'ris',
  578.         'application/x-sh' => 'sh',
  579.         'application/x-shar' => 'shar',
  580.         'application/x-shockwave-flash' => 'swf',
  581.         'application/x-silverlight-app' => 'xap',
  582.         'application/x-sql' => 'sql',
  583.         'application/x-stuffit' => 'sit',
  584.         'application/x-stuffitx' => 'sitx',
  585.         'application/x-subrip' => 'srt',
  586.         'application/x-sv4cpio' => 'sv4cpio',
  587.         'application/x-sv4crc' => 'sv4crc',
  588.         'application/x-t3vm-image' => 't3',
  589.         'application/x-tads' => 'gam',
  590.         'application/x-tar' => 'tar',
  591.         'application/x-tcl' => 'tcl',
  592.         'application/x-tex' => 'tex',
  593.         'application/x-tex-tfm' => 'tfm',
  594.         'application/x-texinfo' => 'texinfo',
  595.         'application/x-tgif' => 'obj',
  596.         'application/x-ustar' => 'ustar',
  597.         'application/x-wais-source' => 'src',
  598.         'application/x-x509-ca-cert' => 'der',
  599.         'application/x-xfig' => 'fig',
  600.         'application/x-xliff+xml' => 'xlf',
  601.         'application/x-xpinstall' => 'xpi',
  602.         'application/x-xz' => 'xz',
  603.         'application/x-zip-compressed' => 'zip',
  604.         'application/x-zmachine' => 'z1',
  605.         'application/xaml+xml' => 'xaml',
  606.         'application/xcap-diff+xml' => 'xdf',
  607.         'application/xenc+xml' => 'xenc',
  608.         'application/xhtml+xml' => 'xhtml',
  609.         'application/xml' => 'xml',
  610.         'application/xml-dtd' => 'dtd',
  611.         'application/xop+xml' => 'xop',
  612.         'application/xproc+xml' => 'xpl',
  613.         'application/xslt+xml' => 'xslt',
  614.         'application/xspf+xml' => 'xspf',
  615.         'application/xv+xml' => 'mxml',
  616.         'application/yang' => 'yang',
  617.         'application/yin+xml' => 'yin',
  618.         'application/zip' => 'zip',
  619.         'audio/adpcm' => 'adp',
  620.         'audio/basic' => 'au',
  621.         'audio/midi' => 'mid',
  622.         'audio/mp4' => 'm4a',
  623.         'audio/mpeg' => 'mp3',
  624.         'audio/ogg' => 'oga',
  625.         'audio/s3m' => 's3m',
  626.         'audio/silk' => 'sil',
  627.         'audio/vnd.dece.audio' => 'uva',
  628.         'audio/vnd.digital-winds' => 'eol',
  629.         'audio/vnd.dra' => 'dra',
  630.         'audio/vnd.dts' => 'dts',
  631.         'audio/vnd.dts.hd' => 'dtshd',
  632.         'audio/vnd.lucent.voice' => 'lvp',
  633.         'audio/vnd.ms-playready.media.pya' => 'pya',
  634.         'audio/vnd.nuera.ecelp4800' => 'ecelp4800',
  635.         'audio/vnd.nuera.ecelp7470' => 'ecelp7470',
  636.         'audio/vnd.nuera.ecelp9600' => 'ecelp9600',
  637.         'audio/vnd.rip' => 'rip',
  638.         'audio/webm' => 'weba',
  639.         'audio/x-aac' => 'aac',
  640.         'audio/x-aiff' => 'aif',
  641.         'audio/x-caf' => 'caf',
  642.         'audio/x-flac' => 'flac',
  643.         'audio/x-hx-aac-adts' => 'aac',
  644.         'audio/x-matroska' => 'mka',
  645.         'audio/x-mpegurl' => 'm3u',
  646.         'audio/x-ms-wax' => 'wax',
  647.         'audio/x-ms-wma' => 'wma',
  648.         'audio/x-pn-realaudio' => 'ram',
  649.         'audio/x-pn-realaudio-plugin' => 'rmp',
  650.         'audio/x-wav' => 'wav',
  651.         'audio/xm' => 'xm',
  652.         'chemical/x-cdx' => 'cdx',
  653.         'chemical/x-cif' => 'cif',
  654.         'chemical/x-cmdf' => 'cmdf',
  655.         'chemical/x-cml' => 'cml',
  656.         'chemical/x-csml' => 'csml',
  657.         'chemical/x-xyz' => 'xyz',
  658.         'font/collection' => 'ttc',
  659.         'font/otf' => 'otf',
  660.         'font/ttf' => 'ttf',
  661.         'font/woff' => 'woff',
  662.         'font/woff2' => 'woff2',
  663.         'image/bmp' => 'bmp',
  664.         'image/x-ms-bmp' => 'bmp',
  665.         'image/cgm' => 'cgm',
  666.         'image/g3fax' => 'g3',
  667.         'image/gif' => 'gif',
  668.         'image/ief' => 'ief',
  669.         'image/jpeg' => 'jpeg',
  670.         'image/pjpeg' => 'jpeg',
  671.         'image/ktx' => 'ktx',
  672.         'image/png' => 'png',
  673.         'image/prs.btif' => 'btif',
  674.         'image/sgi' => 'sgi',
  675.         'image/svg+xml' => 'svg',
  676.         'image/tiff' => 'tiff',
  677.         'image/vnd.adobe.photoshop' => 'psd',
  678.         'image/vnd.dece.graphic' => 'uvi',
  679.         'image/vnd.djvu' => 'djvu',
  680.         'image/vnd.dvb.subtitle' => 'sub',
  681.         'image/vnd.dwg' => 'dwg',
  682.         'image/vnd.dxf' => 'dxf',
  683.         'image/vnd.fastbidsheet' => 'fbs',
  684.         'image/vnd.fpx' => 'fpx',
  685.         'image/vnd.fst' => 'fst',
  686.         'image/vnd.fujixerox.edmics-mmr' => 'mmr',
  687.         'image/vnd.fujixerox.edmics-rlc' => 'rlc',
  688.         'image/vnd.ms-modi' => 'mdi',
  689.         'image/vnd.ms-photo' => 'wdp',
  690.         'image/vnd.net-fpx' => 'npx',
  691.         'image/vnd.wap.wbmp' => 'wbmp',
  692.         'image/vnd.xiff' => 'xif',
  693.         'image/webp' => 'webp',
  694.         'image/x-3ds' => '3ds',
  695.         'image/x-cmu-raster' => 'ras',
  696.         'image/x-cmx' => 'cmx',
  697.         'image/x-freehand' => 'fh',
  698.         'image/x-icon' => 'ico',
  699.         'image/x-mrsid-image' => 'sid',
  700.         'image/x-pcx' => 'pcx',
  701.         'image/x-pict' => 'pic',
  702.         'image/x-portable-anymap' => 'pnm',
  703.         'image/x-portable-bitmap' => 'pbm',
  704.         'image/x-portable-graymap' => 'pgm',
  705.         'image/x-portable-pixmap' => 'ppm',
  706.         'image/x-rgb' => 'rgb',
  707.         'image/x-tga' => 'tga',
  708.         'image/x-xbitmap' => 'xbm',
  709.         'image/x-xpixmap' => 'xpm',
  710.         'image/x-xwindowdump' => 'xwd',
  711.         'message/rfc822' => 'eml',
  712.         'model/iges' => 'igs',
  713.         'model/mesh' => 'msh',
  714.         'model/vnd.collada+xml' => 'dae',
  715.         'model/vnd.dwf' => 'dwf',
  716.         'model/vnd.gdl' => 'gdl',
  717.         'model/vnd.gtw' => 'gtw',
  718.         'model/vnd.mts' => 'mts',
  719.         'model/vnd.vtu' => 'vtu',
  720.         'model/vrml' => 'wrl',
  721.         'model/x3d+binary' => 'x3db',
  722.         'model/x3d+vrml' => 'x3dv',
  723.         'model/x3d+xml' => 'x3d',
  724.         'text/cache-manifest' => 'appcache',
  725.         'text/calendar' => 'ics',
  726.         'text/css' => 'css',
  727.         'text/csv' => 'csv',
  728.         'text/html' => 'html',
  729.         'text/n3' => 'n3',
  730.         'text/plain' => 'txt',
  731.         'text/prs.lines.tag' => 'dsc',
  732.         'text/richtext' => 'rtx',
  733.         'text/rtf' => 'rtf',
  734.         'text/sgml' => 'sgml',
  735.         'text/tab-separated-values' => 'tsv',
  736.         'text/troff' => 't',
  737.         'text/turtle' => 'ttl',
  738.         'text/uri-list' => 'uri',
  739.         'text/vcard' => 'vcard',
  740.         'text/vnd.curl' => 'curl',
  741.         'text/vnd.curl.dcurl' => 'dcurl',
  742.         'text/vnd.curl.mcurl' => 'mcurl',
  743.         'text/vnd.curl.scurl' => 'scurl',
  744.         'text/vnd.dvb.subtitle' => 'sub',
  745.         'text/vnd.fly' => 'fly',
  746.         'text/vnd.fmi.flexstor' => 'flx',
  747.         'text/vnd.graphviz' => 'gv',
  748.         'text/vnd.in3d.3dml' => '3dml',
  749.         'text/vnd.in3d.spot' => 'spot',
  750.         'text/vnd.sun.j2me.app-descriptor' => 'jad',
  751.         'text/vnd.wap.wml' => 'wml',
  752.         'text/vnd.wap.wmlscript' => 'wmls',
  753.         'text/vtt' => 'vtt',
  754.         'text/x-asm' => 's',
  755.         'text/x-c' => 'c',
  756.         'text/x-fortran' => 'f',
  757.         'text/x-java-source' => 'java',
  758.         'text/x-nfo' => 'nfo',
  759.         'text/x-opml' => 'opml',
  760.         'text/x-pascal' => 'p',
  761.         'text/x-setext' => 'etx',
  762.         'text/x-sfv' => 'sfv',
  763.         'text/x-uuencode' => 'uu',
  764.         'text/x-vcalendar' => 'vcs',
  765.         'text/x-vcard' => 'vcf',
  766.         'video/3gpp' => '3gp',
  767.         'video/3gpp2' => '3g2',
  768.         'video/h261' => 'h261',
  769.         'video/h263' => 'h263',
  770.         'video/h264' => 'h264',
  771.         'video/jpeg' => 'jpgv',
  772.         'video/jpm' => 'jpm',
  773.         'video/mj2' => 'mj2',
  774.         'video/mp4' => 'mp4',
  775.         'video/mpeg' => 'mpeg',
  776.         'video/ogg' => 'ogv',
  777.         'video/quicktime' => 'qt',
  778.         'video/vnd.dece.hd' => 'uvh',
  779.         'video/vnd.dece.mobile' => 'uvm',
  780.         'video/vnd.dece.pd' => 'uvp',
  781.         'video/vnd.dece.sd' => 'uvs',
  782.         'video/vnd.dece.video' => 'uvv',
  783.         'video/vnd.dvb.file' => 'dvb',
  784.         'video/vnd.fvt' => 'fvt',
  785.         'video/vnd.mpegurl' => 'mxu',
  786.         'video/vnd.ms-playready.media.pyv' => 'pyv',
  787.         'video/vnd.uvvu.mp4' => 'uvu',
  788.         'video/vnd.vivo' => 'viv',
  789.         'video/webm' => 'webm',
  790.         'video/x-f4v' => 'f4v',
  791.         'video/x-fli' => 'fli',
  792.         'video/x-flv' => 'flv',
  793.         'video/x-m4v' => 'm4v',
  794.         'video/x-matroska' => 'mkv',
  795.         'video/x-mng' => 'mng',
  796.         'video/x-ms-asf' => 'asf',
  797.         'video/x-ms-vob' => 'vob',
  798.         'video/x-ms-wm' => 'wm',
  799.         'video/x-ms-wmv' => 'wmv',
  800.         'video/x-ms-wmx' => 'wmx',
  801.         'video/x-ms-wvx' => 'wvx',
  802.         'video/x-msvideo' => 'avi',
  803.         'video/x-sgi-movie' => 'movie',
  804.         'video/x-smv' => 'smv',
  805.         'x-conference/x-cooltalk' => 'ice',
  806.     ];
  807.     /**
  808.      * {@inheritdoc}
  809.      */
  810.     public function guess($mimeType)
  811.     {
  812.         if (isset($this->defaultExtensions[$mimeType])) {
  813.             return $this->defaultExtensions[$mimeType];
  814.         }
  815.         $lcMimeType strtolower($mimeType);
  816.         return $this->defaultExtensions[$lcMimeType] ?? null;
  817.     }
  818. }