[
  {
    "path": ".gitignore",
    "content": "build.properties\ntarget\n.project\n.classpath\n*.log\nlog\n"
  },
  {
    "path": "Changelog",
    "content": "Changelog\n---------\n\nChanges since 0.1.2\n\t* changing license over to the Apache license, retro-active to \n\t  0.1.2, since I don't want anyone to have to fetch a new package\n\t  for a simple license change.\n\t* sonatype fixes\n\t* TIFF additions\n\nChanges since 0.1.1\n\t* remove log4j.properties from jar file\n\nChanges since 0.1.0\n\t* changes for target source level\n\t* adjustment for maven 1.1\n\t* project.xml cleanup\n\t* documentation fixes\n\t* various other types of cleanup\n\nChanges since 0.0.4a\n\t* migrated build system to maven 1.x\n\t* moved to subversion\n\t* added hinting flag for file extensions hints\n\t* ability to disable submatches for mime-only detection, which\n\t*   which still needs work (e.g. submatch until a mime is found)\n\t* content detection plugins now supported\n\t* logging switched over to commons-logging\n\t* cleaned up javadoc and enabled site generation\n\t* misc other cleanup\n\nChanges since 0.0.3\n\t* added more unit tests\n\t* fixed sub-matches, adjusted magic.xml DTD\n\t* new magic.xml file converted from unix magic file\n\t* created testByte and testString from testByteArray\n\t* testByte is now available and properly applies bitmask\n\t* api reworking\n\nChanges since 0.0.2\n\t* added junit tests\n\t* removed UTF8 encoding from byte array to String conversions\n\nChanges since 0.0.1\n\t* cleaned up a lot of the code\n\t* added some mime types to the magic file\n\t* have regexes available for magic detection\n\t* misc other fixes\n\n"
  },
  {
    "path": "INFO",
    "content": "\nhttp://sf.net/projects/jmimemagic/\n"
  },
  {
    "path": "LICENSE",
    "content": "\n                                 Apache License\n                           Version 2.0, January 2004\n                        http://www.apache.org/licenses/\n\n   TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION\n\n   1. Definitions.\n\n      \"License\" shall mean the terms and conditions for use, reproduction,\n      and distribution as defined by Sections 1 through 9 of this document.\n\n      \"Licensor\" shall mean the copyright owner or entity authorized by\n      the copyright owner that is granting the License.\n\n      \"Legal Entity\" shall mean the union of the acting entity and all\n      other entities that control, are controlled by, or are under common\n      control with that entity. For the purposes of this definition,\n      \"control\" means (i) the power, direct or indirect, to cause the\n      direction or management of such entity, whether by contract or\n      otherwise, or (ii) ownership of fifty percent (50%) or more of the\n      outstanding shares, or (iii) beneficial ownership of such entity.\n\n      \"You\" (or \"Your\") shall mean an individual or Legal Entity\n      exercising permissions granted by this License.\n\n      \"Source\" form shall mean the preferred form for making modifications,\n      including but not limited to software source code, documentation\n      source, and configuration files.\n\n      \"Object\" form shall mean any form resulting from mechanical\n      transformation or translation of a Source form, including but\n      not limited to compiled object code, generated documentation,\n      and conversions to other media types.\n\n      \"Work\" shall mean the work of authorship, whether in Source or\n      Object form, made available under the License, as indicated by a\n      copyright notice that is included in or attached to the work\n      (an example is provided in the Appendix below).\n\n      \"Derivative Works\" shall mean any work, whether in Source or Object\n      form, that is based on (or derived from) the Work and for which the\n      editorial revisions, annotations, elaborations, or other modifications\n      represent, as a whole, an original work of authorship. For the purposes\n      of this License, Derivative Works shall not include works that remain\n      separable from, or merely link (or bind by name) to the interfaces of,\n      the Work and Derivative Works thereof.\n\n      \"Contribution\" shall mean any work of authorship, including\n      the original version of the Work and any modifications or additions\n      to that Work or Derivative Works thereof, that is intentionally\n      submitted to Licensor for inclusion in the Work by the copyright owner\n      or by an individual or Legal Entity authorized to submit on behalf of\n      the copyright owner. For the purposes of this definition, \"submitted\"\n      means any form of electronic, verbal, or written communication sent\n      to the Licensor or its representatives, including but not limited to\n      communication on electronic mailing lists, source code control systems,\n      and issue tracking systems that are managed by, or on behalf of, the\n      Licensor for the purpose of discussing and improving the Work, but\n      excluding communication that is conspicuously marked or otherwise\n      designated in writing by the copyright owner as \"Not a Contribution.\"\n\n      \"Contributor\" shall mean Licensor and any individual or Legal Entity\n      on behalf of whom a Contribution has been received by Licensor and\n      subsequently incorporated within the Work.\n\n   2. Grant of Copyright License. Subject to the terms and conditions of\n      this License, each Contributor hereby grants to You a perpetual,\n      worldwide, non-exclusive, no-charge, royalty-free, irrevocable\n      copyright license to reproduce, prepare Derivative Works of,\n      publicly display, publicly perform, sublicense, and distribute the\n      Work and such Derivative Works in Source or Object form.\n\n   3. Grant of Patent License. Subject to the terms and conditions of\n      this License, each Contributor hereby grants to You a perpetual,\n      worldwide, non-exclusive, no-charge, royalty-free, irrevocable\n      (except as stated in this section) patent license to make, have made,\n      use, offer to sell, sell, import, and otherwise transfer the Work,\n      where such license applies only to those patent claims licensable\n      by such Contributor that are necessarily infringed by their\n      Contribution(s) alone or by combination of their Contribution(s)\n      with the Work to which such Contribution(s) was submitted. If You\n      institute patent litigation against any entity (including a\n      cross-claim or counterclaim in a lawsuit) alleging that the Work\n      or a Contribution incorporated within the Work constitutes direct\n      or contributory patent infringement, then any patent licenses\n      granted to You under this License for that Work shall terminate\n      as of the date such litigation is filed.\n\n   4. Redistribution. You may reproduce and distribute copies of the\n      Work or Derivative Works thereof in any medium, with or without\n      modifications, and in Source or Object form, provided that You\n      meet the following conditions:\n\n      (a) You must give any other recipients of the Work or\n          Derivative Works a copy of this License; and\n\n      (b) You must cause any modified files to carry prominent notices\n          stating that You changed the files; and\n\n      (c) You must retain, in the Source form of any Derivative Works\n          that You distribute, all copyright, patent, trademark, and\n          attribution notices from the Source form of the Work,\n          excluding those notices that do not pertain to any part of\n          the Derivative Works; and\n\n      (d) If the Work includes a \"NOTICE\" text file as part of its\n          distribution, then any Derivative Works that You distribute must\n          include a readable copy of the attribution notices contained\n          within such NOTICE file, excluding those notices that do not\n          pertain to any part of the Derivative Works, in at least one\n          of the following places: within a NOTICE text file distributed\n          as part of the Derivative Works; within the Source form or\n          documentation, if provided along with the Derivative Works; or,\n          within a display generated by the Derivative Works, if and\n          wherever such third-party notices normally appear. The contents\n          of the NOTICE file are for informational purposes only and\n          do not modify the License. You may add Your own attribution\n          notices within Derivative Works that You distribute, alongside\n          or as an addendum to the NOTICE text from the Work, provided\n          that such additional attribution notices cannot be construed\n          as modifying the License.\n\n      You may add Your own copyright statement to Your modifications and\n      may provide additional or different license terms and conditions\n      for use, reproduction, or distribution of Your modifications, or\n      for any such Derivative Works as a whole, provided Your use,\n      reproduction, and distribution of the Work otherwise complies with\n      the conditions stated in this License.\n\n   5. Submission of Contributions. Unless You explicitly state otherwise,\n      any Contribution intentionally submitted for inclusion in the Work\n      by You to the Licensor shall be under the terms and conditions of\n      this License, without any additional terms or conditions.\n      Notwithstanding the above, nothing herein shall supersede or modify\n      the terms of any separate license agreement you may have executed\n      with Licensor regarding such Contributions.\n\n   6. Trademarks. This License does not grant permission to use the trade\n      names, trademarks, service marks, or product names of the Licensor,\n      except as required for reasonable and customary use in describing the\n      origin of the Work and reproducing the content of the NOTICE file.\n\n   7. Disclaimer of Warranty. Unless required by applicable law or\n      agreed to in writing, Licensor provides the Work (and each\n      Contributor provides its Contributions) on an \"AS IS\" BASIS,\n      WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or\n      implied, including, without limitation, any warranties or conditions\n      of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A\n      PARTICULAR PURPOSE. You are solely responsible for determining the\n      appropriateness of using or redistributing the Work and assume any\n      risks associated with Your exercise of permissions under this License.\n\n   8. Limitation of Liability. In no event and under no legal theory,\n      whether in tort (including negligence), contract, or otherwise,\n      unless required by applicable law (such as deliberate and grossly\n      negligent acts) or agreed to in writing, shall any Contributor be\n      liable to You for damages, including any direct, indirect, special,\n      incidental, or consequential damages of any character arising as a\n      result of this License or out of the use or inability to use the\n      Work (including but not limited to damages for loss of goodwill,\n      work stoppage, computer failure or malfunction, or any and all\n      other commercial damages or losses), even if such Contributor\n      has been advised of the possibility of such damages.\n\n   9. Accepting Warranty or Additional Liability. While redistributing\n      the Work or Derivative Works thereof, You may choose to offer,\n      and charge a fee for, acceptance of support, warranty, indemnity,\n      or other liability obligations and/or rights consistent with this\n      License. However, in accepting such obligations, You may act only\n      on Your own behalf and on Your sole responsibility, not on behalf\n      of any other Contributor, and only if You agree to indemnify,\n      defend, and hold each Contributor harmless for any liability\n      incurred by, or claims asserted against, such Contributor by reason\n      of your accepting any such warranty or additional liability.\n\n   END OF TERMS AND CONDITIONS\n\n   APPENDIX: How to apply the Apache License to your work.\n\n      To apply the Apache License to your work, attach the following\n      boilerplate notice, with the fields enclosed by brackets \"[]\"\n      replaced with your own identifying information. (Don't include\n      the brackets!)  The text should be enclosed in the appropriate\n      comment syntax for the file format. We also recommend that a\n      file or class name and description of purpose be included on the\n      same \"printed page\" as the copyright notice for easier\n      identification within third-party archives.\n\n   Copyright [yyyy] [name of copyright owner]\n\n   Licensed under the Apache License, Version 2.0 (the \"License\");\n   you may not use this file except in compliance with the License.\n   You may obtain a copy of the License at\n\n       http://www.apache.org/licenses/LICENSE-2.0\n\n   Unless required by applicable law or agreed to in writing, software\n   distributed under the License is distributed on an \"AS IS\" BASIS,\n   WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n   See the License for the specific language governing permissions and\n   limitations under the License.\n"
  },
  {
    "path": "LICENSE_HEADER",
    "content": "/*\njMimeMagic(TM) is a Java library for determining the content type of files or\nstreams.  For more information, please email arimus@users.sourceforge.net\n\nCopyright 2003-2012 David Castro\n\nLicensed under the Apache License, Version 2.0 (the \"License\");\nyou may not use this file except in compliance with the License.\nYou may obtain a copy of the License at\n\n    http://www.apache.org/licenses/LICENSE-2.0\n\nUnless required by applicable law or agreed to in writing, software\ndistributed under the License is distributed on an \"AS IS\" BASIS,\nWITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\nSee the License for the specific language governing permissions and\nlimitations under the License.\n*/\n"
  },
  {
    "path": "NOTICE",
    "content": "jMimeMagic\nCopyright 2003-2017 David Castro\n\nContributions:\n  Thanks to the MMBase team (http://www.mmbase.org/) for doing the work of\n  creating the original basis for the XML version of the magic file.\n\n  To contribute code or other help, send an email to arimus@users.sourceforge.net\n  or submit patches/bug reports/etc on the jMimeMagic project page:\n\n      https://github.com/arimus/jmimemagic\n\nDevelopers:\n  David Castro <arimus@users.sourceforge.net>\n  Nate Jones <ndjones@users.sourceforge.net>\n\nProblems/questions/suggestions:\n  David Castro <arimus@user.sourceforge.net>\n\n"
  },
  {
    "path": "README",
    "content": "jMimeMagic (TM) v0.1.5\nCopyright (C) 2003-2017, David Castro\nContact:  David Castro <arimus@users.sourceforge.net>\n\njMimeMagic is a Java library for determining the MIME type of files or streams.\n\nPlease see LICENSE in this directory for jMimeMagic licensing information.  See\nLICENSE_log4j, LICENSE_oro, LICENSE_xerces, LICENSE_junit respectively for\nLog4j, ORO, Xerces2 and JUnit licensing information.  Log4j, ORO, Xerces2 and\nJUnit are bundled with jMimeMagic for convenience.\n\n** NOTE **\nThis API absolutely will change until there is a stable release! Relying on it\nto not change is probably NOT a safe bet.  It is an initial release, given as a\n(hopefully) better than nothing option.  The plan is for this library to become\nmuch cleaner and well-architected, but only time will tell.  The more you show\ninterest in this library/nudge me, the more likely that will be the case.\nComments and feedback greatly welcome.\n\n\nRequirements:\n  Java 2 SDK 1.3+\n  Apache Maven 1.0.2+\n  JUnit 3.8.x\n  Jakarta ORO 2.0.x\n  Commons Logging 1.0.x\n  Log4j 1.2.x\n  Xerces 2.4.0 (optional)\n\nBuilding:\n  type 'mvn clean jar:jar'\n\n  should have your jar file in ./target\n\nTesting:\n  Log4j setting can be modified in resources/log4j.properties\n\n  Run all unit tests\n  ------------------\n  edit build.properties and create the line 'maven.test.skip=true'\n  type 'maven clean test'\n  \n  Run test against a particular file\n  ----------------------------------\n  type 'maven clean run -Dclass=net.sf.jmimemagic.Magic -Dargs=<file to test>'\n  - or - simply ./test <file to test> in a unix shell\n  (this is similar to the 'file' command in *nix)\n\nMaven:\n\n  To add jMimeMagic as a dependency in a Maven project, you can use the\n  following in the dependencies section of your pom.xml.\n\n  <dependency>\n      <groupId>net.sf.jmimemagic</groupId>\n      <artifactId>jmimemagic</artifactId>\n      <version>0.1.3</version>\n  </dependency>\n\nContributions:\n  Thanks to the MMBase team (http://www.mmbase.org/) for doing the work of\n  creating the original basis for the XML version of the magic file.\n\n  To contribute code or other help, send an email to arimus@users.sourceforge.net\n  or submit patches/bug reports/etc on the jMimeMagic project page:\n\n      http://sf.net/projects/jmimemagic/\n\nNotes:\n  Remember that you will need the proper libraries (XML Parser/Xerces2, Log4j,\n  Commons Logging, and ORO) in the classpath for any applications that use\n  jMimeMagic.  If you want to run any of the jUnit tests, then you will also\n  need JUnit in the classpath.\n\nDevelopers:\n  David Castro <arimus@users.sourceforge.net>\n  Nate Jones <ndjones@users.sourceforge.net>\n\nProblems/questions/suggestions:\n  David Castro <arimus@user.sourceforge.net>\n\n"
  },
  {
    "path": "TODO",
    "content": "document the new properties concept\n\nin getProperties() for MagicMatch, return all the submatch properties as well\n\nneed to fix all matchers that are currently invalid for one reason or another,\npossibly spitting out to the logs why they are invalid, which would help the\nprocess and anyone who happens to misconfigure a match in the magic.xml file\n\nneed to convert the old magic file to the new magic file, enable validation\n\nfix sub-match detection (partially fixed, cleanup and add unit tests!!!)\nneed to add more unit tests\n\nneed to audit code and ensure that a properly crafted file can't be used to \n\tcause some security issues and/or system degredation (will always be a prob)\n\nmake the regular expression syntax pluggable, so those who would rather a regex\n\tstyle other than perl can have it their way\n\nfiles that have multiple matches based on the magic file\n\twe can take the first match in one mode and return a collection of matches\n\tin another.\n\nadd in support for % variables in magic file, so that matched data can be used\n\tin the description, printf style?\n\n\tsupport a test token that is a placeholder for the data being able to be\n\tany value and can then be used in a description for subtype.  Or find\n\tanother way to do this...via plugins???\n\nsupport for indirect offsets?\n\nsupport for &, ^ comparators\n\nsupport for multiple string encoding\n\nsupport which allows multiple matches at the same level to be combined for a \n\tfull description\n\nNeed to fix problems with some of the type detection.  Dates haven't really\nbeen worked on.\n\nCreate a tool for analyzing repositories of multiple file types, which will\nhelp determine a proper file \"tag\" that uniquely identifies a file type.\n\nPossibly flesh out the magic file format.  Need support multiple tests to\nmake a definitive determination of file type.\n\nSupport some form of lexical parsing to determine valid source file from\ncode snippets, etc?\n\nLots of other stuff todo, just not listed yet.\n\n==== DONE ====\n\nflag to take hints from file extension as to which matches should be ran first?\n\nflag to run in MIME matching mode, no logic other than what is necessary to\n\tto determine MIME type\n\nswitch to commons-logging\n\nsupport for additional info map, allowing additional information to not be\n\tdisplayed in the description, but be available.  For instance, MP3 file\n\tID3 tags could be made available for mp3 files\n* New properties now in matchers\n\tbasic: now have properties in the style <property name=\"\" value=\"\"/>\n\t       possible for any match.  These will then be available in the\n\t\t   returned MagicMatch as a java Map.  This way, descriptions for a\n\t\t   match can be freeform such as \"ID3 Tag\", but you end up with\n\t\t   id3=true as a key/value pair in the map and don't have to do a silly\n\t\t   string test or assign a new mime type to the submatch.  This will\n\t\t   also support plugins, allowing them to add new properties\n\t\t   dynamically as needed for the match/submatch.\n\nadd \"plugin\" match type by which data will be processed through a plugin for\n    complicated matches and assistance of third-party tools. (detectors)\n"
  },
  {
    "path": "checkstyle.xml",
    "content": "<?xml version=\"1.0\"?>\n<!DOCTYPE module PUBLIC\n    \"-//Puppy Crawl//DTD Check Configuration 1.1//EN\"\n    \"http://www.puppycrawl.com/dtds/configuration_1_1.dtd\">\n\n\n<module name=\"Checker\">\n\n    <!-- Checks that a package.html file exists for each package.     -->\n    <!-- See http://checkstyle.sf.net/config_javadoc.html#PackageHtml -->\n    <module name=\"PackageHtml\"/>\n\n    <!-- Checks whether files end with a new line.                        -->\n    <!-- See http://checkstyle.sf.net/config_misc.html#NewlineAtEndOfFile -->\n    <module name=\"NewlineAtEndOfFile\"/>\n\n    <!-- Checks that property files contain the same keys.         -->\n    <!-- See http://checkstyle.sf.net/config_misc.html#Translation -->\n\t<!--\n    <module name=\"Translation\"/>\n\t-->\n\n    <module name=\"TreeWalker\">\n\n        <property name=\"cacheFile\" value=\"${checkstyle.cache.file}\"/>\n\n        <!-- ************************************************************** -->\n        <!-- Default Sun coding conventions checks                          -->\n        <!-- ************************************************************** -->\n\n        <!-- Checks for Javadoc comments.                     -->\n        <!-- See http://checkstyle.sf.net/config_javadoc.html -->\n        <module name=\"JavadocMethod\"/>\n        <module name=\"JavadocType\"/>\n        <!--<module name=\"JavadocVariable\"/>-->\n\n\n        <!-- Checks for Naming Conventions.                  -->\n        <!-- See http://checkstyle.sf.net/config_naming.html -->\n        <module name=\"LocalFinalVariableName\"/>\n        <module name=\"LocalVariableName\"/>\n        <module name=\"MethodName\"/>\n        <module name=\"PackageName\"/>\n        <module name=\"ParameterName\"/>\n        <module name=\"StaticVariableName\"/>\n        <module name=\"TypeName\"/>\n        <module name=\"MemberName\"/>\n\n        <!-- Checks for imports                              -->\n        <!-- See http://checkstyle.sf.net/config_import.html -->\n        <module name=\"AvoidStarImport\"/>\n        <module name=\"IllegalImport\"/> <!-- defaults to sun.* packages -->\n        <module name=\"RedundantImport\"/>\n        <module name=\"UnusedImports\"/>\n\n        <!-- Miscellaneous other checks.                   -->\n        <module name=\"TodoComment\"/>\n    </module>\n\n</module>\n"
  },
  {
    "path": "maven.xml",
    "content": "<project xmlns:maven=\"jelly:maven\" \r\n\txmlns:ant=\"jelly:ant\" \r\n\txmlns:j=\"jelly:core\" \r\n\txmlns:u=\"jelly:util\" \r\n\txmlns:artifact=\"artifact\">\r\n\r\n\t<goal name=\"run\">\r\n    \t<attainGoal name=\"jar:jar\"/>\r\n\r\n\t\t<echo message=\"Running ${class} ${args}\"/>\r\n\r\n\t\t<java fork=\"true\" dir=\"${basedir}\" classname=\"${class}\">\r\n\t\t\t<arg line=\"${args}\"/>\r\n\t\t\t<ant:classpath>\r\n\t\t\t\t<ant:path refid=\"maven.dependency.classpath\"/>\r\n\t\t\t\t<ant:pathelement path=\"${target.dir}/classes\"/>\r\n\t\t\t</ant:classpath>\r\n\t\t</java>\r\n\t</goal>\r\n</project>\r\n\r\n"
  },
  {
    "path": "pom.xml",
    "content": "<project xmlns=\"http://maven.apache.org/POM/4.0.0\" xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\"\n  xsi:schemaLocation=\"http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd\">\n  <modelVersion>4.0.0</modelVersion>\n\n\n  <!-- General for All Maven projects (lib and proj) -->\n  \n  <groupId>net.sf.jmimemagic</groupId>\n  <artifactId>jmimemagic</artifactId>\n  <version>0.1.5</version>\n  <packaging>jar</packaging>\n\n  <name>jMimeMagic</name>\n  <url>http://github.com/arimus/jmimemagic/</url>\n  <description>jMimeMagic is a Java library for determining the content type of files or streams.</description>\n  <licenses>\n    <license>\n      <name>Apache License, Version 2.0</name>\n      <url>http://www.apache.org/licenses/LICENSE-2.0.txt</url>\n      <distribution>repo</distribution>\n      <comments>A business-friendly OSS license</comments>\n    </license>\n  </licenses>\n\n  <scm>\n    <connection>scm:git:git://github.com/arimus/jmimemagic.git</connection>\n    <developerConnection>scm:git:git://github.com/arimus/jmimemagic.git</developerConnection>\n    <url>https://github.com/arimus/jmimemagic</url>\n  </scm>\n\n  <developers>\n    <developer>\n      <id>arimus</id>\n\t  <name>David Castro</name>\n\t  <email>arimus@users.sourceforge.net</email>\n      <roles>\n         <role>Developer</role>\n      </roles>\n\t  <organization>jmimemagic</organization>\n      <timezone>-7</timezone>\n    </developer>\n\n    <developer>\n\t  <id>ndjones</id>\n\t  <name>Nate Jones</name>\n\t  <email>ndjones@users.sourceforge.net</email>\n      <roles>\n         <role>Developer</role>\n      </roles>\n\t  <organization>jmimemagic</organization>\n      <timezone>-7</timezone>\n    </developer>\n  </developers>\n\n  <!-- use the following if you're not using a snapshot version. -->\n  <distributionManagement>\n    <repository>\n      <id>ossrh</id>\n      <name>jMimeMagic Repo</name>\n      <url>https://oss.sonatype.org/content/repositories/snapshots</url>\n    </repository>\n    <!-- use the following if you ARE using a snapshot version. -->\n    <snapshotRepository>\n      <id>ossrh</id>\n      <name>jMimeMagic Repo</name>\n      <url>https://oss.sonatype.org/content/repositories/snapshots</url>\n    </snapshotRepository>\n  </distributionManagement>\n\n\n  <!-- Repositories, currently used to make hibernate3:schema-export and jalopy work -->\n\n  <!--\n  <repositories>\n    <repository>\n      <id>Codehaus Snapshots</id>\n      <url>http://snapshots.repository.codehaus.org</url>\n      <snapshots>\n        <enabled>true</enabled>\n      </snapshots>\n      <releases>\n        <enabled>false</enabled>\n      </releases>\n    </repository>\n    <repository>\n      <id>maven2-repository.dev.java.net</id>\n      <name>Java.net Repository for Maven</name>\n      <url>http://download.java.net/maven/2</url>\n      <layout>default</layout>\n    </repository>\n    <repository>\n      <id>repository.jboss.com</id>\n      <name>JBoss Repository for Maven</name>\n      <url>http://repository.jboss.com/maven2</url>\n      <layout>default</layout>\n    </repository>\n  </repositories>\n  -->\n\n  <!-- Repositories, currently used to make hibernate3:schema-export work -->\n\n  <!--\n  <pluginRepositories>\n    <pluginRepository>\n      <id>Codehaus Snapshots</id>\n      <url>http://snapshots.repository.codehaus.org</url>\n      <snapshots>\n        <enabled>true</enabled>\n      </snapshots>\n      <releases>\n        <enabled>false</enabled>\n      </releases>\n    </pluginRepository>\n  </pluginRepositories>\n  -->\n\n  <build>\n\n    <!-- turning filter on for resources and test, note - test resources dir will override any file with the same name in main resources when a test is ran.  -->\n    <filters>\n      <filter>src/main/filters/filter.properties</filter>\n    </filters>\n    <resources>\n      <resource>\n        <directory>src/main/resources</directory>\n        <filtering>true</filtering>\n        <includes>\n          <include>*.properties</include>\n          <include>*.xml</include>\n          <include>*.dtd</include>\n          <include>*.json</include>\n        </includes>\n        <excludes>\n          <exclude>log4j.properties</exclude>\n        </excludes>\n      </resource>\n    </resources>\n    <testResources>\n      <testResource>\n        <directory>src/test/resources</directory>\n        <filtering>true</filtering>\n      </testResource>\n      <testResource>\n        <directory>src/main/resources</directory>\n        <filtering>true</filtering>\n      </testResource>\n    </testResources>\n\n    <plugins>\n\n      <!-- Code format java files, use mvn jalopy:format -->\n      <!--\n      <plugin>\n        <groupId>org.codehaus.mojo</groupId>\n        <artifactId>jalopy-maven-plugin</artifactId>\n        <version>1.0-SNAPSHOT</version>\n        <configuration>\n          <convention>geekoffice/jalopy.xml</convention>\n          <failOnError>false</failOnError>\n          <fileFormat>UNIX</fileFormat>\n        </configuration>\n        <executions>\n          <execution>\n            <phase>install</phase>\n            <goals>\n              <goal>format</goal>\n            </goals>\n          </execution>\n        </executions>\n      </plugin>\n      -->\n\n      <!-- compile in jdk 1.5 -->\n      <plugin>\n        <groupId>org.apache.maven.plugins</groupId>\n        <artifactId>maven-compiler-plugin</artifactId>\n        <version>2.3</version>\n        <configuration>\n          <source>1.6</source>\n          <target>1.6</target>\n        </configuration>\n      </plugin>\n\n      <plugin>\n        <groupId>org.apache.maven.plugins</groupId>\n        <artifactId>maven-resources-plugin</artifactId>\n        <version>2.4</version>\n        <configuration>\n          <encoding>${project.build.sourceEncoding}</encoding>\n        </configuration>\n      </plugin>\n\n      <plugin>\n        <groupId>org.apache.maven.plugins</groupId>\n        <artifactId>maven-source-plugin</artifactId>\n        <version>2.2.1</version>\n        <executions>\n          <execution>\n            <id>attach-sources</id>\n            <goals>\n              <goal>jar-no-fork</goal>\n            </goals>\n          </execution>\n        </executions>\n      </plugin>\n\n      <plugin>\n        <groupId>org.apache.maven.plugins</groupId>\n        <artifactId>maven-javadoc-plugin</artifactId>\n        <version>2.9.1</version>\n        <executions>\n          <execution>\n            <id>attach-javadocs</id>\n            <goals>\n              <goal>jar</goal>\n            </goals>\n          </execution>\n        </executions>\n      </plugin>\n\n      <plugin>\n        <groupId>org.codehaus.mojo</groupId>\n        <artifactId>exec-maven-plugin</artifactId>\n        <version>1.2.1</version>\n      </plugin>\n\n      <plugin>\n        <groupId>org.sonatype.plugins</groupId>\n        <artifactId>nexus-staging-maven-plugin</artifactId>\n        <version>1.6.2</version>\n        <extensions>true</extensions>\n        <configuration>\n          <serverId>ossrh</serverId>\n          <nexusUrl>https://oss.sonatype.org/</nexusUrl>\n          <autoReleaseAfterClose>false</autoReleaseAfterClose>\n        </configuration>\n      </plugin>\n\n      <plugin>\n        <groupId>org.apache.maven.plugins</groupId>\n        <artifactId>maven-gpg-plugin</artifactId>\n        <version>1.5</version>\n        <executions>\n          <execution>\n            <id>sign-artifacts</id>\n            <phase>verify</phase>\n            <goals>\n              <goal>sign</goal>\n            </goals>\n          </execution>\n        </executions>\n      </plugin>\n\n    </plugins>\n\n    <extensions>\n\n      <extension>\n        <groupId>org.apache.maven.wagon</groupId>\n         <artifactId>wagon-ssh-external</artifactId>\n         <version>1.0-alpha-5</version>\n      </extension>\n\n    </extensions>\n\n  </build>\n\n  <!-- dependencies need by both lib and proj -->\n\n  <dependencies>\n\n    <!-- common compile time dependencies -->\n\n    <dependency>\n      <groupId>commons-logging</groupId>\n      <artifactId>commons-logging</artifactId>\n      <version>1.0.4</version>\n      <scope>compile</scope>\n    </dependency>\n\n    <dependency>\n      <groupId>commons-io</groupId>\n      <artifactId>commons-io</artifactId>\n      <version>2.1</version>\n      <scope>compile</scope>\n    </dependency>\n\n    <!-- common runtime only dependencies -->\n\n    <dependency>\n      <groupId>log4j</groupId>\n      <artifactId>log4j</artifactId>\n      <version>1.2.8</version>\n      <scope>runtime</scope>\n    </dependency>\n\n\n    <!-- common testing only dependencies -->\n\n    <dependency>\n      <groupId>junit</groupId>\n      <artifactId>junit</artifactId>\n      <version>3.8.1</version>\n      <scope>test</scope>\n    </dependency>\n\n<!--    <dependency>\n      <groupId>com.thoughtworks.xstream</groupId>\n      <artifactId>xstream</artifactId>\n      <version>1.4.3</version>\n      <scope>compile</scope>\n    </dependency>-->\n\n  </dependencies>\n\n  <properties>\n    <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>\n    <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding>\n  </properties>\n\n</project>\n"
  },
  {
    "path": "project.properties",
    "content": "# -------------------------------------------------------------------\n# P R O J E C T  P R O P E R T I E S\n# -------------------------------------------------------------------\n\n# CVS project\nmaven.scm.cvs.module=jmimemagic\n\n# User Interface\nmaven.repo.remote=http://repo1.maven.org/maven\nmaven.xdoc.date=left\nmaven.xdoc.date.format=dd MMMM yyyy HH:mm\nmaven.xdoc.version=${pom.currentVersion}\nmaven.license.licenseFile=${basedir}/LICENSE\n\nmaven.ui.body.background=white\nmaven.ui.body.foreground=black\nmaven.ui.banner.background=white\n\n# Overrides\n\nmaven.jar.override=on\n#maven.jar.oro=${basedir}/lib/jakarta-oro-2.0.7.jar\n\n# FAQ\nmaven.faq.src.file=${basedir}/xdocs/faq.fml\nmaven.faq.dest.file=${basedir}/xdocs/faq.xml\n\n# Checkstyle\nmaven.checkstyle.header.file=${basedir}/LICENSE_HEADER\nmaven.checkstyle.properties=${basedir}/checkstyle.xml\n\n# Changelog\nmaven.changelog.factory=org.apache.maven.svnlib.SvnChangeLogFactory\nmaven.changelog.range=90\n\n# Site generation\nmaven.site.failonerror=false\n\n# Provided documentation\nmaven.docs.src=${basedir}/xdocs\n\n# Remove non-needed links\nmaven.xdoc.developmentProcessUrl=\nmaven.xdoc.poweredby.image=\nmaven.xdoc.poweredby.title=\nmaven.xdoc.poweredby.url=\n\n# Maven compilation\nmaven.compile.debug=on\nmaven.compile.deprecation=off\nmaven.compile.optimize=on\n#maven.compile.executable=jikes\nmaven.compile.target=1.2\nmaven.compile.source=1.2\n\n# Desired coding conventions for checkstyle\nmaven.checkstyle.format=sun\n\ntarget.dir=target\n\nmaven.test.skip=true\n#maven.junit.dir=${maven.test.dest}\n\n"
  },
  {
    "path": "project.xml",
    "content": "<?xml version=\"1.0\" encoding=\"ISO-8859-1\"?>\n<project>\n\t<pomVersion>3</pomVersion>\n\t<id>jmimemagic</id>\n\t<name>Java Mime Magic Library</name>\n\t<currentVersion>0.1.2</currentVersion>\n\t<organization>\n\t\t<name>none</name>\n\t</organization>\n\t<inceptionYear>2003</inceptionYear>\n\t<package>net.sf.jmimemagic</package>\n\t\n\t<shortDescription>Determine the content type of files or streams.</shortDescription>\n\n\t<description>\n\t\tjMimeMagic is a Java library for determining the content type of files or streams.\n\t</description>\n\n\t<repository>\n\t\t<connection>\n\t\t\tscm:svn:https://svn.sourceforge.net/svnroot/jmimemagic/trunk\n\t\t</connection>\n\t\t<developerConnection>\n\t\t\tscm:svn:https://svn.sourceforge.net/svnroot/jmimemagic/trunk\n\t\t</developerConnection>\n\t\t<url>\n\t\t\thttp://svn.sourceforge.net/viewvc/jmimemagic/\n\t\t</url>\n\t</repository>\n\t\t\n\t<build>\n\t\t<nagEmailAddress>arimus@users.sourceforge.net</nagEmailAddress>\n\t\t<sourceDirectory>${basedir}/src/java</sourceDirectory>\t\t\n\t\t<defaultGoal>jar</defaultGoal>\n\t\t<unitTestSourceDirectory>${basedir}/src/test</unitTestSourceDirectory>\n\t\t<unitTest>\n\t\t\t<includes>\n\t\t\t\t<include>**/*Test.java</include>\n\t\t\t</includes>\n\t\t\t<resources>\n\t\t\t\t<resource>\n\t\t\t\t\t<targetPath>/</targetPath>\n\t\t\t\t\t<directory>resources</directory>\n\t\t\t\t\t<filtering>true</filtering>\n\t\t\t\t\t<includes>\n\t\t\t\t\t\t<include>*.properties</include>\n\t\t\t\t\t\t<include>*.xml</include>\n\t\t\t\t\t\t<include>*.dtd</include>\n\t\t\t\t\t</includes>\n\t\t\t\t</resource>\n\t\t\t</resources>\n\t\t</unitTest>\n\t\t<unitTestSourceDirectory>src/test</unitTestSourceDirectory>\n\t\t<resources>\n\t\t\t<resource>\n\t\t\t\t<targetPath>/</targetPath>\n\t\t\t\t<directory>resources</directory>\n\t\t\t\t<filtering>true</filtering>\n\t\t\t\t<includes>\n\t\t\t\t\t<include>*.properties</include>\n\t\t\t\t\t<include>*.xml</include>\n\t\t\t\t\t<include>*.dtd</include>\n\t\t\t\t</includes>\n\t\t\t\t<excludes>\n\t\t\t\t\t<exclude>log4j.properties</exclude>\n\t\t\t\t</excludes>\n\t\t\t</resource>\n\t\t</resources>\n\t</build>\n\n\t<developers>\n\t\t<developer>\n\t\t\t<name>David Castro</name>\n\t\t\t<id>arimus</id>\n\t\t\t<email>arimus@users.sourceforge.net</email>\n\t\t\t<organization>jmimemagic</organization>\n\t\t</developer>\t\t\n\n\t\t<developer>\n\t\t\t<name>Nate Jones</name>\n\t\t\t<id>ndjones</id>\n\t\t\t<email>ndjones@users.sourceforge.net</email>\n\t\t\t<organization>jmimemagic</organization>\n\t\t</developer>\t\t\n\t</developers>\n\t\n\t<!-- J A R  R E S O U R C E S -->\n\t<!-- Resources that are packaged up inside the JAR file -->\n\n\t<!--\n\t<resources>\n\t\t<resource>\n\t\t\t<targetPath>/</targetPath>\n\t\t\t<directory>resources</directory>\n\t\t\t<includes>\n\t\t\t\t<include>*.properties</include>\n\t\t\t\t<include>*.xml</include>\n\t\t\t</includes>\n\t\t</resource>\n\t</resources>\n\t-->\n\n\t<dependencies>\n\t\t<dependency>\n\t\t  <groupId>junit</groupId>\n\t\t  <artifactId>junit</artifactId>\n\t\t  <version>3.8.1</version>\n\t\t  <properties>\n\t\t  \t<scope>test</scope>\n\t\t  </properties>\n\t\t</dependency>\n\n\t\t<dependency>\n\t\t  <groupId>oro</groupId>\n\t\t  <artifactId>oro</artifactId>\n\t\t  <version>2.0.8</version>\n\t\t  <properties>\n\t\t  \t<scope>compile</scope>\n\t\t  </properties>\n\t\t</dependency>\n\n\t\t<dependency>\n\t\t  <groupId>commons-logging</groupId>\n\t\t  <artifactId>commons-logging</artifactId>\n\t\t  <version>1.0.4</version>\n\t\t  <properties>\n\t\t  \t<scope>compile</scope>\n\t\t  </properties>\n\t\t</dependency>\n\n\t\t<dependency>\n\t\t  <groupId>log4j</groupId>\n\t\t  <artifactId>log4j</artifactId>\n\t\t  <version>1.2.8</version>\n\t\t  <properties>\n\t\t  \t<scope>runtime</scope>\n\t\t  </properties>\n\t\t</dependency>\n\n\t\t<dependency>\n\t\t  <groupId>xerces</groupId>\n\t\t  <artifactId>xerces</artifactId>\n\t\t  <version>2.4.0</version>\n\t\t  <properties>\n\t\t  \t<scope>runtime</scope>\n\t\t  </properties>\n\t\t</dependency>\n\n\t\t<dependency>\n\t\t  <groupId>xerces</groupId>\n\t\t  <artifactId>xercesImpl</artifactId>\n\t\t  <version>2.7.1</version>\n\t\t  <properties>\n\t\t  \t<scope>runtime</scope>\n\t\t  </properties>\n\t\t</dependency>\n\n\t\t<dependency>\n\t\t  <groupId>xml-apis</groupId>\n\t\t  <artifactId>xml-apis</artifactId>\n\t\t  <version>2.0.2</version>\n\t\t  <properties>\n\t\t  \t<scope>compile</scope>\n\t\t  </properties>\n\t\t</dependency>\n\n\t\t<dependency>\n\t\t  <groupId>xml-apis</groupId>\n\t\t  <artifactId>xmlParserAPIs</artifactId>\n\t\t  <version>2.0.2</version>\n\t\t  <properties>\n\t\t  \t<scope>compile</scope>\n\t\t  </properties>\n\t\t</dependency>\n\t</dependencies>\n\n</project>\n\n"
  },
  {
    "path": "src/main/filters/filter.properties",
    "content": ""
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/Magic.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\nimport org.apache.commons.logging.Log;\nimport org.apache.commons.logging.LogFactory;\n\nimport java.io.File;\nimport java.io.IOException;\nimport java.io.PrintStream;\n\nimport java.util.ArrayList;\nimport java.util.Collection;\nimport java.util.HashMap;\nimport java.util.Iterator;\nimport java.util.List;\nimport java.util.Map;\n\n\n/**\n * This class is the primary class for jMimeMagic\n *\n * @author $Author: arimus $\n * @version $Revision: 1.8 $\n */\npublic class Magic\n{\n    private static Log log = LogFactory.getLog(Magic.class);\n    private static boolean initialized = false;\n    private static MagicParser magicParser = null;\n    private static Map<String,List<MagicMatcher>> hintMap = new HashMap<String, List<MagicMatcher>>();\n\n    /**\n     * constructor\n     */\n    public Magic()\n    {\n        log.debug(\"instantiated\");\n    }\n\n    /**\n     * Add a hint to use the specified matcher for the given extension\n     * \n     * @param extension DOCUMENT ME!\n     * @param matcher DOCUMENT ME!\n     */\n    private static void addHint(String extension, MagicMatcher matcher)\n    {\n        if (hintMap.keySet().contains(extension)) {\n            List<MagicMatcher> a = hintMap.get(extension);\n            a.add(matcher);\n        } else {\n        \tList<MagicMatcher> a = new ArrayList<MagicMatcher>();\n            a.add(matcher);\n            hintMap.put(extension, a);\n        }\n    }\n\n    /**\n     * create a parser and initialize it\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     */\n    public static synchronized void initialize()\n        throws MagicParseException\n    {\n        log.debug(\"initialize()\");\n\n        if (!initialized) {\n            log.debug(\"initializing\");\n            magicParser = new MagicParser();\n            magicParser.initialize();\n\n            // build hint map\n            Iterator<MagicMatcher> i = magicParser.getMatchers().iterator();\n\n            while (i.hasNext()) {\n                MagicMatcher matcher = i.next();\n                String ext = matcher.getMatch().getExtension();\n\n                if ((ext != null) && !ext.trim().equals(\"\")) {\n                    if (log.isDebugEnabled()) {\n                        log.debug(\"adding hint mapping for extension '\" + ext + \"'\");\n                    }\n\n                    addHint(ext, matcher);\n                } else if (matcher.getMatch().getType().equals(\"detector\")) {\n                    String[] exts = matcher.getDetectorExtensions();\n\n                    for (int j = 0; j < exts.length; j++) {\n                        if (log.isDebugEnabled()) {\n                            log.debug(\"adding hint mapping for extension '\" + exts[j] + \"'\");\n                        }\n\n                        addHint(exts[j], matcher);\n                    }\n                }\n            }\n\n            initialized = true;\n        }\n    }\n\n    /**\n     * return the parsed MagicMatch objects that were created from the magic.xml\n     * definitions\n     *\n     * @return the parsed MagicMatch objects\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     */\n    public static Collection<MagicMatcher> getMatchers()\n        throws MagicParseException\n    {\n        log.debug(\"getMatchers()\");\n\n        if (!initialized) {\n            initialize();\n        }\n\n        Iterator<MagicMatcher> i = magicParser.getMatchers().iterator();\n        List<MagicMatcher> m = new ArrayList<MagicMatcher>();\n\n        while (i.hasNext()) {\n            MagicMatcher matcher = (MagicMatcher) i.next();\n\n            try {\n                m.add(matcher.clone());\n            } catch (CloneNotSupportedException e) {\n                log.error(\"failed to clone matchers\");\n                throw new MagicParseException(\"failed to clone matchers\");\n            }\n        }\n\n        return m;\n    }\n\n    /**\n     * get a match from a stream of data\n     *\n     * @param data DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     * @throws MagicMatchNotFoundException DOCUMENT ME!\n     * @throws MagicException DOCUMENT ME!\n     */\n    public static MagicMatch getMagicMatch(byte[] data)\n        throws MagicParseException, MagicMatchNotFoundException, MagicException\n    {\n        return getMagicMatch(data, false);\n    }\n\n    /**\n     * get a match from a stream of data\n     *\n     * @param data DOCUMENT ME!\n     * @param onlyMimeMatch DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     * @throws MagicMatchNotFoundException DOCUMENT ME!\n     * @throws MagicException DOCUMENT ME!\n     */\n    public static MagicMatch getMagicMatch(byte[] data, boolean onlyMimeMatch)\n        throws MagicParseException, MagicMatchNotFoundException, MagicException\n    {\n        log.debug(\"getMagicMatch(byte[])\");\n\n        if (!initialized) {\n            initialize();\n        }\n\n        Collection<MagicMatcher> matchers = magicParser.getMatchers();\n        log.debug(\"getMagicMatch(byte[]): have \" + matchers.size() + \" matchers\");\n\n        MagicMatcher matcher = null;\n        MagicMatch match = null;\n        Iterator<MagicMatcher> i = matchers.iterator();\n\n        while (i.hasNext()) {\n            matcher = i.next();\n\n            log.debug(\"getMagicMatch(byte[]): trying to match: \" +\n                matcher.getMatch().getMimeType());\n\n            try {\n                if ((match = matcher.test(data, onlyMimeMatch)) != null) {\n                    log.debug(\"getMagicMatch(byte[]): matched \" + matcher.getMatch().getMimeType());\n\n                    return match;\n                }\n            } catch (IOException e) {\n                log.error(\"getMagicMatch(byte[]): \" + e);\n                throw new MagicException(e);\n            } catch (UnsupportedTypeException e) {\n                log.error(\"getMagicMatch(byte[]): \" + e);\n                throw new MagicException(e);\n            }\n        }\n\n        throw new MagicMatchNotFoundException();\n    }\n\n    /**\n     * get a match from a file\n     *\n     * @param file the file to match content in\n     * @param extensionHints whether or not to use extension to optimize order of content tests\n     *\n     * @return the MagicMatch object representing a match in the file\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     * @throws MagicMatchNotFoundException DOCUMENT ME!\n     * @throws MagicException DOCUMENT ME!\n     */\n    public static MagicMatch getMagicMatch(File file, boolean extensionHints)\n        throws MagicParseException, MagicMatchNotFoundException, MagicException\n    {\n        return getMagicMatch(file, extensionHints, false);\n    }\n\n    /**\n     * get a match from a file\n     *\n     * @param file the file to match content in\n     * @param extensionHints whether or not to use extension to optimize order of content tests\n     * @param onlyMimeMatch only try to get mime type, no submatches are processed when true\n     *\n     * @return the MagicMatch object representing a match in the file\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     * @throws MagicMatchNotFoundException DOCUMENT ME!\n     * @throws MagicException DOCUMENT ME!\n     */\n    public static MagicMatch getMagicMatch(File file, boolean extensionHints, boolean onlyMimeMatch)\n        throws MagicParseException, MagicMatchNotFoundException, MagicException\n    {\n        log.debug(\"getMagicMatch(File)\");\n\n        if (!initialized) {\n            initialize();\n        }\n\n        long start = System.currentTimeMillis();\n\n        MagicMatcher matcher = null;\n        MagicMatch match = null;\n\n        // check for extension hints\n        List<MagicMatcher> checked = new ArrayList<MagicMatcher>();\n\n        if (extensionHints) {\n            log.debug(\"trying to use hints first\");\n\n            String name = file.getName();\n            int pos = name.lastIndexOf('.');\n\n            if (pos > -1) {\n                String ext = name.substring(pos + 1, name.length());\n\n                if ((ext != null) && !ext.equals(\"\")) {\n                    if (log.isDebugEnabled()) {\n                        log.debug(\"using extension '\" + ext + \"' for hinting\");\n                    }\n\n                    Collection<MagicMatcher> c = hintMap.get(ext);\n\n                    if (c != null) {\n                        Iterator<MagicMatcher> i = c.iterator();\n\n                        while (i.hasNext()) {\n                            matcher = (MagicMatcher) i.next();\n\n                            log.debug(\"getMagicMatch(File): trying to match: \" +\n                                matcher.getMatch().getDescription());\n\n                            try {\n                                if ((match = matcher.test(file, onlyMimeMatch)) != null) {\n                                    log.debug(\"getMagicMatch(File): matched \" +\n                                        matcher.getMatch().getDescription());\n\n                                    if (log.isDebugEnabled()) {\n                                        long end = System.currentTimeMillis();\n                                        log.debug(\"found match in '\" + (end - start) +\n                                            \"' milliseconds\");\n                                    }\n\n                                    return match;\n                                }\n                            } catch (UnsupportedTypeException e) {\n                                log.error(\"getMagicMatch(File): \" + e);\n                                throw new MagicException(e);\n                            } catch (IOException e) {\n                                log.error(\"getMagicMatch(File): \" + e);\n                                throw new MagicException(e);\n                            }\n\n                            // add to the already checked list\n                            checked.add(matcher);\n                        }\n                    }\n                } else {\n                    log.debug(\"no file extension, ignoring hints\");\n                }\n            } else {\n                log.debug(\"no file extension, ignoring hints\");\n            }\n        }\n\n        Collection<MagicMatcher> matchers = magicParser.getMatchers();\n        log.debug(\"getMagicMatch(File): have \" + matchers.size() + \" matches\");\n\n        Iterator<MagicMatcher> i = matchers.iterator();\n\n        while (i.hasNext()) {\n            matcher = (MagicMatcher) i.next();\n\n            if (!checked.contains(matcher)) {\n                log.debug(\"getMagicMatch(File): trying to match: \" +\n                    matcher.getMatch().getDescription());\n\n                try {\n                    if ((match = matcher.test(file, onlyMimeMatch)) != null) {\n                        log.debug(\"getMagicMatch(File): matched \" +\n                            matcher.getMatch().getDescription());\n\n                        if (log.isDebugEnabled()) {\n                            long end = System.currentTimeMillis();\n                            log.debug(\"found match in '\" + (end - start) + \"' milliseconds\");\n                        }\n\n                        return match;\n                    }\n                } catch (UnsupportedTypeException e) {\n                    log.error(\"getMagicMatch(File): \" + e);\n                    throw new MagicException(e);\n                } catch (IOException e) {\n                    log.error(\"getMagicMatch(File): \" + e);\n                    throw new MagicException(e);\n                }\n            } else {\n                log.debug(\"getMagicMatch(File): already checked, skipping: \" +\n                    matcher.getMatch().getDescription());\n            }\n        }\n\n        throw new MagicMatchNotFoundException();\n    }\n\n    /**\n     * print the contents of a magic file\n     *\n     * @param stream DOCUMENT ME!\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     */\n    public static void printMagicFile(PrintStream stream)\n        throws MagicParseException\n    {\n        if (!initialized) {\n            initialize();\n        }\n\n        Collection<MagicMatcher> matchers = Magic.getMatchers();\n        log.debug(\"have \" + matchers.size() + \" matches\");\n\n        MagicMatcher matcher = null;\n        Iterator<MagicMatcher> i = matchers.iterator();\n\n        while (i.hasNext()) {\n            matcher = (MagicMatcher) i.next();\n            log.debug(\"printing\");\n            printMagicMatcher(stream, matcher, \"\");\n        }\n    }\n\n    /**\n     * print a magic match\n     *\n     * @param stream DOCUMENT ME!\n     * @param matcher DOCUMENT ME!\n     * @param spacing DOCUMENT ME!\n     */\n    private static void printMagicMatcher(PrintStream stream, MagicMatcher matcher, String spacing)\n    {\n        stream.println(spacing + \"name: \" + matcher.getMatch().getDescription());\n        stream.println(spacing + \"children: \");\n\n        Collection<MagicMatcher> matchers = matcher.getSubMatchers();\n        Iterator<MagicMatcher> i = matchers.iterator();\n\n        while (i.hasNext()) {\n            printMagicMatcher(stream, (MagicMatcher) i.next(), spacing + \"  \");\n        }\n    }\n\n    /**\n     * print a magic match\n     *\n     * @param stream DOCUMENT ME!\n     * @param match DOCUMENT ME!\n     * @param spacing DOCUMENT ME!\n     */\n    public static void printMagicMatch(PrintStream stream, MagicMatch match, String spacing)\n    {\n        stream.println(spacing + \"=============================\");\n        stream.println(spacing + \"mime type: \" + match.getMimeType());\n        stream.println(spacing + \"description: \" + match.getDescription());\n        stream.println(spacing + \"extension: \" + match.getExtension());\n        stream.println(spacing + \"test: \" + new String(match.getTest().array()));\n        stream.println(spacing + \"bitmask: \" + match.getBitmask());\n        stream.println(spacing + \"offset: \" + match.getOffset());\n        stream.println(spacing + \"length: \" + match.getLength());\n        stream.println(spacing + \"type: \" + match.getType());\n        stream.println(spacing + \"comparator: \" + match.getComparator());\n        stream.println(spacing + \"=============================\");\n\n        Collection<MagicMatch> submatches = match.getSubMatches();\n        Iterator<MagicMatch> i = submatches.iterator();\n\n        while (i.hasNext()) {\n            printMagicMatch(stream, (MagicMatch) i.next(), spacing + \"    \");\n        }\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param args DOCUMENT ME!\n     */\n    public static void main(String[] args)\n    {\n        try {\n            if (args.length == 0) {\n                System.err.println(\"usage: test <file>\");\n                System.exit(1);;\n            }\n            File f = new File(args[0]);\n\n            if (f.exists()) {\n                MagicMatch match = Magic.getMagicMatch(f, true, false);\n\n                System.out.println(\"filename: \" + args[0]);\n                printMagicMatch(System.out, match, \"\");\n            } else {\n                System.err.println(\"file '\" + f.getCanonicalPath() + \"' not found\");\n            }\n        } catch (MagicMatchNotFoundException e) {\n            System.out.println(\"no match found\");\n        } catch (Exception e) {\n            System.err.println(\"error: \" + e);\n            e.printStackTrace(System.err);\n        }\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/MagicDetector.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\nimport java.io.File;\n\nimport java.util.Map;\n\n\n/**\n * DOCUMENT ME!\n *\n * @author $Author$\n * @version $Revision$\n  */\npublic interface MagicDetector\n{\n    // get the short name of this detector\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String getName();\n\n    // get the display name of this detector\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String getDisplayName();\n\n    // get the version of this plugin\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String getVersion();\n\n    // get a list of types this detector handles\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] getHandledTypes();\n\n    // get a list of file extensions this detector typically deals with\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] getHandledExtensions();\n\n    // process the stream and return all matching content types\n    /**\n     * DOCUMENT ME!\n     *\n     * @param data DOCUMENT ME!\n     * @param offset DOCUMENT ME!\n     * @param length DOCUMENT ME!\n     * @param bitmask DOCUMENT ME!\n     * @param comparator DOCUMENT ME!\n     * @param mimeType DOCUMENT ME!\n     * @param params DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] process(byte[] data, int offset, int length, long bitmask, char comparator,\n        String mimeType, Map<String,String> params);\n\n    // process the file and return all matching content types\n    /**\n     * DOCUMENT ME!\n     *\n     * @param file DOCUMENT ME!\n     * @param offset DOCUMENT ME!\n     * @param length DOCUMENT ME!\n     * @param bitmask DOCUMENT ME!\n     * @param comparator DOCUMENT ME!\n     * @param mimeType DOCUMENT ME!\n     * @param params DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] process(File file, int offset, int length, long bitmask, char comparator,\n        String mimeType, Map<String,String> params);\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/MagicException.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\n/**\n * Basic JMimeMagic parse exception. This is simply a holder to identify a parsing problem. It\n * should be extended to identify more specific issues.\n *\n * @author $Author: arimus $\n * @version $Revision: 1.1 $\n */\npublic class MagicException extends Exception\n{\n/**\n         * Default constructor\n         */\n    public MagicException()\n    {\n        super();\n    }\n\n/**\n         * Create exception with error message\n         * \n         * @param message The error message for this exception\n         */\n    public MagicException(String message)\n    {\n        super(message);\n    }\n\n/**\n         * Create exception based on an existing Throwable\n         * \n         * @param cause The throwable on which we'll base this exception\n         */\n    public MagicException(Throwable cause)\n    {\n        super(cause);\n    }\n\n/**\n         * Create an exception with custom message and throwable info\n         * \n         * @param message The message\n         * @param cause The target Throwable\n         */\n    public MagicException(String message, Throwable cause)\n    {\n        super(message, cause);\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/MagicMatch.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\nimport org.apache.commons.logging.Log;\nimport org.apache.commons.logging.LogFactory;\n\nimport java.nio.ByteBuffer;\n\nimport java.util.ArrayList;\nimport java.util.Collection;\nimport java.util.HashMap;\nimport java.util.Iterator;\nimport java.util.List;\nimport java.util.Map;\n\n\n/**\n * This class represents a single match test\n *\n * @author $Author: arimus $\n * @version $Revision: 1.10 $\n */\npublic class MagicMatch implements Cloneable\n{\n    private static Log log = LogFactory.getLog(MagicMatch.class);\n    private String mimeType = null;\n    private String extension = null;\n    private String description = null;\n    private ByteBuffer test = null;\n    private int offset = 0;\n    private int length = 0;\n\n    // possible types:\n    //     byte, short, long, string, date, beshort, belong, bedate, leshort,\n    //     lelong, ledate, regex\n    private String type = \"\";\n    private long bitmask = 0xFFFFFFFFL;\n    private char comparator = '\\0';\n    private List<MagicMatch> subMatches = new ArrayList<MagicMatch>(0);\n    private Map<String,String> properties;\n\n    /** \n     * constructor \n     */\n    public MagicMatch()\n    {\n        log.debug(\"instantiated\");\n    }\n\n    /**\n     * print information about this match\n     *\n     * @return DOCUMENT ME!\n     */\n    public String print()\n    {\n        StringBuffer string = new StringBuffer();\n        string.append(\"\\n\");\n        string.append(\"mime type: \").append(mimeType).append(\"\\n\");\n        string.append(\"description: \").append(description).append(\"\\n\");\n        string.append(\"extension: \").append(extension).append(\"\\n\");\n        string.append(\"offset: \").append(offset).append(\"\\n\");\n        string.append(\"length: \").append(length).append(\"\\n\");\n        string.append(\"test: \").append(new String(test.array())).append(\"\\n\");\n        string.append(\"type: \").append(type).append(\"\\n\");\n        string.append(\"comparator: \").append(comparator).append(\"\\n\");\n        string.append(\"bitmask: \").append(bitmask);\n\n        return string.toString();\n    }\n\n    /**\n     * set the mime type for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setMimeType(String value)\n    {\n        mimeType = value;\n    }\n\n    /**\n     * get the magic match for this magic match\n     *\n     * @return the mime type for this magic match\n     */\n    public String getMimeType()\n    {\n        return mimeType;\n    }\n\n    /**\n     * set the extension for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setExtension(String value)\n    {\n        extension = value;\n    }\n\n    /**\n     * get the extension for this magic match\n     *\n     * @return the extension for this magic match\n     */\n    public String getExtension()\n    {\n        return extension;\n    }\n\n    /**\n     * set the description for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setDescription(String value)\n    {\n        description = value;\n    }\n\n    /**\n     * get the description for this magic match\n     *\n     * @return the description for thie magic match\n     */\n    public String getDescription()\n    {\n        return description;\n    }\n\n    /**\n     * set the test value for thie magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setTest(ByteBuffer value)\n    {\n        test = value;\n    }\n\n    /**\n     * get the test value for this magic match\n     *\n     * @return DOCUMENT ME!\n     */\n    public ByteBuffer getTest()\n    {\n        return test;\n    }\n\n    /**\n     * set the offset in the stream we are comparing to the test value for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setOffset(int value)\n    {\n        this.offset = value;\n    }\n\n    /**\n     * get the offset in the stream we are comparing to the test value for this magic match\n     *\n     * @return the offset for this magic match\n     */\n    public int getOffset()\n    {\n        return offset;\n    }\n\n    /**\n     * set the length we are restricting the comparison to for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setLength(int value)\n    {\n        this.length = value;\n    }\n\n    /**\n     * get the length we are restricting the comparison to for this magic match\n     *\n     * @return DOCUMENT ME!\n     */\n    public int getLength()\n    {\n        return length;\n    }\n\n    /**\n     * set the type of match to perform for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setType(String value)\n    {\n        this.type = value;\n    }\n\n    /**\n     * get the type of match for this magic match\n     *\n     * @return DOCUMENT ME!\n     */\n    public String getType()\n    {\n        return type;\n    }\n\n    /**\n     * set the bitmask that will be applied for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setBitmask(String value)\n    {\n        if (value != null) {\n            this.bitmask = Long.decode(value).intValue();\n        }\n    }\n\n    /**\n     * get the bitmask that will be applied for this magic match\n     *\n     * @return the bitmask for this magic match\n     */\n    public long getBitmask()\n    {\n        return bitmask;\n    }\n\n    /**\n     * set the comparator for this magic match\n     *\n     * @param value DOCUMENT ME!\n     */\n    public void setComparator(String value)\n    {\n        this.comparator = value.charAt(0);\n    }\n\n    /**\n     * get the comparator for this magic match\n     *\n     * @return the comparator for this magic match\n     */\n    public char getComparator()\n    {\n        return comparator;\n    }\n\n    /**\n     * set the properties for this magic match\n     *\n     * @param properties DOCUMENT ME!\n     */\n    public void setProperties(Map<String,String> properties)\n    {\n        this.properties = properties;\n    }\n\n    /**\n     * get the properties for this magic match\n     *\n     * @return the properties for this magic match\n     */\n    public Map<String,String> getProperties()\n    {\n        return properties;\n    }\n\n    /**\n     * add a submatch to this magic match\n     *\n     * @param m a magic match\n     */\n    public void addSubMatch(MagicMatch m)\n    {\n        log.debug(\"adding submatch '\" + m.getDescription() + \"' to '\" + getDescription() + \"'\");\n        subMatches.add(m);\n    }\n\n    /**\n     * set all submatches\n     *\n     * @param a a collection of submatches\n     */\n    public void setSubMatches(Collection<MagicMatch> a)\n    {\n        log.debug(\"setting submatches for '\" + getDescription() + \"'\");\n        subMatches.clear();\n        subMatches.addAll(a);\n    }\n\n    /**\n     * get all submatches for this magic match\n     *\n     * @return a collection of submatches\n     */\n    public Collection<MagicMatch> getSubMatches()\n    {\n        return subMatches;\n    }\n\n    /**\n     * determine if this match or any submatches has the description\n     *\n     * @param desc DOCUMENT ME!\n     *\n     * @return whether or not the description matches\n     */\n    public boolean descriptionMatches(String desc)\n    {\n        if ((description != null) && description.equals(desc)) {\n            return true;\n        }\n\n        Collection<MagicMatch> submatches = getSubMatches();\n        Iterator<MagicMatch> i = submatches.iterator();\n        MagicMatch m = null;\n\n        while (i.hasNext()) {\n            m = (MagicMatch) i.next();\n\n            if (m.descriptionMatches(desc)) {\n                return true;\n            }\n        }\n\n        return false;\n    }\n\n    /**\n     * determine if this match or any submatches has the description\n     *\n     * @param desc DOCUMENT ME!\n     *\n     * @return whether or not the description matches\n     */\n    public boolean mimeTypeMatches(String desc)\n    {\n        if ((mimeType != null) && mimeType.equals(desc)) {\n            return true;\n        }\n\n        Collection<MagicMatch> submatches = getSubMatches();\n        Iterator<MagicMatch> i = submatches.iterator();\n        MagicMatch m = null;\n\n        while (i.hasNext()) {\n            m = (MagicMatch) i.next();\n\n            if (m.mimeTypeMatches(desc)) {\n                return true;\n            }\n        }\n\n        return false;\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     *\n     * @throws CloneNotSupportedException DOCUMENT ME!\n     */\n    protected Object clone()\n        throws CloneNotSupportedException\n    {\n        MagicMatch clone = new MagicMatch();\n        clone.setBitmask(Long.toString(bitmask, 8));\n        clone.setComparator(\"\" + comparator);\n        clone.setDescription(description);\n        clone.setExtension(extension);\n        clone.setLength(length);\n        clone.setMimeType(mimeType);\n        clone.setOffset(offset);\n\n        // these properties should only be String types, so we shouldn't have to clone them\n        if(properties!= null) {\n\t        Map<String,String> m = new HashMap<String, String>();\n\t        m.putAll(properties);\n\t        clone.setProperties(m);\n        }\n\n        Iterator<MagicMatch> i = subMatches.iterator();\n        List<MagicMatch> a = new ArrayList<MagicMatch>();\n\n        while (i.hasNext()) {\n            MagicMatch mm = i.next();\n            a.add(mm);\n        }\n\n        clone.setSubMatches(a);\n\n        clone.setTest(test);\n        clone.setType(type);\n\n        // TODO Auto-generated method stub\n        return clone;\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/MagicMatchNotFoundException.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\n/**\n * Basic JMimeMagic parse exception. This is simply a holder to identify a parsing problem. It\n * should be extended to identify more specific issues.\n *\n * @author $Author: arimus $\n * @version $Revision: 1.1 $\n */\npublic class MagicMatchNotFoundException extends Exception\n{\n    /** \n     * constructor \n     */\n    public MagicMatchNotFoundException()\n    {\n        super();\n    }\n\n    /**\n     * Create exception with error message\n     * \n     * @param message The error message for this exception\n     */\n    public MagicMatchNotFoundException(String message)\n    {\n        super(message);\n    }\n\n    /**\n     * Create exception based on an existing Throwable\n     * \n     * @param cause The throwable on which we'll base this exception\n     */\n    public MagicMatchNotFoundException(Throwable cause)\n    {\n        super(cause);\n    }\n\n    /**\n     * Create an exception with custom message and throwable info\n     * \n     * @param message The message\n     * @param cause The target Throwable\n     */\n    public MagicMatchNotFoundException(String message, Throwable cause)\n    {\n        super(message, cause);\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/MagicMatcher.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\nimport org.apache.commons.logging.Log;\nimport org.apache.commons.logging.LogFactory;\n\nimport java.io.File;\nimport java.io.IOException;\nimport java.io.RandomAccessFile;\n\nimport java.nio.ByteBuffer;\nimport java.nio.ByteOrder;\n\nimport java.util.ArrayList;\nimport java.util.Collection;\nimport java.util.Iterator;\nimport java.util.List;\nimport java.util.regex.Pattern;\n\n\n/**\n * This class represents a single match test\n *\n * @author $Author: arimus $\n * @version $Revision: 1.1 $\n */\npublic class MagicMatcher implements Cloneable\n{\n    private static Log log = LogFactory.getLog(MagicMatcher.class);\n    private List<MagicMatcher> subMatchers = new ArrayList<MagicMatcher>(0);\n    private MagicMatch match = null;\n\n    /** \n     * constructor \n     */\n    public MagicMatcher()\n    {\n        log.debug(\"instantiated\");\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param match DOCUMENT ME!\n     */\n    public void setMatch(MagicMatch match)\n    {\n        log.debug(\"setMatch()\");\n        this.match = match;\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public MagicMatch getMatch()\n    {\n        log.debug(\"getMatch()\");\n\n        return this.match;\n    }\n\n    /**\n     * test to see if everything is in order for this match\n     *\n     * @return whether or not this match has enough data to be valid\n     */\n    public boolean isValid()\n    {\n        log.debug(\"isValid()\");\n\n        if ((match == null) || (match.getTest() == null)) {\n            return false;\n        }\n\n        String type = new String(match.getTest().array());\n        char comparator = match.getComparator();\n        String description = match.getDescription();\n        String test = new String(match.getTest().array());\n\n        if ((type != null) && !type.equals(\"\") && (comparator != '\\0') &&\n                ((comparator == '=') || (comparator == '!') || (comparator == '>') ||\n                (comparator == '<')) && (description != null) && !description.equals(\"\") &&\n                (test != null) && !test.equals(\"\")) {\n            return true;\n        }\n\n        return false;\n    }\n\n    /**\n     * add a submatch to this magic match\n     *\n     * @param m a magic match\n     */\n    public void addSubMatcher(MagicMatcher m)\n    {\n        log.debug(\"addSubMatcher()\");\n        subMatchers.add(m);\n    }\n\n    /**\n     * set all submatches\n     *\n     * @param a a collection of submatches\n     */\n    public void setSubMatchers(Collection<MagicMatcher> a)\n    {\n        log.debug(\"setSubMatchers(): for match '\" + match.getDescription() + \"'\");\n        subMatchers.clear();\n        subMatchers.addAll(a);\n    }\n\n    /**\n     * get all submatches for this magic match\n     *\n     * @return a collection of submatches\n     */\n    public Collection<MagicMatcher> getSubMatchers()\n    {\n        log.debug(\"getSubMatchers()\");\n\n        return subMatchers;\n    }\n\n    /**\n     * test to see if this match or any submatches match\n     *\n     * @param f the file that should be used to test the match\n     * @param onlyMimeMatch DOCUMENT ME!\n     *\n     * @return the deepest magic match object that matched\n     *\n     * @throws IOException DOCUMENT ME!\n     * @throws UnsupportedTypeException DOCUMENT ME!\n     */\n    public MagicMatch test(File f, boolean onlyMimeMatch)\n        throws IOException, UnsupportedTypeException\n    {\n        log.debug(\"test(File)\");\n\n        int offset = match.getOffset();\n        String description = match.getDescription();\n        String type = match.getType();\n\n        log.debug(\"test(File): testing '\" + f.getName() + \"' for '\" + description + \"'\");\n\n        log.debug(\"test(File): \\n=== BEGIN MATCH INFO ==\");\n        log.debug(match.print());\n        log.debug(\"test(File): \\n=== END MATCH INFO ====\\n\");\n\n        RandomAccessFile file = null;\n        file = new RandomAccessFile(f, \"r\");\n\n        try {\n            int length = 0;\n\n            if (type.equals(\"byte\")) {\n                length = 1;\n            } else if (type.equals(\"short\") || type.equals(\"leshort\") || type.equals(\"beshort\")) {\n                length = 4;\n            } else if (type.equals(\"long\") || type.equals(\"lelong\") || type.equals(\"belong\")) {\n                length = 8;\n            } else if (type.equals(\"string\")) {\n                length = match.getTest().capacity();\n            } else if (type.equals(\"regex\")) {\n                \n                \n                final int matchLength = match.getLength();\n                length = (matchLength == 0) ? (int) file.length() - offset : matchLength;\n\n                if (length < 0) {\n                    length = 0;\n                }\n            } else if (type.equals(\"detector\")) {\n                length = (int) file.length() - offset;\n\n                if (length < 0) {\n                    length = 0;\n                }\n            } else {\n                throw new UnsupportedTypeException(\"unsupported test type '\" + type + \"'\");\n            }\n\n            // we know this match won't work since there isn't enough data for the test\n            if (length > (file.length() - offset)) {\n                return null;\n            }\n\n            byte[] buf = new byte[length];\n            file.seek(offset);\n\n            int bytesRead = 0;\n            int size = 0;\n            boolean gotAllBytes = false;\n            boolean done = false;\n\n            while (!done) {\n                size = file.read(buf, 0, length - bytesRead);\n\n                if (size == -1) {\n                    throw new IOException(\"reached end of file before all bytes were read\");\n                }\n\n                bytesRead += size;\n\n                if (bytesRead == length) {\n                    gotAllBytes = true;\n                    done = true;\n                }\n            }\n\n            log.debug(\"test(File): stream size is '\" + buf.length + \"'\");\n\n            MagicMatch match = null;\n            MagicMatch submatch = null;\n\n            if (testInternal(buf)) {\n                // set the top level match to this one\n                try {\n                    match = getMatch() != null ? (MagicMatch) getMatch()\n                            .clone() : null;\n                } catch (CloneNotSupportedException e) {\n                    // noop\n                }\n\n                log.debug(\"test(File): testing matched '\" + description + \"'\");\n\n                // set the data on this match\n                if ((onlyMimeMatch == false) && (subMatchers != null) && (subMatchers.size() > 0)) {\n                    log.debug(\"test(File): testing \" + subMatchers.size() + \" submatches for '\" +\n                        description + \"'\");\n\n                    for (int i = 0; i < subMatchers.size(); i++) {\n                        log.debug(\"test(File): testing submatch \" + i);\n\n                        MagicMatcher m = (MagicMatcher) subMatchers.get(i);\n\n                        if ((submatch = m.test(f, false)) != null) {\n                            log.debug(\"test(File): submatch \" + i + \" matched with '\" +\n                                submatch.getDescription() + \"'\");\n                            match.addSubMatch(submatch);\n                        } else {\n                            log.debug(\"test(File): submatch \" + i + \" doesn't match\");\n                        }\n                    }\n                }\n            }\n\n            return match;\n        } finally {\n            try {\n                file.close();\n            } catch (Exception fce) {\n            }\n        }\n    }\n\n    /**\n     * test to see if this match or any submatches match\n     *\n     * @param data the data that should be used to test the match\n     * @param onlyMimeMatch DOCUMENT ME!\n     *\n     * @return the deepest magic match object that matched\n     *\n     * @throws IOException DOCUMENT ME!\n     * @throws UnsupportedTypeException DOCUMENT ME!\n     */\n    public MagicMatch test(byte[] data, boolean onlyMimeMatch)\n        throws IOException, UnsupportedTypeException\n    {\n        log.debug(\"test(byte[])\");\n\n        int offset = match.getOffset();\n        String description = match.getDescription();\n        String type = match.getType();\n        String test = new String(match.getTest().array());\n        String mimeType = match.getMimeType();\n\n        log.debug(\"test(byte[]): testing byte[] data for '\" + description + \"'\");\n\n        log.debug(\"test(byte[]): \\n=== BEGIN MATCH INFO ==\");\n        log.debug(match.print());\n        log.debug(\"test(byte[]): \\n=== END MATCH INFO ====\\n\");\n\n        int length = 0;\n\n        if (type.equals(\"byte\")) {\n            length = 1;\n        } else if (type.equals(\"short\") || type.equals(\"leshort\") || type.equals(\"beshort\")) {\n            length = 4;\n        } else if (type.equals(\"long\") || type.equals(\"lelong\") || type.equals(\"belong\")) {\n            length = 8;\n        } else if (type.equals(\"string\")) {\n            length = match.getTest().capacity();\n        } else if (type.equals(\"regex\")) {\n            // FIXME - something wrong here, shouldn't have to subtract 1???\n            length = data.length - offset - 1;\n\n            if (length < 0) {\n                length = 0;\n            }\n        } else if (type.equals(\"detector\")) {\n            // FIXME - something wrong here, shouldn't have to subtract 1???\n            length = data.length - offset - 1;\n\n            if (length < 0) {\n                length = 0;\n            }\n        } else {\n            throw new UnsupportedTypeException(\"unsupported test type \" + type);\n        }\n\n        byte[] buf = new byte[length];\n        log.debug(\"test(byte[]): offset=\" + offset + \",length=\" + length + \",data length=\" +\n            data.length);\n\n        if ((offset + length) < data.length) {\n            System.arraycopy(data, offset, buf, 0, length);\n\n            log.debug(\"test(byte[]): stream size is '\" + buf.length + \"'\");\n\n            MagicMatch match = null;\n            MagicMatch submatch = null;\n\n            if (testInternal(buf)) {\n                // set the top level match to this one\n                try {\n                    match = getMatch() != null ? (MagicMatch) getMatch()\n                            .clone() : null;\n                } catch (CloneNotSupportedException e) {\n                    // noop\n                }\n\n                log.debug(\"test(byte[]): testing matched '\" + description + \"'\");\n\n                // set the data on this match\n                if ((onlyMimeMatch == false) && (subMatchers != null) && (subMatchers.size() > 0)) {\n                    log.debug(\"test(byte[]): testing \" + subMatchers.size() + \" submatches for '\" +\n                        description + \"'\");\n\n                    for (int i = 0; i < subMatchers.size(); i++) {\n                        log.debug(\"test(byte[]): testing submatch \" + i);\n\n                        MagicMatcher m = (MagicMatcher) subMatchers.get(i);\n\n                        if ((submatch = m.test(data, false)) != null) {\n                            log.debug(\"test(byte[]): submatch \" + i + \" matched with '\" +\n                                submatch.getDescription() + \"'\");\n                            match.addSubMatch(submatch);\n                        } else {\n                            log.debug(\"test(byte[]): submatch \" + i + \" doesn't match\");\n                        }\n                    }\n                }\n            }\n\n            return match;\n        } else {\n            return null;\n        }\n    }\n\n    /**\n     * internal test switch\n     * \n     * @param data DOCUMENT ME!\n     * @return DOCUMENT ME!\n     */\n    private boolean testInternal(byte[] data)\n    {\n        log.debug(\"testInternal(byte[])\");\n\n        if (data.length == 0) {\n            return false;\n        }\n\n        String type = match.getType();\n        String test = new String(match.getTest().array());\n        String mimeType = match.getMimeType();\n        String description = match.getDescription();\n\n        ByteBuffer buffer = ByteBuffer.allocate(data.length);\n\n        if ((type != null) && (test != null) && (test.length() > 0)) {\n            if (type.equals(\"string\")) {\n                buffer = buffer.put(data);\n\n                return testString(buffer);\n            } else if (type.equals(\"byte\")) {\n                buffer = buffer.put(data);\n\n                return testByte(buffer);\n            } else if (type.equals(\"short\")) {\n                buffer = buffer.put(data);\n\n                return testShort(buffer);\n            } else if (type.equals(\"leshort\")) {\n                buffer = buffer.put(data);\n                buffer.order(ByteOrder.LITTLE_ENDIAN);\n\n                return testShort(buffer);\n            } else if (type.equals(\"beshort\")) {\n                buffer = buffer.put(data);\n                buffer.order(ByteOrder.BIG_ENDIAN);\n\n                return testShort(buffer);\n            } else if (type.equals(\"long\")) {\n                buffer = buffer.put(data);\n\n                return testLong(buffer);\n            } else if (type.equals(\"lelong\")) {\n                buffer = buffer.put(data);\n                buffer.order(ByteOrder.LITTLE_ENDIAN);\n\n                return testLong(buffer);\n            } else if (type.equals(\"belong\")) {\n                buffer = buffer.put(data);\n                buffer.order(ByteOrder.BIG_ENDIAN);\n\n                return testLong(buffer);\n            } else if (type.equals(\"regex\")) {\n                return testRegex(new String(data));\n            } else if (type.equals(\"detector\")) {\n                buffer = buffer.put(data);\n\n                return testDetector(buffer);\n\n                //\t\t\t} else if (type.equals(\"date\")) {\n                //\t\t\t\treturn testDate(data, BIG_ENDIAN);\n                //\t\t\t} else if (type.equals(\"ledate\")) {\n                //\t\t\t\treturn testDate(data, LITTLE_ENDIAN);\n                //\t\t\t} else if (type.equals(\"bedate\")) {\n                //\t\t\t\treturn testDate(data, BIG_ENDIAN);\n            } else {\n                log.error(\"testInternal(byte[]): invalid test type '\" + type + \"'\");\n            }\n        } else {\n            log.error(\"testInternal(byte[]): type or test is empty for '\" + mimeType + \" - \" +\n                description + \"'\");\n        }\n\n        return false;\n    }\n\n    /**\n     * test the data against the test byte\n     *\n     * @param data the data we are testing\n     *\n     * @return if we have a match\n     */\n    private boolean testByte(ByteBuffer data)\n    {\n        log.debug(\"testByte()\");\n\n        String test = new String(match.getTest().array());\n        char comparator = match.getComparator();\n        long bitmask = match.getBitmask();\n\n        String s = test;\n        byte b = data.get(0);\n        b = (byte) (b & bitmask);\n        log.debug(\"testByte(): decoding '\" + test + \"' to byte\");\n\n        int tst = Integer.decode(test).byteValue();\n        byte t = (byte) (tst & 0xff);\n        log.debug(\"testByte(): applying bitmask '\" + bitmask + \"' to '\" + tst + \"', result is '\" +\n            t + \"'\");\n        log.debug(\"testByte(): comparing byte '\" + b + \"' to '\" + t + \"'\");\n\n        switch (comparator) {\n        case '=':\n            return t == b;\n\n        case '!':\n            return t != b;\n\n        case '>':\n            return t > b;\n\n        case '<':\n            return t < b;\n        }\n\n        return false;\n    }\n\n    /**\n     * test the data against the byte array\n     *\n     * @param data the data we are testing\n     *\n     * @return if we have a match\n     */\n    private boolean testString(ByteBuffer data)\n    {\n        log.debug(\"testString()\");\n\n        ByteBuffer test = match.getTest();\n        char comparator = match.getComparator();\n\n        byte[] b = data.array();\n        byte[] t = test.array();\n\n        boolean diff = false;\n        int i = 0;\n\n        for (i = 0; i < t.length; i++) {\n            log.debug(\"testing byte '\" + b[i] + \"' from '\" + new String(data.array()) +\n                \"' against byte '\" + t[i] + \"' from '\" + new String(test.array()) + \"'\");\n\n            if (t[i] != b[i]) {\n                diff = true;\n\n                break;\n            }\n        }\n\n        switch (comparator) {\n        case '=':\n            return !diff;\n\n        case '!':\n            return diff;\n\n        case '>':\n            return t[i] > b[i];\n\n        case '<':\n            return t[i] < b[i];\n        }\n\n        return false;\n    }\n\n    /**\n     * test the data against a short\n     *\n     * @param data the data we are testing\n     *\n     * @return if we have a match\n     */\n    private boolean testShort(ByteBuffer data)\n    {\n        log.debug(\"testShort()\");\n\n        short val = 0;\n        String test = new String(match.getTest().array());\n        char comparator = match.getComparator();\n        long bitmask = match.getBitmask();\n\n        val = byteArrayToShort(data);\n\n        // apply bitmask before the comparison\n        val = (short) (val & (short) bitmask);\n\n        short tst = 0;\n\n        try {\n            tst = Integer.decode(test).shortValue();\n        } catch (NumberFormatException e) {\n            log.error(\"testShort(): \" + e);\n\n            return false;\n\n            //if (test.length() == 1) {\t\n            //\ttst = new Integer(Character.getNumericValue(test.charAt(0))).shortValue();\n            //}\n        }\n\n        log.debug(\"testShort(): testing '\" + Long.toHexString(val) + \"' against '\" +\n            Long.toHexString(tst) + \"'\");\n\n        switch (comparator) {\n        case '=':\n            return val == tst;\n\n        case '!':\n            return val != tst;\n\n        case '>':\n            return val > tst;\n\n        case '<':\n            return val < tst;\n        }\n\n        return false;\n    }\n\n    /**\n     * test the data against a long\n     *\n     * @param data the data we are testing\n     *\n     * @return if we have a match\n     */\n    private boolean testLong(ByteBuffer data)\n    {\n        log.debug(\"testLong()\");\n\n        long val = 0;\n        String test = new String(match.getTest().array());\n        char comparator = match.getComparator();\n        long bitmask = match.getBitmask();\n\n        val = byteArrayToLong(data);\n\n        // apply bitmask before the comparison\n        val = val & bitmask;\n\n        long tst = Long.decode(test).longValue();\n\n        log.debug(\"testLong(): testing '\" + Long.toHexString(val) + \"' against '\" + test +\n            \"' => '\" + Long.toHexString(tst) + \"'\");\n\n        switch (comparator) {\n        case '=':\n            return val == tst;\n\n        case '!':\n            return val != tst;\n\n        case '>':\n            return val > tst;\n\n        case '<':\n            return val < tst;\n        }\n\n        return false;\n    }\n\n    /**\n     * test the data against a regex\n     *\n     * @param text the data we are testing\n     *\n     * @return if we have a match\n     */\n    private boolean testRegex(String text)\n    {\n        log.debug(\"testRegex()\");\n\n        String test = new String(match.getTest().array());\n        char comparator = match.getComparator();\n\n        log.debug(\"testRegex(): searching for '\" + test + \"'\");\n\n        if (comparator == '=') {\n            if (Pattern.matches(test, text)) {\n                return true;\n            } else {\n                return false;\n            }\n        } else if (comparator == '!') {\n            if (Pattern.matches(test, text)) {\n                return false;\n            } else {\n                return true;\n            }\n        }\n\n        return false;\n    }\n\n    /**\n     * test the data using a detector\n     *\n     * @param data the data we are testing\n     *\n     * @return if we have a match\n     */\n    private boolean testDetector(ByteBuffer data)\n    {\n        log.debug(\"testDetector()\");\n\n        String detectorClass = new String(match.getTest().array());\n\n        try {\n            log.debug(\"loading class: \" + detectorClass);\n\n            Class<?> c = Class.forName(detectorClass);\n            MagicDetector detector = (MagicDetector) c.newInstance();\n            String[] types = detector.process(data.array(), match.getOffset(), match.getLength(),\n                    match.getBitmask(), match.getComparator(), match.getMimeType(),\n                    match.getProperties());\n\n            if ((types != null) && (types.length > 0)) {\n                // the match object has no mime type set, so set from the detector class processing\n                match.setMimeType(types[0]);\n\n                return true;\n            }\n        } catch (ClassNotFoundException e) {\n            log.error(\"failed to load detector: \" + detectorClass, e);\n        } catch (InstantiationException e) {\n            log.error(\"specified class is not a valid detector class: \" + detectorClass, e);\n        } catch (IllegalAccessException e) {\n            log.error(\"specified class cannot be accessed: \" + detectorClass, e);\n        }\n\n        return false;\n    }\n\n    /**\n     * Get the extensions for the underlying detectory\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] getDetectorExtensions()\n    {\n        log.debug(\"testDetector()\");\n\n        String detectorClass = new String(match.getTest().array());\n\n        try {\n            log.debug(\"loading class: \" + detectorClass);\n\n            Class<?> c = Class.forName(detectorClass);\n            MagicDetector detector = (MagicDetector) c.newInstance();\n\n            return detector.getHandledTypes();\n        } catch (ClassNotFoundException e) {\n            log.error(\"failed to load detector: \" + detectorClass, e);\n        } catch (InstantiationException e) {\n            log.error(\"specified class is not a valid detector class: \" + detectorClass, e);\n        } catch (IllegalAccessException e) {\n            log.error(\"specified class cannot be accessed: \" + detectorClass, e);\n        }\n\n        return new String[0];\n    }\n\n    /**\n     * encode a byte as an octal string\n     *\n     * @param b a byte of data\n     *\n     * @return an octal representation of the byte data\n     */\n    private String byteToOctalString(byte b)\n    {\n        int n1;\n        int n2;\n        int n3;\n        n1 = (b / 32) & 7;\n        n2 = (b / 8) & 7;\n        n3 = b & 7;\n\n        return String.valueOf(n1) + String.valueOf(n2) + String.valueOf(n3);\n    }\n\n    /**\n     * convert a byte array to a short\n     *\n     * @param data buffer of byte data\n     *\n     * @return byte array converted to a short\n     */\n    private short byteArrayToShort(ByteBuffer data)\n    {\n        return data.getShort(0);\n    }\n\n    /**\n     * convert a byte array to a long\n     *\n     * @param data buffer of byte data\n     *\n     * @return byte arrays (high and low bytes) converted to a long value\n     */\n    private long byteArrayToLong(ByteBuffer data)\n    {\n        return (long) data.getInt(0);\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     *\n     * @throws CloneNotSupportedException DOCUMENT ME!\n     */\n    protected MagicMatcher clone()\n        throws CloneNotSupportedException\n    {\n        MagicMatcher clone = new MagicMatcher();\n\n        clone.setMatch((MagicMatch) match.clone());\n\n        Iterator<MagicMatcher> i = subMatchers.iterator();\n        List<MagicMatcher> sub = new ArrayList<MagicMatcher>();\n\n        while (i.hasNext()) {\n            MagicMatcher m = (MagicMatcher) i.next();\n            sub.add(m.clone());\n        }\n\n        clone.setSubMatchers(sub);\n\n        return clone;\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/MagicParseException.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\n/**\n * Basic JMimeMagic parse exception. This is simply a holder to identify a parsing problem. It\n * should be extended to identify more specific issues.\n *\n * @author $Author: arimus $\n * @version $Revision: 1.1 $\n */\npublic class MagicParseException extends Exception\n{\n    /**\n     * Default constructor\n     */\n    public MagicParseException()\n    {\n        super();\n    }\n\n    /**\n     * Create exception with error message\n     * \n     * @param message The error message for this exception\n     */\n    public MagicParseException(String message)\n    {\n        super(message);\n    }\n\n    /**\n     * Create exception based on an existing Throwable\n     * \n     * @param cause The throwable on which we'll base this exception\n     */\n    public MagicParseException(Throwable cause)\n    {\n        super(cause);\n    }\n\n    /**\n     * Create an exception with custom message and throwable info\n     * \n     * @param message The message\n     * @param cause The target Throwable\n     */\n    public MagicParseException(String message, Throwable cause)\n    {\n        super(message, cause);\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/MagicParser.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\nimport org.apache.commons.logging.Log;\nimport org.apache.commons.logging.LogFactory;\n\nimport org.xml.sax.Attributes;\nimport org.xml.sax.ContentHandler;\nimport org.xml.sax.ErrorHandler;\nimport org.xml.sax.SAXException;\nimport org.xml.sax.SAXNotRecognizedException;\nimport org.xml.sax.SAXNotSupportedException;\nimport org.xml.sax.SAXParseException;\nimport org.xml.sax.XMLReader;\nimport org.xml.sax.helpers.DefaultHandler;\nimport org.xml.sax.helpers.XMLReaderFactory;\n\nimport java.io.ByteArrayOutputStream;\nimport java.net.URL;\nimport java.nio.ByteBuffer;\n\nimport java.util.ArrayList;\nimport java.util.Collection;\nimport java.util.HashMap;\nimport java.util.List;\nimport java.util.Map;\n\n\n/**\n * DOCUMENT ME!\n *\n * @author $Author$\n * @version $Revision$\n  */\npublic class MagicParser extends DefaultHandler implements ContentHandler, ErrorHandler\n{\n    private static String magicFile = \"/magic.xml\";\n    private static Log log = LogFactory.getLog(MagicParser.class);\n\n    // Namespaces feature id (http://xml.org/sax/features/namespaces).\n    protected static final String NAMESPACES_FEATURE_ID = \"http://xml.org/sax/features/namespaces\";\n\n    // Validation feature id (http://xml.org/sax/features/validation). \n    protected static final String VALIDATION_FEATURE_ID = \"http://xml.org/sax/features/validation\";\n\n    // Schema validation feature id (http://apache.org/xml/features/validation/schema). \n    protected static final String SCHEMA_VALIDATION_FEATURE_ID = \"http://apache.org/xml/features/validation/schema\";\n\n    // Schema full checking feature id (http://apache.org/xml/features/validation/schema-full-checking). \n    protected static final String SCHEMA_FULL_CHECKING_FEATURE_ID = \"http://apache.org/xml/features/validation/schema-full-checking\";\n\n    // Default parser name. \n    protected static final String DEFAULT_PARSER_NAME = \"org.apache.xerces.parsers.SAXParser\";\n\n    // Default namespaces support (true). \n    protected static final boolean DEFAULT_NAMESPACES = true;\n\n    // Default validation support (false). \n    protected static final boolean DEFAULT_VALIDATION = false;\n\n    // Default Schema validation support (false). \n    protected static final boolean DEFAULT_SCHEMA_VALIDATION = false;\n\n    // Default Schema full checking support (false). \n    protected static final boolean DEFAULT_SCHEMA_FULL_CHECKING = false;\n    private boolean initialized = false;\n    private XMLReader parser = null;\n    private List<MagicMatcher> stack = new ArrayList<MagicMatcher>();\n    private Collection<MagicMatcher> matchers = new ArrayList<MagicMatcher>();\n    private MagicMatcher matcher = null;\n    private MagicMatch match = null;\n    private Map<String,String> properties = null;\n    private String finalValue = \"\";\n    private boolean isMimeType = false;\n    private boolean isExtension = false;\n    private boolean isDescription = false;\n    private boolean isTest = false;\n\n    /** \n     * constructor \n     */\n    public MagicParser()\n    {\n        log.debug(\"instantiated\");\n    }\n\n    /**\n     * parse the xml file and create our MagicMatcher object list\n     *\n     * @throws MagicParseException DOCUMENT ME!\n     */\n    public synchronized void initialize()\n        throws MagicParseException\n    {\n        boolean namespaces = DEFAULT_NAMESPACES;\n        boolean validation = DEFAULT_VALIDATION;\n        boolean schemaValidation = DEFAULT_SCHEMA_VALIDATION;\n        boolean schemaFullChecking = DEFAULT_SCHEMA_FULL_CHECKING;\n\n        if (!initialized) {\n            // use default parser\n            try {\n                parser = XMLReaderFactory.createXMLReader();\n            } catch (Exception e) {\n                try {\n                    log.debug(\"falling back to default parser: \" + DEFAULT_PARSER_NAME);\n                    parser = XMLReaderFactory.createXMLReader(DEFAULT_PARSER_NAME);\n                } catch (Exception ee) {\n                    throw new MagicParseException(\"unable to instantiate parser\");\n                }\n            }\n\n            // set parser features\n            try {\n                parser.setFeature(NAMESPACES_FEATURE_ID, namespaces);\n            } catch (SAXException e) {\n                log.debug(\"initialize(): warning: Parser does not support feature (\" +\n                    NAMESPACES_FEATURE_ID + \")\");\n            }\n\n            try {\n                parser.setFeature(VALIDATION_FEATURE_ID, validation);\n            } catch (SAXException e) {\n                log.debug(\"initialize(): warning: Parser does not support feature (\" +\n                    VALIDATION_FEATURE_ID + \")\");\n            }\n\n            try {\n                parser.setFeature(SCHEMA_VALIDATION_FEATURE_ID, schemaValidation);\n            } catch (SAXNotRecognizedException e) {\n                // ignore\n            } catch (SAXNotSupportedException e) {\n                log.debug(\"initialize(): warning: Parser does not support feature (\" +\n                    SCHEMA_VALIDATION_FEATURE_ID + \")\");\n            }\n\n            try {\n                parser.setFeature(SCHEMA_FULL_CHECKING_FEATURE_ID, schemaFullChecking);\n            } catch (SAXNotRecognizedException e) {\n                // ignore\n            } catch (SAXNotSupportedException e) {\n                log.debug(\"initialize(): warning: Parser does not support feature (\" +\n                    SCHEMA_FULL_CHECKING_FEATURE_ID + \")\");\n            }\n\n            // set handlers\n            parser.setErrorHandler(this);\n            parser.setContentHandler(this);\n\n            // parse file\n            try {\n                // get the magic file URL\n                URL resource = MagicParser.class.getResource(magicFile);\n\t\t\t\tString magicURL = resource.toString();\n\n                if (magicURL == null) {\n                    log.error(\"initialize(): couldn't load '\" + magicURL + \"'\");\n                    throw new MagicParseException(\"couldn't load '\" + magicURL + \"'\");\n                }\n\n                parser.parse(magicURL);\n            } catch (SAXParseException e) {\n                // ignore\n            } catch (Exception e) {\n                e.printStackTrace();\n                throw new MagicParseException(\"parse error occurred - \" + e.getMessage());\n            }\n\n            initialized = true;\n        }\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public Collection<MagicMatcher> getMatchers()\n    {\n        return matchers;\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void startDocument()\n        throws SAXException\n    {\n        log.debug(\"startDocument()\");\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void endDocument()\n        throws SAXException\n    {\n        log.debug(\"endDocument()\");\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param target DOCUMENT ME!\n     * @param data DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void processingInstruction(String target, String data)\n        throws SAXException\n    {\n        // do nothing\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param ch DOCUMENT ME!\n     * @param offset DOCUMENT ME!\n     * @param length DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void characters(char[] ch, int offset, int length)\n        throws SAXException\n    {\n        String value = new String(ch, offset, length);\n        log.debug(\"characters(): value is '\" + value + \"'\");\n\n        finalValue += value;\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param ch DOCUMENT ME!\n     * @param offset DOCUMENT ME!\n     * @param length DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void ignorableWhitespace(char[] ch, int offset, int length)\n        throws SAXException\n    {\n        // do nothing\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param uri DOCUMENT ME!\n     * @param localName DOCUMENT ME!\n     * @param qname DOCUMENT ME!\n     * @param attributes DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void startElement(String uri, String localName, String qname, Attributes attributes)\n        throws SAXException\n    {\n        log.debug(\"startElement()\");\n        log.debug(\"startElement(): localName is '\" + localName + \"'\");\n\n        // create a new matcher\n        if (localName.equals(\"match\")) {\n            log.debug(\"startElement(): creating new matcher\");\n            // match to hold data\n            match = new MagicMatch();\n            // our matcher\n            matcher = new MagicMatcher();\n            matcher.setMatch(match);\n        }\n\n        // these are subelements of matcher, but also occur elsewhere\n        if (matcher != null) {\n            if (localName.equals(\"mimetype\")) {\n                isMimeType = true;\n            } else if (localName.equals(\"extension\")) {\n                isExtension = true;\n            } else if (localName.equals(\"description\")) {\n                isDescription = true;\n            } else if (localName.equals(\"test\")) {\n                isTest = true;\n\n                int length = attributes.getLength();\n\n                for (int i = 0; i < length; i++) {\n                    String attrLocalName = attributes.getLocalName(i);\n                    String attrValue = attributes.getValue(i);\n\n                    if (attrLocalName.equals(\"offset\")) {\n                        if (!attrValue.equals(\"\")) {\n                            match.setOffset(new Integer(attrValue).intValue());\n                            log.debug(\"startElement():   setting offset to '\" + attrValue + \"'\");\n                        }\n                    } else if (attrLocalName.equals(\"length\")) {\n                        if (!attrValue.equals(\"\")) {\n                            match.setLength(new Integer(attrValue).intValue());\n                            log.debug(\"startElement():   setting length to '\" + attrValue + \"'\");\n                        }\n                    } else if (attrLocalName.equals(\"type\")) {\n                        match.setType(attrValue);\n                        log.debug(\"startElement():   setting type to '\" + attrValue + \"'\");\n                    } else if (attrLocalName.equals(\"bitmask\")) {\n                        if (!attrValue.equals(\"\")) {\n                            match.setBitmask(attrValue);\n                            log.debug(\"startElement():   setting bitmask to '\" + attrValue + \"'\");\n                        }\n                    } else if (attrLocalName.equals(\"comparator\")) {\n                        match.setComparator(attrValue);\n                        log.debug(\"startElement():   setting comparator to '\" + attrValue + \"'\");\n                    }\n                }\n            } else if (localName.equals(\"property\")) {\n                int length = attributes.getLength();\n                String name = null;\n                String value = null;\n\n                for (int i = 0; i < length; i++) {\n                    String attrLocalName = attributes.getLocalName(i);\n                    String attrValue = attributes.getValue(i);\n\n                    if (attrLocalName.equals(\"name\")) {\n                        if (!attrValue.equals(\"\")) {\n                            name = attrValue;\n                        }\n                    } else if (attrLocalName.equals(\"value\")) {\n                        if (!attrValue.equals(\"\")) {\n                            value = attrValue;\n                        }\n                    }\n                }\n\n                // save the property to our map\n                if ((name != null) && (value != null)) {\n                    if (properties == null) {\n                        properties = new HashMap<String, String>();\n                    }\n\n                    if (!properties.containsKey(name)) {\n                        properties.put(name, value);\n                        log.debug(\"startElement():   setting property '\" + name + \"'='\" + value +\n                            \"'\");\n                    } else {\n                        log.debug(\"startElement():   not setting property '\" + name +\n                            \"', duplicate key\");\n                    }\n                }\n            } else if (localName.equals(\"match-list\")) {\n                log.debug(\"startElement(): found submatcher list\");\n\n                // this means we are processing a child match, so we need to push\n                // the existing match on the stack\n                log.debug(\"startElement(): pushing current matcher to stack\");\n                stack.add(matcher);\n            } else {\n                // we don't care about this type\n            }\n        }\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param uri DOCUMENT ME!\n     * @param localName DOCUMENT ME!\n     * @param qname DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void endElement(String uri, String localName, String qname)\n        throws SAXException\n    {\n        log.debug(\"endElement()\");\n        log.debug(\"endElement(): localName is '\" + localName + \"'\");\n\n        // determine which tag these chars are for and save them\n        if (isMimeType) {\n            isMimeType = false;\n            match.setMimeType(finalValue);\n            log.debug(\"characters(): setting mimetype to '\" + finalValue + \"'\");\n        } else if (isExtension) {\n            isExtension = false;\n            match.setExtension(finalValue);\n            log.debug(\"characters(): setting extension to '\" + finalValue + \"'\");\n        } else if (isDescription) {\n            isDescription = false;\n            match.setDescription(finalValue);\n            log.debug(\"characters(): setting description to '\" + finalValue + \"'\");\n        } else if (isTest) {\n            isTest = false;\n            match.setTest(convertOctals(finalValue));\n            log.debug(\"characters(): setting test to '\" + convertOctals(finalValue) + \"'\");\n        } else {\n            // do nothing\n        }\n\n        finalValue = \"\";\n\n        // need to save the current matcher here if it is filled out enough and\n        // we have an /matcher\n        if (localName.equals(\"match\")) {\n            // FIXME - make sure the MagicMatcher isValid() test works\n            if (matcher.isValid()) {\n                // set the collected properties on this matcher\n                match.setProperties(properties);\n\n                // add root match\n                if (stack.size() == 0) {\n                    log.debug(\"endElement(): adding root matcher\");\n                    matchers.add(matcher);\n                } else {\n                    // we need to add the match to it's parent which is on the\n                    // stack\n                    log.debug(\"endElement(): adding sub matcher\");\n\n                    MagicMatcher m = (MagicMatcher) stack.get(stack.size() - 1);\n                    m.addSubMatcher(matcher);\n                }\n            } else {\n                // don't add invalid matchers\n                log.info(\"endElement(): not adding invalid matcher '\" + match.getDescription() +\n                    \"'\");\n            }\n\n            matcher = null;\n            properties = null;\n\n            // restore matcher from the stack if we have an /matcher-list\n        } else if (localName.equals(\"match-list\")) {\n            if (stack.size() > 0) {\n                log.debug(\"endElement(): popping from the stack\");\n                matcher = (MagicMatcher) stack.get(stack.size() - 1);\n                // pop from the stack\n                stack.remove(matcher);\n            }\n        } else if (localName.equals(\"mimetype\")) {\n            isMimeType = false;\n        } else if (localName.equals(\"extension\")) {\n            isExtension = false;\n        } else if (localName.equals(\"description\")) {\n            isDescription = false;\n        } else if (localName.equals(\"test\")) {\n            isTest = false;\n        }\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param ex DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void warning(SAXParseException ex)\n        throws SAXException\n    {\n        // FIXME\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param ex DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void error(SAXParseException ex)\n        throws SAXException\n    {\n        // FIXME\n        throw ex;\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param ex DOCUMENT ME!\n     *\n     * @throws SAXException DOCUMENT ME!\n     */\n    public void fatalError(SAXParseException ex)\n        throws SAXException\n    {\n        // FIXME\n        throw ex;\n    }\n\n    /**\n     * replaces octal representations of bytes, written as \\ddd to actual byte values.\n     *\n     * @param s a string with encoded octals\n     *\n     * @return string with all octals decoded\n     */\n    private ByteBuffer convertOctals(String s)\n    {\n        int beg = 0;\n        int end = 0;\n        int chr;\n        ByteArrayOutputStream buf = new ByteArrayOutputStream();\n\n        while ((end = s.indexOf('\\\\', beg)) != -1) {\n            if (s.charAt(end + 1) != '\\\\') {\n                //log.debug(\"appending chunk '\"+s.substring(beg, end)+\"'\");\n                for (int z = beg; z < end; z++) {\n                    buf.write((int) s.charAt(z));\n                }\n\n                //log.debug(\"found \\\\ at position \"+end);\n                //log.debug(\"converting octal '\"+s.substring(end, end+4)+\"'\");\n                if ((end + 4) <= s.length()) {\n                    try {\n                        chr = Integer.parseInt(s.substring(end + 1, end + 4), 8);\n\n                        //log.debug(\"converted octal '\"+s.substring(end+1,end+4)+\"' to '\"+chr);\n                        //log.debug(\"converted octal back to '\"+Integer.toOctalString(chr));\n\n                        //log.debug(\"converted '\"+s.substring(end+1,end+4)+\"' to \"+chr+\"/\"+((char)chr));\n                        buf.write(chr);\n                        beg = end + 4;\n                        end = beg;\n                    } catch (NumberFormatException nfe) {\n                        //log.debug(\"not an octal\");\n                        buf.write((int) '\\\\');\n                        beg = end + 1;\n                        end = beg;\n                    }\n                } else {\n                    //log.debug(\"not an octal, not enough chars left in string\");\n                    buf.write((int) '\\\\');\n                    beg = end + 1;\n                    end = beg;\n                }\n            } else {\n                //log.debug(\"appending \\\\\");\n                buf.write((int) '\\\\');\n                beg = end + 1;\n                end = beg;\n            }\n        }\n\n        if (end < s.length()) {\n            for (int z = beg; z < s.length(); z++) {\n                buf.write((int) s.charAt(z));\n            }\n        }\n\n        try {\n            log.debug(\"convertOctals(): returning buffer size '\" + buf.size() + \"'\");\n\n            ByteBuffer b = ByteBuffer.allocate(buf.size());\n\n            return b.put(buf.toByteArray());\n        } catch (Exception e) {\n            log.error(\"convertOctals(): error parsing string: \" + e);\n\n            return ByteBuffer.allocate(0);\n        }\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/UnsupportedTypeException.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic;\n\n/**\n * JMimeMagic unsupported test type exception. This exception is thrown when an unsupported\n * test type is specified in a mime magic test\n *\n * @author $Author: arimus $\n * @version $Revision: 1.1 $\n */\npublic class UnsupportedTypeException extends Exception\n{\n    /**\n     * Default constructor\n     */\n    public UnsupportedTypeException()\n    {\n        super();\n    }\n\n    /**\n     * Create exception with error message\n     * \n     * @param message The error message for this exception\n     */\n    public UnsupportedTypeException(String message)\n    {\n        super(message);\n    }\n\n    /**\n     * Create exception based on an existing Throwable\n     * \n     * @param cause The throwable on which we'll base this exception\n     */\n    public UnsupportedTypeException(Throwable cause)\n    {\n        super(cause);\n    }\n\n    /**\n     * Create an exception with custom message and throwable info\n     * \n     * @param message The message\n     * @param cause The target Throwable\n     */\n    public UnsupportedTypeException(String message, Throwable cause)\n    {\n        super(message, cause);\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/detectors/TextFileDetector.java",
    "content": "/*\njMimeMagic (TM) is a Java Library for determining the content type of files or streams\nCopyright (C) 2003-2017 David Castro\n*/\npackage net.sf.jmimemagic.detectors;\n\nimport net.sf.jmimemagic.MagicDetector;\n\nimport org.apache.commons.io.ByteOrderMark;\nimport org.apache.commons.io.IOUtils;\nimport org.apache.commons.io.input.BOMInputStream;\nimport org.apache.commons.logging.Log;\nimport org.apache.commons.logging.LogFactory;\n\nimport java.io.*;\n\nimport java.util.Map;\nimport java.util.regex.Pattern;\n\n\n/**\n * DOCUMENT ME!\n *\n * @author $Author$\n * @version $Revision$\n  */\npublic class TextFileDetector implements MagicDetector\n{\n    private static Log log = LogFactory.getLog(TextFileDetector.class);\n\n    /**\n     * Creates a new TextFileDetector object.\n     */\n    public TextFileDetector()\n    {\n        super();\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String getDisplayName()\n    {\n        return \"Text File Detector\";\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String getVersion()\n    {\n        return \"0.1\";\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] getHandledExtensions()\n    {\n        return new String[] { \"txt\", \"text\" };\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] getHandledTypes()\n    {\n        return new String[] { \"text/plain\" };\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String getName()\n    {\n        return \"textfiledetector\";\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param data DOCUMENT ME!\n     * @param offset DOCUMENT ME!\n     * @param length DOCUMENT ME!\n     * @param bitmask DOCUMENT ME!\n     * @param comparator DOCUMENT ME!\n     * @param mimeType DOCUMENT ME!\n     * @param params DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] process(byte[] data, int offset, int length, long bitmask, char comparator,\n        String mimeType, Map<String,String> params)\n    {\n        log.debug(\"processing stream data\");\n\n        BOMInputStream bomIn = null;\n        try {\n            bomIn = new BOMInputStream(new ByteArrayInputStream(data), ByteOrderMark.UTF_8, ByteOrderMark.UTF_16LE, ByteOrderMark.UTF_16BE);\n            if (bomIn.hasBOM()) {\n                return new String[] { \"text/plain\" };\n            }\n        } catch (IOException e) {\n            log.error(\"TextFileDetector: error detecting byte order mark\");\n        } finally {\n        \tIOUtils.closeQuietly(bomIn);\n        }\n\n        try {\n            String s = new String(data, \"UTF-8\");\n\n            if (!Pattern.matches(\"/[^[:ascii:][:space:]]/\", s)) {\n                return new String[] { \"text/plain\" };\n            }\n        } catch (UnsupportedEncodingException e) {\n            log.error(\"TextFileDetector: failed to process data\");\n        }\n\n        return null;\n    }\n\n    /**\n     * DOCUMENT ME!\n     *\n     * @param file DOCUMENT ME!\n     * @param offset DOCUMENT ME!\n     * @param length DOCUMENT ME!\n     * @param bitmask DOCUMENT ME!\n     * @param comparator DOCUMENT ME!\n     * @param mimeType DOCUMENT ME!\n     * @param params DOCUMENT ME!\n     *\n     * @return DOCUMENT ME!\n     */\n    public String[] process(File file, int offset, int length, long bitmask, char comparator,\n        String mimeType, Map<String,String> params)\n    {\n        log.debug(\"processing file data\");\n\n        BufferedInputStream is =null;\n        try {\n            is = new BufferedInputStream(new FileInputStream(file));\n\n            byte[] b = new byte[length];\n            int n = is.read(b, offset, length);\n            if (n > 0) {\n                return process(b, offset, length, bitmask, comparator, mimeType, params);\n            }\n        } catch (IOException e) {\n            log.error(\"TextFileDetector: error\", e);\n        } finally {\n        \tIOUtils.closeQuietly(is);\n        }\n\n        return null;\n    }\n}\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/detectors/package.html",
    "content": "<html>\n<body>\n\t<h1>net.sf.jmimemagic</h1>\n\tThis package contains detectors for jmimemagic\n</body>\n</html>\n"
  },
  {
    "path": "src/main/java/net/sf/jmimemagic/package.html",
    "content": "<html>\n<body>\n\t<h1>net.sf.jmimemagic.detectors</h1>\n\tThis package contains the main classes for jmimemagic\n</body>\n</html>\n"
  },
  {
    "path": "src/main/resources/log4j.properties",
    "content": "log4j.rootCategory=ERROR, file\n\nlog4j.appender.stdout=org.apache.log4j.ConsoleAppender\nlog4j.appender.stdout.layout=org.apache.log4j.PatternLayout\nlog4j.appender.stdout.layout.ConversionPattern=%d [%t] %-5p %c - %m%n\n\nlog4j.appender.file=org.apache.log4j.RollingFileAppender\nlog4j.appender.file.File=jmimemagic.log\nlog4j.appender.file.MaxFileSize=10000KB\nlog4j.appender.file.MaxBackupIndex=1\nlog4j.appender.file.layout=org.apache.log4j.PatternLayout\nlog4j.appender.file.layout.ConversionPattern=%d [%t] %-5p %c - %m%n\n\n# Print only messages of priority WARN or above in the package com.foo.\nlog4j.category.net.sf.jmimemagic=ERROR\n\n"
  },
  {
    "path": "src/main/resources/magic.dtd",
    "content": "<!ELEMENT magic (info?,detectorlist)>\n<!ELEMENT info (version?,author?,description?)>\n<!ELEMENT version (#PCDATA)>\n<!ELEMENT author (#PCDATA)>\n<!ELEMENT description (#PCDATA)>\n<!ELEMENT detectorlist (detector*)>\n<!ELEMENT detector (mimetype,extension,designation,test,childlist?)>\n<!ELEMENT extension (#PCDATA)>\n<!ELEMENT mimetype (#PCDATA)>\n<!ELEMENT designation (#PCDATA)>\n<!ELEMENT test (#PCDATA)>\n<!ATTLIST test offset CDATA \"0\">\n<!ATTLIST test type CDATA \"string\">\n<!ATTLIST test comparator CDATA \"=\">\n<!ELEMENT childlist (detector+)>\n\t       \n               \n"
  },
  {
    "path": "src/main/resources/magic.xml",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE magic PUBLIC \"-//jmimemagic//DTD magic config 1.0//EN\" \"magic_1_0.dtd\">\n<magic>\n<info>\n<version>0.2</version>\n<author>dcastro</author>\n<description>magic file</description>\n</info>\n<match-list>\n<match>\n\t<mimetype>audio/mp3</mimetype>\n\t<extension></extension>\n\t<description>MP3</description>\n\t<test type=\"beshort\" offset=\"0\" length=\"\" bitmask=\"0xfffe\" comparator=\"=\">0xfffa</test>\n\t<match-list>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 32 kBits</description>\n\t\t<property name=\"bitrate\" value=\"32\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x10</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 40 kBits</description>\n\t\t<property name=\"bitrate\" value=\"40\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x20</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 48 kBits</description>\n\t\t<property name=\"bitrate\" value=\"48\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x30</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 56 kBits</description>\n\t\t<property name=\"bitrate\" value=\"56\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x40</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 64 kBits</description>\n\t\t<property name=\"bitrate\" value=\"64\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x50</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 80 kBits</description>\n\t\t<property name=\"bitrate\" value=\"80\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x60</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 96 kBits</description>\n\t\t<property name=\"bitrate\" value=\"96\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x70</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 112 kBits</description>\n\t\t<property name=\"bitrate\" value=\"112\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x80</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 128 kBits</description>\n\t\t<property name=\"bitrate\" value=\"128\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x90</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 160 kBits</description>\n\t\t<property name=\"bitrate\" value=\"160\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xA0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 192 kBits</description>\n\t\t<property name=\"bitrate\" value=\"192\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xB0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 224 kBits</description>\n\t\t<property name=\"bitrate\" value=\"224\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xC0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 256 kBits</description>\n\t\t<property name=\"bitrate\" value=\"256\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xD0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 320 kBits</description>\n\t\t<property name=\"bitrate\" value=\"320\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xE0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 44.1 kHz</description>\n\t\t<property name=\"samplingrate\" value=\"44.1\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0x0C\" comparator=\"=\">0x00</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 48 kHz</description>\n\t\t<property name=\"samplingrate\" value=\"48\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0x0C\" comparator=\"=\">0x04</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 32 kHz</description>\n\t\t<property name=\"samplingrate\" value=\"32\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0x0C\" comparator=\"=\">0x08</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, Stereo</description>\n\t\t<property name=\"channels\" value=\"stereo\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0x00</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, JStereo</description>\n\t\t<property name=\"channels\" value=\"jstereo\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0x40</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, Dual-Ch</description>\n\t\t<property name=\"channels\" value=\"dual\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0x80</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, Mono</description>\n\t\t<property name=\"channels\" value=\"mono\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0xC0</test>\n\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>image/gif</mimetype>\n\t<extension></extension>\n\t<description>GIF image data</description>\n\t<test type=\"string\" offset=\"0\" length=\"\" bitmask=\"\" comparator=\"=\">GIF8</test>\n\t<match-list>\n\t<match>\n\t\t<mimetype>b, version 8%s,</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, version 8%s,</description>\n\t\t<test type=\"string\" offset=\"4\" length=\"\" bitmask=\"\" comparator=\"=\">7a</test>\n\t</match>\n\t<match>\n\t\t<mimetype>b, version 8%s,</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, version 8%s,</description>\n\t\t<test type=\"string\" offset=\"4\" length=\"\" bitmask=\"\" comparator=\"=\">9a</test>\n\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>video/mpeg</mimetype>\n\t<extension>mpg</extension>\n\t<description>MPEG video stream data</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0x1b3</test>\n</match>\n<match>\n\t<mimetype>video/mpeg</mimetype>\n\t<extension>mpg</extension>\n\t<description>MPEG system stream data</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0x1ba</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>MP</description>\n\t<test offset=\"0\" type=\"beshort\" comparator=\"&amp;\">0xfff0</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>\\b</description>\n\t\t\t<test offset=\"1\" type=\"byte\" comparator=\"=\">0x8</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>\\b3</description>\n\t\t\t\t\t<test offset=\"1\" type=\"byte\" comparator=\"&amp;\">0x2</test>\n\t\t\t\t\t<match-list>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 32 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x10</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 40 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x20</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 48 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x30</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 56 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x40</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 64 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x50</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 80 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x60</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 96 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x70</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>112 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x80</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>128 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x90</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>160 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xa0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>192 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xb0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>224 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xc0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>256 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xd0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>320 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xe0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t</match-list>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>\\b2</description>\n\t\t\t\t\t<test offset=\"1\" type=\"byte\" comparator=\"&amp;\">0x4</test>\n\t\t\t\t\t<match-list>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 32 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x10</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 48 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x20</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 56 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x30</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 64 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x40</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 80 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x50</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description> 96 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x60</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>112 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x70</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>128 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x80</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>160 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x90</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>192 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xa0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>224 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xb0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>256 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xc0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>320 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xd0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>384 kBits</description>\n\t\t\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xe0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t</match-list>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>44.1 kHz</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>48 kHz</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x4</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>32 kHz</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x8</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>\\b</description>\n\t\t\t<test offset=\"1\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>\\b3</description>\n\t\t\t\t\t<test offset=\"1\" type=\"byte\" comparator=\"&amp;\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>\\b2</description>\n\t\t\t\t\t<test offset=\"1\" type=\"byte\" comparator=\"&amp;\">0x4</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>  8 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x10</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 16 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x20</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 24 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x30</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 32 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x40</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 40 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x50</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 48 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x60</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 56 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x70</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 64 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x80</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 80 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x90</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description> 96 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xa0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>112 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xb0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>128 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xc0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>144 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xd0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>160 kBits</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0xe0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>22.05 kHz</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>24 kHz</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x4</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>16 kHz</description>\n\t\t\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x8</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Stereo</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>JStereo</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"=\">0x40</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Dual-Ch</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"=\">0x80</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Mono</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"=\">0xc0</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>FLI file</description>\n\t<test offset=\"4\" type=\"leshort\" comparator=\"=\">0xaf11</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>- %d frames,</description>\n\t\t\t<test offset=\"6\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>width=%d pixels,</description>\n\t\t\t<test offset=\"8\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>height=%d pixels,</description>\n\t\t\t<test offset=\"10\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>depth=%d,</description>\n\t\t\t<test offset=\"12\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>ticks/frame=%d</description>\n\t\t\t<test offset=\"16\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>FLC file</description>\n\t<test offset=\"4\" type=\"leshort\" comparator=\"=\">0xaf12</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>- %d frames</description>\n\t\t\t<test offset=\"6\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>width=%d pixels,</description>\n\t\t\t<test offset=\"8\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>height=%d pixels,</description>\n\t\t\t<test offset=\"10\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>depth=%d,</description>\n\t\t\t<test offset=\"12\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>ticks/frame=%d</description>\n\t\t\t<test offset=\"16\" type=\"leshort\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Silicon Graphics movie file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">MOVI</test>\n</match>\n<match>\n\t<mimetype>video/quicktime</mimetype>\n\t<extension>mov</extension>\n\t<description>Apple QuickTime movie file (moov)</description>\n\t<test offset=\"4\" type=\"string\" comparator=\"=\">moov</test>\n</match>\n<match>\n\t<mimetype>video/quicktime</mimetype>\n\t<extension>mov</extension>\n\t<description>Apple QuickTime movie file (mdat)</description>\n\t<test offset=\"4\" type=\"string\" comparator=\"=\">mdat</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Applixware</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">*BEGIN</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Words Document</description>\n\t\t\t<test offset=\"7\" type=\"string\" comparator=\"=\">WORDS</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Graphic</description>\n\t\t\t<test offset=\"7\" type=\"string\" comparator=\"=\">GRAPHICS</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Bitmap</description>\n\t\t\t<test offset=\"7\" type=\"string\" comparator=\"=\">RASTER</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Spreadsheet</description>\n\t\t\t<test offset=\"7\" type=\"string\" comparator=\"=\">SPREADSHEETS</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Macro</description>\n\t\t\t<test offset=\"7\" type=\"string\" comparator=\"=\">MACRO</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Builder Object</description>\n\t\t\t<test offset=\"7\" type=\"string\" comparator=\"=\">BUILDER</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/x-tar</mimetype>\n\t<extension>tar</extension>\n\t<description>POSIX tar archive</description>\n\t<test offset=\"257\" type=\"string\" comparator=\"=\">ustar </test>\n</match>\n<match>\n\t<mimetype>application/x-tar</mimetype>\n\t<extension>tar</extension>\n\t<description>tar archive</description>\n\t<test offset=\"257\" type=\"string\" comparator=\"=\">ustar  \\000GNU</test>\n</match>\n<match>\n  <mimetype>application/vnd.openxmlformats-officedocument.wordprocessingml.document</mimetype>\n  <extension>docx</extension>\n  <description>Microsoft Office Open XML Document</description>\n  <test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n  <mimetype>application/vnd.openxmlformats-officedocument.wordprocessingml.document</mimetype>\n  <extension>docm</extension>\n  <description>Microsoft Office Open XML Document</description>\n  <test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n  <mimetype>application/vnd.openxmlformats-officedocument.spreadsheetml.sheet</mimetype>\n  <extension>xlsx</extension>\n  <description>Microsoft Office Open XML Workbook</description>\n  <test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n  <mimetype>application/vnd.openxmlformats-officedocument.spreadsheetml.sheet</mimetype>\n  <extension>xlsm</extension>\n  <description>Microsoft Office Open XML Workbook</description>\n  <test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n  <mimetype>application/vnd.openxmlformats-officedocument.presentationml.presentation</mimetype>\n  <extension>pptx</extension>\n  <description>Microsoft Office Open XML Workbook</description>\n  <test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n  <mimetype>application/vnd.openxmlformats-officedocument.presentationml.presentation</mimetype>\n  <extension>pptm</extension>\n  <description>Microsoft Office Open XML Workbook</description>\n  <test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n\t<mimetype>application/zip</mimetype>\n\t<extension>zip</extension>\n\t<description>Zip archive data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/zip</mimetype>\n\t\t\t<extension>zip</extension>\n\t\t\t<description>at least v0.9 to extract</description>\n\t\t\t<test offset=\"4\" type=\"byte\" comparator=\"=\">0x9</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/zip</mimetype>\n\t\t\t<extension>zip</extension>\n\t\t\t<description>at least v1.0 to extract</description>\n\t\t\t<test offset=\"4\" type=\"byte\" comparator=\"=\">0xa</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/zip</mimetype>\n\t\t\t<extension>zip</extension>\n\t\t\t<description>at least v1.1 to extract</description>\n\t\t\t<test offset=\"4\" type=\"byte\" comparator=\"=\">0xb</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/zip</mimetype>\n\t\t\t<extension>zip</extension>\n\t\t\t<description>at least v2.0 to extract</description>\n\t\t\t<test offset=\"4\" type=\"byte\" comparator=\"=\">0x14</test>\n\t\t</match>\n    </match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Standard MIDI data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">MThd</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(format %d)</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>using %d tracks</description>\n\t\t\t<test offset=\"11\" type=\"byte\" comparator=\"&gt;\">0x1</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Creative Music (CMF) data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">CTMF</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>SoundBlaster instrument data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">SBI</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Creative Labs voice data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">Creative Voice File</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description></description>\n\t\t\t<test offset=\"19\" type=\"byte\" comparator=\"=\">0x1a</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>- version %d</description>\n\t\t\t<test offset=\"23\" type=\"byte\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>\\b.%d</description>\n\t\t\t<test offset=\"22\" type=\"byte\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Extended MOD sound data,</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">EMOD</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>version %d</description>\n\t\t\t<test offset=\"4\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>\\b.%d,</description>\n\t\t\t<test offset=\"4\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%d instruments</description>\n\t\t\t<test offset=\"45\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(module)</description>\n\t\t\t<test offset=\"83\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(song)</description>\n\t\t\t<test offset=\"83\" type=\"byte\" comparator=\"=\">0x1</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>realaudio sound file</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0x2e7261fd</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>file        </description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">.RMF\\000\\000\\000realmedia</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\037\\235compress'd</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>block compressed</description>\n\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%d bits</description>\n\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/x-gzip</mimetype>\n\t<extension>gz</extension>\n\t<description>gzip compressed data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\037\\213</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>reserved method,</description>\n\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"&lt;\">0x8</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>deflated,</description>\n\t\t\t<test offset=\"2\" type=\"byte\" comparator=\"=\">0x8</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>ASCII,</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"&amp;\">0x1</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>continuation,</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"&amp;\">0x2</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>extra field,</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"&amp;\">0x4</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>original filename,</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"&amp;\">0x8</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>comment,</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"&amp;\">0x10</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>encrypted,</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"&amp;\">0x20</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>last modified: %s,</description>\n\t\t\t<test offset=\"4\" type=\"ledate\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>max compression,</description>\n\t\t\t<test offset=\"8\" type=\"byte\" comparator=\"=\">0x2</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>max speed,</description>\n\t\t\t<test offset=\"8\" type=\"byte\" comparator=\"=\">0x4</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: MS-DOS</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: Amiga</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0x1</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: VMS</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0x2</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: Unix</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0x3</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: Atari</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0x5</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: OS/2</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0x6</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: MacOS</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0x7</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: Tops/20</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0xa</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-gzip</mimetype>\n\t\t\t<extension>gz</extension>\n\t\t\t<description>os: Win/32</description>\n\t\t\t<test offset=\"9\" type=\"byte\" comparator=\"=\">0xb</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/x-bzip2</mimetype>\n\t<extension>bz2</extension>\n\t<description>bzip2 compressed data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">BZh</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/x-bzip2</mimetype>\n\t\t\t<extension>bz2</extension>\n\t\t\t<description>block size = %c00k</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"&gt;\">0x2f</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/x-shockwave-flash</mimetype>\n\t<extension>swf</extension>\n\t<description>Macromedia Flash data,</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">FWS</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/x-shockwave-flash</mimetype>\n\t\t\t<extension>swf</extension>\n\t\t\t<description>version %d</description>\n\t\t\t<test offset=\"3\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PostScript Type 1 font text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">%!PS-AdobeFont-1.</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(%s)</description>\n\t\t\t<test offset=\"20\" type=\"string\" comparator=\"&gt;\">\\000</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PostScript Type 1 font program data</description>\n\t<test offset=\"6\" type=\"string\" comparator=\"=\">%!PS-AdobeFont-1.0</test>\n</match>\n<match>\n\t<mimetype>application/postscript</mimetype>\n\t<extension>ps</extension>\n\t<description>PostScript Level 2 program data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">%!PS-Adobe-2.0</test>\n</match>\n<match>\n\t<mimetype>application/vnd.framemaker</mimetype>\n\t<extension>???</extension>\n\t<description>FrameMaker document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;MakerFile</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/vnd.framemaker</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(5.5</description>\n\t\t\t<test offset=\"11\" type=\"string\" comparator=\"=\">5.5</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/vnd.framemaker</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(5.0</description>\n\t\t\t<test offset=\"11\" type=\"string\" comparator=\"=\">5.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/vnd.framemaker</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(4.0</description>\n\t\t\t<test offset=\"11\" type=\"string\" comparator=\"=\">4.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/vnd.framemaker</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(3.0</description>\n\t\t\t<test offset=\"11\" type=\"string\" comparator=\"=\">3.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/vnd.framemaker</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(2.0</description>\n\t\t\t<test offset=\"11\" type=\"string\" comparator=\"=\">2.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/vnd.framemaker</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(1.0</description>\n\t\t\t<test offset=\"11\" type=\"string\" comparator=\"=\">1.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/vnd.framemaker</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%c)</description>\n\t\t\t<test offset=\"14\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>FrameMaker MIF (ASCII) file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;MIFFile</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(4.0)</description>\n\t\t\t<test offset=\"9\" type=\"string\" comparator=\"=\">4.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(3.0)</description>\n\t\t\t<test offset=\"9\" type=\"string\" comparator=\"=\">3.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(2.0)</description>\n\t\t\t<test offset=\"9\" type=\"string\" comparator=\"=\">2.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(1.x)</description>\n\t\t\t<test offset=\"9\" type=\"string\" comparator=\"=\">1.0</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>FrameMaker Dictionary text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;MakerDictionary</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(3.0)</description>\n\t\t\t<test offset=\"17\" type=\"string\" comparator=\"=\">3.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(2.0)</description>\n\t\t\t<test offset=\"17\" type=\"string\" comparator=\"=\">2.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(1.x)</description>\n\t\t\t<test offset=\"17\" type=\"string\" comparator=\"=\">1.0</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>FrameMaker Font file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;MakerScreenFont</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(%s)</description>\n\t\t\t<test offset=\"17\" type=\"string\" comparator=\"=\">1.01</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>FrameMaker MML file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;MML</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>FrameMaker Book file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;BookFile</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(3.0</description>\n\t\t\t<test offset=\"10\" type=\"string\" comparator=\"=\">3.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(2.0</description>\n\t\t\t<test offset=\"10\" type=\"string\" comparator=\"=\">2.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>(1.0</description>\n\t\t\t<test offset=\"10\" type=\"string\" comparator=\"=\">1.0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%c)</description>\n\t\t\t<test offset=\"13\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Intermediate Print File\tFrameMaker IPL file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;Maker</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>GIMP gradient data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">GIMP Gradient</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>GIMP XCF image data,</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">gimp xcf file</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%ld x</description>\n\t\t\t<test offset=\"14\" type=\"belong\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%ld,</description>\n\t\t\t<test offset=\"18\" type=\"belong\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>RGB Color</description>\n\t\t\t<test offset=\"22\" type=\"belong\" comparator=\"=\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Greyscale</description>\n\t\t\t<test offset=\"22\" type=\"belong\" comparator=\"=\">0x1</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Indexed Color</description>\n\t\t\t<test offset=\"22\" type=\"belong\" comparator=\"=\">0x2</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>GIMP pattern data,</description>\n\t<test offset=\"20\" type=\"string\" comparator=\"=\">GPAT</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%s</description>\n\t\t\t<test offset=\"24\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>GIMP brush data</description>\n\t<test offset=\"20\" type=\"string\" comparator=\"=\">GIMP</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PBM image text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">P1</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PGM image text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">P2</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PPM image text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">P3</test>\n</match>\n<match>\n\t<mimetype>image/x-portable-bitmap</mimetype>\n\t<extension>pbm</extension>\n\t<description>PBM \"rawbits\" image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">P4</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PGM \"rawbits\" image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">P5</test>\n</match>\n<match>\n\t<mimetype>image/x-portable-graymap</mimetype>\n\t<extension>???</extension>\n\t<description>PPM \"rawbits\" image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">P6</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>NIFF image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">IIN1</test>\n</match>\n<match>\n    <mimetype>image/tiff</mimetype>\n\t<extension>tif</extension>\n\t<description>TIFF image data, big-endian</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">MM\\000\\052</test>\n</match>\n<match>\n    <mimetype>image/tiff</mimetype>\n    <extension>tif</extension>\n\t<description>TIFF image data, little-endian</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">II\\052\\000</test>\n</match>\n<match>\n    <mimetype>image/tiff</mimetype>\n\t<extension>tiff</extension>\n\t<description>TIFF image data, big-endian</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">MM\\000\\052</test>\n</match>\n<match>\n    <mimetype>image/tiff</mimetype>\n    <extension>tiff</extension>\n\t<description>TIFF image data, little-endian</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">II\\052\\000</test>\n</match>\n<match>\n\t<mimetype>image/png</mimetype>\n\t<extension>png</extension>\n\t<description>PNG image data,</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\211NG</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>image/png</mimetype>\n\t\t\t<extension>png</extension>\n\t\t\t<description>CORRUPTED,</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0xd0a1a0a</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>image/png</mimetype>\n\t\t\t<extension>png</extension>\n\t\t\t<description></description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0xd0a1a0a</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>%ld x</description>\n\t\t\t\t\t<test offset=\"16\" type=\"belong\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>%ld,</description>\n\t\t\t\t\t<test offset=\"20\" type=\"belong\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>%d-bit</description>\n\t\t\t\t\t<test offset=\"24\" type=\"byte\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>grayscale,</description>\n\t\t\t\t\t<test offset=\"25\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>\\b/color RGB,</description>\n\t\t\t\t\t<test offset=\"25\" type=\"byte\" comparator=\"=\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>colormap,</description>\n\t\t\t\t\t<test offset=\"25\" type=\"byte\" comparator=\"=\">0x3</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>gray+alpha,</description>\n\t\t\t\t\t<test offset=\"25\" type=\"byte\" comparator=\"=\">0x4</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>\\b/color RGBA,</description>\n\t\t\t\t\t<test offset=\"25\" type=\"byte\" comparator=\"=\">0x6</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>non-interlaced</description>\n\t\t\t\t\t<test offset=\"28\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>image/png</mimetype>\n\t\t\t\t\t<extension>png</extension>\n\t\t\t\t\t<description>interlaced</description>\n\t\t\t\t\t<test offset=\"28\" type=\"byte\" comparator=\"=\">0x1</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>image/png</mimetype>\n\t<extension>png</extension>\n\t<description>PNG image data, CORRUPTED</description>\n\t<test offset=\"1\" type=\"string\" comparator=\"=\">PNG</test>\n</match>\n<match>\n\t<mimetype>image/gif</mimetype>\n\t<extension>gif</extension>\n\t<description>GIF image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">GIF8</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>image/gif</mimetype>\n\t\t\t<extension>gif</extension>\n\t\t\t<description>version 8%s,</description>\n\t\t\t<test offset=\"4\" type=\"string\" comparator=\"=\">7a</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>image/gif</mimetype>\n\t\t\t<extension>gif</extension>\n\t\t\t<description>version 8%s,</description>\n\t\t\t<test offset=\"4\" type=\"string\" comparator=\"=\">9a</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>image/gif</mimetype>\n\t\t\t<extension>gif</extension>\n\t\t\t<description>%hd x</description>\n\t\t\t<test offset=\"6\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>image/gif</mimetype>\n\t\t\t<extension>gif</extension>\n\t\t\t<description>%hd,</description>\n\t\t\t<test offset=\"8\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>window manager raster image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\361\\000@\\273CMU</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%d x</description>\n\t\t\t<test offset=\"4\" type=\"lelong\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%d,</description>\n\t\t\t<test offset=\"8\" type=\"lelong\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%d-bit</description>\n\t\t\t<test offset=\"12\" type=\"lelong\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/x-miff</mimetype>\n\t<extension>miff</extension>\n\t<description>MIFF image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">id=ImageMagick</test>\n</match>\n<match>\n\t<mimetype>image/g3fax</mimetype>\n\t<extension>fax</extension>\n\t<description>group 3 fax data</description>\n\t<test offset=\"1\" type=\"string\" comparator=\"=\">PC Research, Inc</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>image/g3fax</mimetype>\n\t\t\t<extension>fax</extension>\n\t\t\t<description>normal resolution (204x98 DPI)</description>\n\t\t\t<test offset=\"29\" type=\"byte\" comparator=\"=\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>image/g3fax</mimetype>\n\t\t\t<extension>fax</extension>\n\t\t\t<description>fine resolution (204x196 DPI)</description>\n\t\t\t<test offset=\"29\" type=\"byte\" comparator=\"=\">0x1</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>image/jpeg</mimetype>\n\t<extension>jpg</extension>\n\t<description>JPEG image data</description>\n\t<test offset=\"0\" type=\"beshort\" comparator=\"=\">0xffd8</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>image/jpeg</mimetype>\n\t\t\t<extension>jpg</extension>\n\t\t\t<description>JFIF standard</description>\n\t\t\t<test offset=\"6\" type=\"string\" comparator=\"=\">JFIF</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>image/jpeg</mimetype>\n\t<extension>jpg</extension>\n\t<description>JPEG image data, HSI proprietary</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">hsi1</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PC icon data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">IC</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PC pointer image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PI</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PC color icon data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">CI</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PC color pointer image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">CP</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>X pixmap image text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">/* XPM */</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>iff image data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">Imagefile version-</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%s</description>\n\t\t\t<test offset=\"10\" type=\"string\" comparator=\"&gt;\">\\000</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Kodak Photo CD image pack file</description>\n\t<test offset=\"2048\" type=\"string\" comparator=\"=\">PCD_IPI</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Kodak Photo CD overview pack file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PCD_OPA</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>%s</description>\n\t<test offset=\"1536\" type=\"string\" comparator=\"=\">Visio (TM) Drawing</test>\n</match>\n<match>\n\t<mimetype>application/java</mimetype>\n\t<extension>class</extension>\n\t<description>Compiled Java Class Data</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0xcafebabe</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Java Class Version 1.2</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x0000002e</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Java Class Version 1.3</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x0000002f</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Java Class Version 1.4</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x00000030</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Java Class Version 1.5</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x00000031</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Java serialization data</description>\n\t<test offset=\"0\" type=\"beshort\" comparator=\"=\">0xaced</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>version %d</description>\n\t\t\t<test offset=\"2\" type=\"beshort\" comparator=\"&gt;\">0x4</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/mac-binhex40</mimetype>\n\t<extension>???</extension>\n\t<description>BinHex binary text</description>\n\t<test offset=\"11\" type=\"string\" comparator=\"=\">must be converted with BinHex</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/mac-binhex40</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>version %.3s</description>\n\t\t\t<test offset=\"41\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>StuffIt Archive (data)</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">SIT!</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>StuffIt Archive (rsrc + data)</description>\n\t<test offset=\"65\" type=\"string\" comparator=\"=\">SIT!</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>StuffIt Deluxe (data)</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">SITD</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>StuffIt Deluxe (rsrc + data)</description>\n\t<test offset=\"65\" type=\"string\" comparator=\"=\">SITD</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>StuffIt Deluxe Segment (data)</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">Seg</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>StuffIt Deluxe Segment (rsrc + data)</description>\n\t<test offset=\"65\" type=\"string\" comparator=\"=\">Seg</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/pdf</mimetype>\n\t<extension>pdf</extension>\n\t<description>Macintosh PDF File (data)</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PDF</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/pdf</mimetype>\n\t\t\t<extension>pdf</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/pdf</mimetype>\n\t<extension>pdf</extension>\n\t<description>Macintosh PDF File(rsrc + data)</description>\n\t<test offset=\"65\" type=\"string\" comparator=\"=\">PDF</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/pdf</mimetype>\n\t\t\t<extension>pdf</extension>\n\t\t\t<description>: %s</description>\n\t\t\t<test offset=\"2\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>MIME entity text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">MIME-Version:</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description></description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">Content-Type:</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%s</description>\n\t\t\t<test offset=\"14\" type=\"string\" comparator=\"&gt;\">\\000</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description></description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">Content-Type</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%s</description>\n\t\t\t<test offset=\"13\" type=\"string\" comparator=\"&gt;\">\\000</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>MS-DOS batch file text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">@echo off</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Windows PE</description>\n\t<test offset=\"128\" type=\"string\" comparator=\"=\">PE\\000\\000MS</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>32-bit</description>\n\t\t\t<test offset=\"150\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>unknown processor</description>\n\t\t\t<test offset=\"132\" type=\"leshort\" comparator=\"=\">0x0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Intel 80386</description>\n\t\t\t<test offset=\"132\" type=\"leshort\" comparator=\"=\">0x14c</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>MIPS R4000</description>\n\t\t\t<test offset=\"132\" type=\"leshort\" comparator=\"=\">0x166</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Alpha</description>\n\t\t\t<test offset=\"132\" type=\"leshort\" comparator=\"=\">0x184</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Motorola 68000</description>\n\t\t\t<test offset=\"132\" type=\"leshort\" comparator=\"=\">0x268</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PowerPC</description>\n\t\t\t<test offset=\"132\" type=\"leshort\" comparator=\"=\">0x1f0</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PA-RISC</description>\n\t\t\t<test offset=\"132\" type=\"leshort\" comparator=\"=\">0x290</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description></description>\n\t\t\t<test offset=\"148\" type=\"leshort\" comparator=\"&gt;\">0x1b</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>unknown subsystem</description>\n\t\t\t\t\t<test offset=\"220\" type=\"leshort\" comparator=\"=\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>native</description>\n\t\t\t\t\t<test offset=\"220\" type=\"leshort\" comparator=\"=\">0x1</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>GUI</description>\n\t\t\t\t\t<test offset=\"220\" type=\"leshort\" comparator=\"=\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>console</description>\n\t\t\t\t\t<test offset=\"220\" type=\"leshort\" comparator=\"=\">0x3</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>POSIX</description>\n\t\t\t\t\t<test offset=\"220\" type=\"leshort\" comparator=\"=\">0x7</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>executable</description>\n\t\t\t<test offset=\"150\" type=\"leshort\" comparator=\"=\">0x0</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>not relocatable</description>\n\t\t\t\t\t<test offset=\"150\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>system file</description>\n\t\t\t\t\t<test offset=\"150\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>DLL</description>\n\t\t\t<test offset=\"150\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>not relocatable</description>\n\t\t\t\t\t<test offset=\"150\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>system file</description>\n\t\t\t\t\t<test offset=\"150\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>MS Windows COFF Intel 80386 object file</description>\n\t<test offset=\"0\" type=\"leshort\" comparator=\"=\">0x14c</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>MS-DOS executable (EXE)</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">MZ</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>OS/2 or MS Windows</description>\n\t\t\t<test offset=\"24\" type=\"string\" comparator=\"=\">@</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%s</description>\n\t\t\t\t\t<test offset=\"231\" type=\"string\" comparator=\"=\">LH/2 Self-Extract</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%s</description>\n\t\t\t\t\t<test offset=\"233\" type=\"string\" comparator=\"=\">PKSFX2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%s</description>\n\t\t\t\t\t<test offset=\"122\" type=\"string\" comparator=\"=\">Windows self-extracting ZIP</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>ARJ SFX</description>\n\t\t\t<test offset=\"28\" type=\"string\" comparator=\"=\">RJSX\\377\\377b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>diet compressed</description>\n\t\t\t<test offset=\"28\" type=\"string\" comparator=\"=\">diet\\371\\234b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PKSFX</description>\n\t\t\t<test offset=\"30\" type=\"string\" comparator=\"=\">Copyright 1989-1990 PKWARE Inc.</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%.6s compressed</description>\n\t\t\t<test offset=\"30\" type=\"string\" comparator=\"=\">PKLITE Copr.</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%.15s</description>\n\t\t\t<test offset=\"36\" type=\"string\" comparator=\"=\">LHa's SFX</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>%.15s</description>\n\t\t\t<test offset=\"36\" type=\"string\" comparator=\"=\">LHA's SFX</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>LHa SFX archive v2.13S</description>\n\t\t\t<test offset=\"1638\" type=\"string\" comparator=\"=\">-lh5-</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>RAR self-extracting archive</description>\n\t\t\t<test offset=\"7195\" type=\"string\" comparator=\"=\">Rar!</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PKZIP SFX archive v1.1</description>\n\t\t\t<test offset=\"11696\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PKZIP SFX archive v1.93a</description>\n\t\t\t<test offset=\"13297\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PKZIP2 SFX archive v1.09</description>\n\t\t\t<test offset=\"15588\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PKZIP SFX archive v2.04g</description>\n\t\t\t<test offset=\"15770\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PKZIP2 SFX archive v1.02</description>\n\t\t\t<test offset=\"28374\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Info-ZIP SFX archive v5.12</description>\n\t\t\t<test offset=\"25115\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Info-ZIP SFX archive v5.12 w/decryption</description>\n\t\t\t<test offset=\"26331\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Info-ZIP SFX archive v5.12</description>\n\t\t\t<test offset=\"47031\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Info-ZIP SFX archive v5.12 w/decryption</description>\n\t\t\t<test offset=\"49845\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Info-ZIP NT SFX archive v5.12 w/decryption</description>\n\t\t\t<test offset=\"69120\" type=\"string\" comparator=\"=\">PK\\003\\004b,</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>CODEC archive v3.21</description>\n\t\t\t<test offset=\"49801\" type=\"string\" comparator=\"=\">y\\377\\200\\377v\\377b,</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>1 file</description>\n\t\t\t\t\t<test offset=\"49824\" type=\"leshort\" comparator=\"=\">0x1</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%u files</description>\n\t\t\t\t\t<test offset=\"49824\" type=\"leshort\" comparator=\"&gt;\">0x1</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>MS-DOS executable (built-in)</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">LZ</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Windows NT Registry file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">regf</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>%s</description>\n\t<test offset=\"2080\" type=\"string\" comparator=\"=\">Microsoft Word 6.0 Document</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Spanish Microsoft Word 6 document data</description>\n\t<test offset=\"2080\" type=\"string\" comparator=\"=\">Documento Microsoft Word 6</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Word document data</description>\n\t<test offset=\"2112\" type=\"string\" comparator=\"=\">MSWordDoc</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Word Document</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0x31be0000</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Word 6.0 Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PO^Q`</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Office Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\376\\067\\000\\043</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Office Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\320\\317\\021\\340\\241\\261</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Office Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\333\\245-\\000\\000\\000</test>\n</match>\n<match>\n\t<mimetype>application/msexcel</mimetype>\n\t<extension>???</extension>\n\t<description>%s</description>\n\t<test offset=\"2080\" type=\"string\" comparator=\"=\">Microsoft Excel 5.0 Worksheet</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Microsoft Excel 5.0 Worksheet</description>\n\t<test offset=\"2114\" type=\"string\" comparator=\"=\">Biff5</test>\n</match>\n<match>\n\t<mimetype>text/xml</mimetype>\n\t<extension>???</extension>\n\t<description>XML 1.0 Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;?xml version=\"1.0\"?&gt;</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/msexcel</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Microsoft Excel Spreadsheet</description>\n\t\t\t<test offset=\"23\" type=\"string\" comparator=\"=\">&lt;Workbook xmlns=\"urn:schemas-microsoft-com:office:spreadsheet\"</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Lotus 1-2-3</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0x1a00</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>wk3 document data</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x100400</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>wk4 document data</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x2100400</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>fm3 or fmb document data</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x7800100</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>fm3 or fmb document data</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x7800000</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>Lotus 1-2-3</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0x200</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>wk1 document data</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x6040600</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>fmt document data</description>\n\t\t\t<test offset=\"4\" type=\"belong\" comparator=\"=\">0x6800200</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>WordPerfect document</description>\n\t<test offset=\"1\" type=\"string\" comparator=\"=\">WPC</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>MS Windows Help Data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">?_\\003\\000</test>\n</match>\n<!--<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>\"compact bitmap\" format (Poskanzer)</description>\n\t<test offset=\"0\" type=\"short\" comparator=\"=\"></test>\n</match>-->\n<match>\n\t<mimetype>application/pdf</mimetype>\n\t<extension>pdf</extension>\n\t<description>PDF document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">%PDF-</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>application/pdf</mimetype>\n\t\t\t<extension>pdf</extension>\n\t\t\t<description>version %c</description>\n\t\t\t<test offset=\"5\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/pdf</mimetype>\n\t\t\t<extension>pdf</extension>\n\t\t\t<description>\\b.%c</description>\n\t\t\t<test offset=\"7\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>DOS EPS Binary File</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0xc5d0d3c6</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Postscript starts at byte %d</description>\n\t\t\t<test offset=\"4\" type=\"long\" comparator=\"&gt;\"></test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>length %d</description>\n\t\t\t\t\t<test offset=\"8\" type=\"long\" comparator=\"&gt;\"></test>\n\t\t\t\t\t<match-list>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>Metafile starts at byte %d</description>\n\t\t\t\t\t\t\t<test offset=\"12\" type=\"long\" comparator=\"&gt;\"></test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>length %d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"16\" type=\"long\" comparator=\"&gt;\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>TIFF starts at byte %d</description>\n\t\t\t\t\t\t\t<test offset=\"20\" type=\"long\" comparator=\"&gt;\"></test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>length %d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"24\" type=\"long\" comparator=\"&gt;\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t</match-list>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>PPD file</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">*PPD-Adobe:</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>ve</description>\n\t\t\t<test offset=\"13\" type=\"string\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>RIFF (little-endian) data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">RIFF</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>palette</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">PAL</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>version %d</description>\n\t\t\t\t\t<test offset=\"16\" type=\"leshort\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%d entries</description>\n\t\t\t\t\t<test offset=\"18\" type=\"leshort\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>device-independent bitmap</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">RDIB</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description></description>\n\t\t\t\t\t<test offset=\"16\" type=\"string\" comparator=\"=\">BM</test>\n\t\t\t\t\t<match-list>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>OS/2 1.x format</description>\n\t\t\t\t\t\t\t<test offset=\"30\" type=\"leshort\" comparator=\"=\">0xc</test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"34\" type=\"leshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"36\" type=\"leshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>OS/2 2.x format</description>\n\t\t\t\t\t\t\t<test offset=\"30\" type=\"leshort\" comparator=\"=\">0x40</test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"34\" type=\"leshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"36\" type=\"leshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>Windows 3.x format</description>\n\t\t\t\t\t\t\t<test offset=\"30\" type=\"leshort\" comparator=\"=\">0x28</test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"34\" type=\"lelong\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"38\" type=\"lelong\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"44\" type=\"leshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t</match-list>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>MIDI</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">RMID</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>multimedia movie</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">RMMP</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>application/x-wav</mimetype>\n\t\t\t<extension>wav</extension>\n\t\t\t<description>WAVE audio</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">WAVE</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>Microsoft PCM</description>\n\t\t\t\t\t<test offset=\"20\" type=\"leshort\" comparator=\"=\">0x1</test>\n\t\t\t\t\t<match-list>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>%d bit</description>\n\t\t\t\t\t\t\t<test offset=\"34\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t</match-list>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>mono</description>\n\t\t\t\t\t<test offset=\"22\" type=\"leshort\" comparator=\"=\">0x1</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>stereo</description>\n\t\t\t\t\t<test offset=\"22\" type=\"leshort\" comparator=\"=\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%d channels</description>\n\t\t\t\t\t<test offset=\"22\" type=\"leshort\" comparator=\"&gt;\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%d Hz</description>\n\t\t\t\t\t<test offset=\"24\" type=\"lelong\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>AVI</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">AVI </test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>animated cursor</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">ACON</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>RIFF (big-endian) data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">RIFX</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>palette</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">PAL</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>version %d</description>\n\t\t\t\t\t<test offset=\"16\" type=\"beshort\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%d entries</description>\n\t\t\t\t\t<test offset=\"18\" type=\"beshort\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>device-independent bitmap</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">RDIB</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description></description>\n\t\t\t\t\t<test offset=\"16\" type=\"string\" comparator=\"=\">BM</test>\n\t\t\t\t\t<match-list>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>OS/2 1.x format</description>\n\t\t\t\t\t\t\t<test offset=\"30\" type=\"beshort\" comparator=\"=\">0xc</test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"34\" type=\"beshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"36\" type=\"beshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>OS/2 2.x format</description>\n\t\t\t\t\t\t\t<test offset=\"30\" type=\"beshort\" comparator=\"=\">0x40</test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"34\" type=\"beshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"36\" type=\"beshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>Windows 3.x format</description>\n\t\t\t\t\t\t\t<test offset=\"30\" type=\"beshort\" comparator=\"=\">0x28</test>\n\t\t\t\t\t\t\t<match-list>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"34\" type=\"belong\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d x</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"38\" type=\"belong\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t\t\t<description>%d</description>\n\t\t\t\t\t\t\t\t\t<test offset=\"44\" type=\"beshort\" comparator=\"=\"></test>\n\t\t\t\t\t\t\t\t</match>\n\t\t\t\t\t\t\t</match-list>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t</match-list>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>MIDI</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">RMID</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>multimedia movie</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">RMMP</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WAVE audio</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">WAVE</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>Microsoft PCM</description>\n\t\t\t\t\t<test offset=\"20\" type=\"leshort\" comparator=\"=\">0x1</test>\n\t\t\t\t\t<match-list>\n\t\t\t\t\t\t<match>\n\t\t\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t\t\t<description>%d bit</description>\n\t\t\t\t\t\t\t<test offset=\"34\" type=\"leshort\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t\t\t</match>\n\t\t\t\t\t</match-list>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>mono</description>\n\t\t\t\t\t<test offset=\"22\" type=\"beshort\" comparator=\"=\">0x1</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>stereo</description>\n\t\t\t\t\t<test offset=\"22\" type=\"beshort\" comparator=\"=\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%d channels</description>\n\t\t\t\t\t<test offset=\"22\" type=\"beshort\" comparator=\"&gt;\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%d Hz</description>\n\t\t\t\t\t<test offset=\"24\" type=\"belong\" comparator=\"&gt;\">0x0</test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>AVI</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">AVI </test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>animated cursor</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">ACON</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Notation Interchange File Format</description>\n\t\t\t<test offset=\"8\" type=\"string\" comparator=\"=\">NIFF</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description></description>\n\t<test offset=\"0\" type=\"beshort\" comparator=\"=\">0xedab</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>RPM</description>\n\t\t\t<test offset=\"2\" type=\"beshort\" comparator=\"=\">0xeedb</test>\n\t\t\t<match-list>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>v%d</description>\n\t\t\t\t\t<test offset=\"4\" type=\"byte\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>bin</description>\n\t\t\t\t\t<test offset=\"6\" type=\"beshort\" comparator=\"=\">0x0</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>src</description>\n\t\t\t\t\t<test offset=\"6\" type=\"beshort\" comparator=\"=\">0x1</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>i386</description>\n\t\t\t\t\t<test offset=\"8\" type=\"beshort\" comparator=\"=\">0x1</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>Alpha</description>\n\t\t\t\t\t<test offset=\"8\" type=\"beshort\" comparator=\"=\">0x2</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>Sparc</description>\n\t\t\t\t\t<test offset=\"8\" type=\"beshort\" comparator=\"=\">0x3</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>MIPS</description>\n\t\t\t\t\t<test offset=\"8\" type=\"beshort\" comparator=\"=\">0x4</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>PowerPC</description>\n\t\t\t\t\t<test offset=\"8\" type=\"beshort\" comparator=\"=\">0x5</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>68000</description>\n\t\t\t\t\t<test offset=\"8\" type=\"beshort\" comparator=\"=\">0x6</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>SGI</description>\n\t\t\t\t\t<test offset=\"8\" type=\"beshort\" comparator=\"=\">0x7</test>\n\t\t\t\t</match>\n\t\t\t\t<match>\n\t\t\t\t\t<mimetype>???</mimetype>\n\t\t\t\t\t<extension>???</extension>\n\t\t\t\t\t<description>%s</description>\n\t\t\t\t\t<test offset=\"10\" type=\"string\" comparator=\"=\"></test>\n\t\t\t\t</match>\n\t\t\t</match-list>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>text/rtf</mimetype>\n\t<extension>rtf</extension>\n\t<description>Rich Text Format data,</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">{\\rtf</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>text/rtf</mimetype>\n\t\t\t<extension>rtf</extension>\n\t\t\t<description>version %c,</description>\n\t\t\t<test offset=\"5\" type=\"byte\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>text/rtf</mimetype>\n\t\t\t<extension>rtf</extension>\n\t\t\t<description>ANSI</description>\n\t\t\t<test offset=\"6\" type=\"string\" comparator=\"=\">\\ansi</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>text/rtf</mimetype>\n\t\t\t<extension>rtf</extension>\n\t\t\t<description>Apple Macintosh</description>\n\t\t\t<test offset=\"6\" type=\"string\" comparator=\"=\">\\mac</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>text/rtf</mimetype>\n\t\t\t<extension>rtf</extension>\n\t\t\t<description>IBM PC, code page 437</description>\n\t\t\t<test offset=\"6\" type=\"string\" comparator=\"=\">\\pc</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>text/rtf</mimetype>\n\t\t\t<extension>rtf</extension>\n\t\t\t<description>IBM PS/2, code page 850</description>\n\t\t\t<test offset=\"6\" type=\"string\" comparator=\"=\">\\pca</test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;!DOCTYPE HTML</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;!doctype html</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;HEAD</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;head</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;TITLE</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;title</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;html</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;HTML</test>\n</match>\n<match>\n\t<mimetype>text/sgml</mimetype>\n\t<extension>sgml</extension>\n\t<description>exported SGML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;!DOCTYPE</test>\n</match>\n<match>\n\t<mimetype>text/sgml</mimetype>\n\t<extension>sgml</extension>\n\t<description>exported SGML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;!doctype</test>\n</match>\n<match>\n\t<mimetype>text/sgml</mimetype>\n\t<extension>sgml</extension>\n\t<description>exported SGML subdocument text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;!SUBDOC</test>\n</match>\n<match>\n\t<mimetype>text/sgml</mimetype>\n\t<extension>sgml</extension>\n\t<description>exported SGML subdocument text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;!subdoc</test>\n</match>\n<match>\n\t<mimetype>text/sgml</mimetype>\n\t<extension>sgml</extension>\n\t<description>exported SGML document text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">&lt;!--</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>???</extension>\n\t<description>(Corel/WP)</description>\n\t<test offset=\"1\" type=\"string\" comparator=\"=\">WPC</test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect macro</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect keyboard file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect document</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect dictionary</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect thesaurus</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect block</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect rectangular block</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect column block</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect printer data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect printer data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect driver resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect hyphenation code</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect hyphenation data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect macro resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect hyphenation lex</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect wordlist</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect equation resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect spell rules</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect dictionary rules</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect spell rules (Microlytics)</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect settings file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect 4.2 document</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect dialog file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect button bar</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Shell macro</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Shell definition</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Notebook macro</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Notebook help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Notebook keyboard file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Notebook definition</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Calculator help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Calendar help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Calendar data file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Editor macro</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Editor help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Editor keyboard file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Editor macro resource file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Macro editor macro</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Macro editor help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Macro editor keyboard file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect macro</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect keyboard file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect worksheet</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect printer definition</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect graphic definition</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect temporary printer</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>PlanPerfect macro resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Mail</description>\n\t\t\t<test offset=\"8\" type=\"byte\" comparator=\"=\">0xb</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>distribution list</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>out box</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>in box</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>users archived mailbox</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>archived message database</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>archived attachments</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Printer temporary file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Scheduler help file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Scheduler in file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Scheduler out file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise settings file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise directory services</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise settings file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Terminal resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Terminal resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Terminal resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GUI loadable text</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>graphics resource data</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>printer settings file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>port definition file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>print queue parameters</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>compressed file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Network service msg file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Network service msg file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>Async gateway login msg</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise message file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise admin domain database</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise admin host database</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise admin remote host database</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>GroupWise admin ADS deferment data file</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>IntelliTAG (SGML) compiled DTD</description>\n\t\t\t<test offset=\"8\" type=\"short\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect graphic image (1.0)</description>\n\t\t\t<test offset=\"8\" type=\"long\" comparator=\"=\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>???</mimetype>\n\t\t\t<extension>???</extension>\n\t\t\t<description>WordPerfect graphic image (2.0)</description>\n\t\t\t<test offset=\"8\" type=\"long\" comparator=\"=\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>text/x-java</mimetype>\n\t<extension>java</extension>\n\t<description>Java source file</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^\\s*package/</test>\n</match>\n<match>\n\t<mimetype>text/x-perl</mimetype>\n\t<extension>pl</extension>\n\t<description>Perl source file</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/usr\\/bin\\/perl/</test>\n</match>\n<match>\n\t<mimetype>text/x-c</mimetype>\n\t<extension>c</extension>\n\t<description>C source file</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#include/m</test>\n</match>\n<match>\n\t<mimetype>application/x-sh</mimetype>\n\t<extension>sh</extension>\n\t<description>sh script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/sh/</test>\n</match>\n<match>\n\t<mimetype>application/x-bash</mimetype>\n\t<extension>sh</extension>\n\t<description>bash script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/bash/</test>\n</match>\n<match>\n\t<mimetype>application/x-csh</mimetype>\n\t<extension>sh</extension>\n\t<description>csh script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/csh/</test>\n</match>\n<match>\n\t<mimetype>application/x-ksh</mimetype>\n\t<extension>sh</extension>\n\t<description>ksh script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/ksh/</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML Document</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^\\s*&lt;!DOCTYPE HTML PUBLIC/</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>html</extension>\n\t<description>HTML Document</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^\\s*&lt;html&gt;/</test>\n</match>\n<!-- \n<match>\n\t<mimetype>text/plain</mimetype>\n\t<extension>txt</extension>\n\t<description>ASCII Text Document</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"!\">/[^[:ascii:][:space:]]/</test>\n</match>\n-->\n<match>\n\t<mimetype>text/plain</mimetype>\n\t<extension></extension>\n\t<description>net.sf.jmimemagic.detectors.TextFileDetector</description>\n\t<test type=\"detector\" offset=\"0\" length=\"\" bitmask=\"\" comparator=\"=\">net.sf.jmimemagic.detectors.TextFileDetector</test>\n</match>\n<match>\n\t<mimetype>application/vnd.oasis.opendocument.text</mimetype>\n\t<extension>odt</extension>\n\t<description>Open Document Text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n</match-list>\n</magic>\n"
  },
  {
    "path": "src/main/resources/magic.xml.basic",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE magic PUBLIC \"-//jMimeMagic//DTD magic config 1.0//EN\" \"magic_1_0.dtd\">\n<magic>\n<info>\n<version>0.1</version>\n<author>arimus@users.sourceforge.net</author>\n<description>XML magic file</description>\n</info>\n<match-list>\n<match>\n\t<mimetype>application/x-tar</mimetype>\n\t<extension>tar</extension>\n\t<description>POSIX tar archive</description>\n\t<test offset=\"257\" type=\"string\" comparator=\"=\">ustar\\000</test>\n</match>\n<match>\n\t<mimetype>application/x-tar</mimetype>\n\t<extension>tar</extension>\n\t<description>tar archive</description>\n\t<test offset=\"257\" type=\"string\" comparator=\"=\">ustar  \\000GNU</test>\n</match>\n<match>\n\t<mimetype>application/zip</mimetype>\n\t<extension>zip</extension>\n\t<description>archive data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n\t<mimetype>application/x-gzip</mimetype>\n\t<extension>gz</extension>\n\t<description>gzip compressed data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\037\\213</test>\n</match>\n<match>\n\t<mimetype>application/x-bzip2</mimetype>\n\t<extension>bz2</extension>\n\t<description>bzip2 compressed data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">BZh</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>bat</extension>\n\t<description>MS-DOS batch file text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">@echo off</test>\n</match>\n</match-list>\n</magic>\n"
  },
  {
    "path": "src/main/resources/magic.xml.verified",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE magic PUBLIC \"-//jmimemagic//DTD magic config 1.0//EN\" \"magic_1_0.dtd\">\n<magic>\n<info>\n<version>0.2</version>\n<author>dcastro</author>\n<description>magic file</description>\n</info>\n\n<match-list>\n<!--\n<match>\n\t<mimetype></mimetype>        # the mime type if matched \n\t<extension></extension>      # the likely extension for this matched stream \n\t<description>empty</description>  # description if matched \n\t<test type=\"\" \n\t      offset=\"0\" \n\t\t  length=\"\" \n\t\t  bitmask=\"\" \n\t\t  comparator=\"\">\n\t</test>                      # the test which defines this match \n\t\t# test   - this value may contain a '.', which represents any value\n\t\t#          '.' must be replaced with '.'\n\t\t#          xNN where N is [0-9] represents a hex value\n\t\t# type   - one of:\n\t\t#\t\t\t long        - long, platform byte order\n\t\t#\t\t\t lelong      - long, little endian\n\t\t#\t\t\t belong      - long, big endian\n\t\t#\t\t\t short       - short\n\t\t#\t\t\t leshort     - short, little endian\n\t\t#\t\t\t beshort     - short, big endian\n\t\t#\t\t\t string      - string\n\t\t#\t\t\t string-ZZZZ - string with encoding defined by ZZZZ (any \n\t\t#\t\t\t               length encoding name)\n\t\t#\t\t\t byte        - byte\n\t\t#\t\t\t regex       - regular expression in perl 5 style\n\t\t#\t\t\t plugin      - call the specified class to determine if\n\t\t#\t\t\t               the stream is of this mime type\n\t\t# offset     - location match should start from on the stream\n\t\t#              normal offset - n (0-indexed byte position in stream)\n\t\t#              indirect offset - for which types???\n\t\t# length     - this is implicit when data is specified in <test/>, but\n\t\t# \t\t\t   for regex and plugin this will limit the amount of data\n\t\t# \t\t\t   used for comparison, as if the rest of the stream didn't\n\t\t# \t\t\t   exist\n\t\t# bitmask    - a bitmask that should be applied to the stream segment\n\t\t# \t\t\t   before it is tested against the value or passed to\n\t\t# \t\t\t   regex/plugin\n\t\t# comparator - one of:\n\t\t#                = - equals\n\t\t#\t\t\t\t ! - not equals\n\t\t#\t\t\t\t > - greater than\n\t\t#\t\t\t\t < - less than\n\t\t#\t\t\t\t & - all bits set\n\t\t#\t\t\t\t ^ - all bit cleared\n\t\n\t<match-list>                    # example sub-match\n\t\t<match>\n\t\t<mimetype></mimetype>       # if submatch has diff mime type\n\t\t<extension></extension>     # if submatch has diff ext \n\t\t<description \n\t\t\t  supplemental=\"\">      # defined if this is a supplemental desc\n\t\t</description>              # description if matched\n\t\t<test offset=\"0\"\n\t\t\t  length=\"\"\n\t\t\t  type=\"\"\n\t\t\t  bitmask=\"\"\n\t\t\t  comparator=\"\">\n\t\t</test>                     # the test which defines this match \n\t\t</match>\n\t</match-list>\n</match>\n\n-->\n<match>\n\t<mimetype>audio/mp3</mimetype>\n\t<extension></extension>\n\t<description>MP3</description>\n\t<test type=\"beshort\" offset=\"0\" length=\"\" bitmask=\"0xfffe\" comparator=\"=\">0xfffa</test>\n\t<match-list>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 32 kBits</description>\n\t\t<property name=\"bitrate\" value=\"32\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x10</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 40 kBits</description>\n\t\t<property name=\"bitrate\" value=\"40\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x20</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 48 kBits</description>\n\t\t<property name=\"bitrate\" value=\"48\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x30</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 56 kBits</description>\n\t\t<property name=\"bitrate\" value=\"56\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x40</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 64 kBits</description>\n\t\t<property name=\"bitrate\" value=\"64\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x50</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 80 kBits</description>\n\t\t<property name=\"bitrate\" value=\"80\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x60</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 96 kBits</description>\n\t\t<property name=\"bitrate\" value=\"96\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x70</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 112 kBits</description>\n\t\t<property name=\"bitrate\" value=\"112\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x80</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 128 kBits</description>\n\t\t<property name=\"bitrate\" value=\"128\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0x90</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 160 kBits</description>\n\t\t<property name=\"bitrate\" value=\"160\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xA0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 192 kBits</description>\n\t\t<property name=\"bitrate\" value=\"192\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xB0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 224 kBits</description>\n\t\t<property name=\"bitrate\" value=\"224\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xC0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 256 kBits</description>\n\t\t<property name=\"bitrate\" value=\"256\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xD0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 320 kBits</description>\n\t\t<property name=\"bitrate\" value=\"320\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0xf0\" comparator=\"=\">0xE0</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 44.1 kHz</description>\n\t\t<property name=\"samplingrate\" value=\"44.1\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0x0C\" comparator=\"=\">0x00</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 48 kHz</description>\n\t\t<property name=\"samplingrate\" value=\"48\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0x0C\" comparator=\"=\">0x04</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, 32 kHz</description>\n\t\t<property name=\"samplingrate\" value=\"32\"/>\n\t\t<test type=\"byte\" offset=\"2\" length=\"\" bitmask=\"0x0C\" comparator=\"=\">0x08</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, Stereo</description>\n\t\t<property name=\"channels\" value=\"stereo\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0x00</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, JStereo</description>\n\t\t<property name=\"channels\" value=\"jstereo\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0x40</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, Dual-Ch</description>\n\t\t<property name=\"channels\" value=\"dual\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0x80</test>\n\t</match>\n\t<match>\n\t\t<mimetype></mimetype>\n\t\t<extension></extension>\n\t\t<description>b, Mono</description>\n\t\t<property name=\"channels\" value=\"mono\"/>\n\t\t<test type=\"byte\" offset=\"3\" length=\"\" bitmask=\"0xC0\" comparator=\"=\">0xC0</test>\n\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>image/gif</mimetype>\n\t<extension></extension>\n\t<description>GIF image data</description>\n\t<test type=\"string\" offset=\"0\" length=\"\" bitmask=\"\" comparator=\"=\">GIF8</test>\n\t<match-list>\n\t<match>\n\t\t<mimetype>b, version 8%s,</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, version 8%s,</description>\n\t\t<test type=\"string\" offset=\"4\" length=\"\" bitmask=\"\" comparator=\"=\">7a</test>\n\t</match>\n\t<match>\n\t\t<mimetype>b, version 8%s,</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, version 8%s,</description>\n\t\t<test type=\"string\" offset=\"4\" length=\"\" bitmask=\"\" comparator=\"=\">9a</test>\n\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>image/png</mimetype>\n\t<extension></extension>\n\t<description>PNG image data</description>\n\t<test type=\"string\" offset=\"1\" length=\"\" bitmask=\"\" comparator=\"=\">PNG</test>\n\t<match-list>\n\t<match>\n\t\t<mimetype>CORRUPTED,</mimetype>\n\t\t<extension></extension>\n\t\t<description>CORRUPTED,</description>\n\t\t<test type=\"belong\" offset=\"4\" length=\"\" bitmask=\"\" comparator=\"!\">0x0d0a1a0a</test>\n\t</match>\n\t<match>\n\t\t<mimetype>X</mimetype>\n\t\t<extension></extension>\n\t\t<description>X</description>\n\t\t<test type=\"belong\" offset=\"4\" length=\"\" bitmask=\"\" comparator=\"=\">0x0d0a1a0a</test>\n\t\t<match-list>\n\t\t<match>\n\t\t\t<mimetype>bcolor RGB,</mimetype>\n\t\t\t<extension></extension>\n\t\t\t<description>bcolor RGB,</description>\n\t\t\t<test type=\"byte\" offset=\"25\" length=\"\" bitmask=\"\" comparator=\"=\">2</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>colormap,</mimetype>\n\t\t\t<extension></extension>\n\t\t\t<description>colormap,</description>\n\t\t\t<test type=\"byte\" offset=\"25\" length=\"\" bitmask=\"\" comparator=\"=\">3</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>grayalpha,</mimetype>\n\t\t\t<extension></extension>\n\t\t\t<description>grayalpha,</description>\n\t\t\t<test type=\"byte\" offset=\"25\" length=\"\" bitmask=\"\" comparator=\"=\">4</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>bcolor RGBA,</mimetype>\n\t\t\t<extension></extension>\n\t\t\t<description>bcolor RGBA,</description>\n\t\t\t<test type=\"byte\" offset=\"25\" length=\"\" bitmask=\"\" comparator=\"=\">6</test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype>interlaced</mimetype>\n\t\t\t<extension></extension>\n\t\t\t<description>interlaced</description>\n\t\t\t<test type=\"byte\" offset=\"28\" length=\"\" bitmask=\"\" comparator=\"=\">1</test>\n\t\t</match>\n\t\t</match-list>\n\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>image/jpeg</mimetype>\n\t<extension></extension>\n\t<description>JPEG image data</description>\n\t<test type=\"beshort\" offset=\"0\" length=\"\" bitmask=\"\" comparator=\"=\">0xffd8</test>\n\t<match-list>\n\t<match>\n\t\t<mimetype>b, JFIF standard</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, JFIF standard</description>\n\t\t<test type=\"string\" offset=\"6\" length=\"\" bitmask=\"\" comparator=\"=\">JFIF</test>\n\t</match>\n\t<match>\n\t\t<mimetype>b, EXIF standard</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, EXIF standard</description>\n\t\t<test type=\"string\" offset=\"6\" length=\"\" bitmask=\"\" comparator=\"=\">Exif</test>\n\t</match>\n\t<match>\n\t\t<mimetype>b, resolution (DPI)</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, resolution (DPI)</description>\n\t\t<test type=\"byte\" offset=\"13\" length=\"\" bitmask=\"\" comparator=\"=\">1</test>\n\t</match>\n\t<match>\n\t\t<mimetype>b, resolution (DPCM)</mimetype>\n\t\t<extension></extension>\n\t\t<description>b, resolution (DPCM)</description>\n\t\t<test type=\"byte\" offset=\"13\" length=\"\" bitmask=\"\" comparator=\"=\">2</test>\n\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>JPEG image data, HSI proprietary</mimetype>\n\t<extension></extension>\n\t<description>JPEG image data, HSI proprietary</description>\n\t<test type=\"string\" offset=\"0\" length=\"\" bitmask=\"\" comparator=\"=\">hsi1</test>\n</match>\n<!-- FIXME - invalid index errors working with regexes\n<match>\n\t<mimetype>text/x-java</mimetype>\n\t<extension>java</extension>\n\t<description>Java source file</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^\\s*package/</test>\n</match>\n<match>\n\t<mimetype>text/x-perl</mimetype>\n\t<extension>pl</extension>\n\t<description>Perl source file</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/usr\\/bin\\/perl/</test>\n</match>\n<match>\n\t<mimetype>text/x-c</mimetype>\n\t<extension>c</extension>\n\t<description>C source file</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#include/m</test>\n</match>\n<match>\n\t<mimetype>application/x-sh</mimetype>\n\t<extension>.sh</extension>\n\t<description>sh script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/sh/</test>\n</match>\n<match>\n\t<mimetype>application/x-bash</mimetype>\n\t<extension>.sh</extension>\n\t<description>bash script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/bash/</test>\n</match>\n<match>\n\t<mimetype>application/x-csh</mimetype>\n\t<extension>.sh</extension>\n\t<description>csh script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/csh/</test>\n</match>\n<match>\n\t<mimetype>application/x-ksh</mimetype>\n\t<extension>.sh</extension>\n\t<description>ksh script</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^#!\\/bin\\/ksh/</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>.html</extension>\n\t<description>HTML Document</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^\\s*&lt;!DOCTYPE HTML PUBLIC/</test>\n</match>\n<match>\n\t<mimetype>text/html</mimetype>\n\t<extension>.html</extension>\n\t<description>HTML Document</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"=\">/^\\s*&lt;html&gt;/</test>\n</match>\n<match>\n\t<mimetype>text/plain</mimetype>\n\t<extension>.txt</extension>\n\t<description>ASCII Text Document</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"!\">/[^[:ascii:][:space:]]/</test>\n</match>\n-->\n\n<!-- Microsoft Word documents -->\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>%s</description>\n\t<test offset=\"2080\" type=\"string\" comparator=\"=\">Microsoft Word 6.0 Document</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Spanish Microsoft Word 6 document data</description>\n\t<test offset=\"2080\" type=\"string\" comparator=\"=\">Documento Microsoft Word 6</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Word document data</description>\n\t<test offset=\"2112\" type=\"string\" comparator=\"=\">MSWordDoc</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Word Document</description>\n\t<test offset=\"0\" type=\"belong\" comparator=\"=\">0x31be0000</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Word 6.0 Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PO^Q`</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Office Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\376\\067\\000\\043</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Office Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\320\\317\\021\\340\\241\\261</test>\n</match>\n<match>\n\t<mimetype>application/msword</mimetype>\n\t<extension>doc</extension>\n\t<description>Microsoft Office Document</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\333\\245-\\000\\000\\000</test>\n</match>\n<match>\n\t<mimetype>text/rtf</mimetype>\n\t<extension></extension>\n\t<description>Rich Text Format data</description>\n\t<test type=\"string\" offset=\"\" length=\"\" bitmask=\"\" comparator=\"=\">{\\rtf</test>\n\t<match-list>\n\t<match>\n\t\t<mimetype>version %c,</mimetype>\n\t\t<extension></extension>\n\t\t<description>version %c,</description>\n\t\t<test type=\"byte\" offset=\"5\" length=\"\" bitmask=\"\" comparator=\"=\"></test>\n\t</match>\n\t<match>\n\t\t<mimetype>ANSI</mimetype>\n\t\t<extension></extension>\n\t\t<description>ANSI</description>\n\t\t<test type=\"string\" offset=\"6\" length=\"\" bitmask=\"\" comparator=\"=\">\\ansi</test>\n\t</match>\n\t<match>\n\t\t<mimetype>Apple Macintosh</mimetype>\n\t\t<extension></extension>\n\t\t<description>Apple Macintosh</description>\n\t\t<test type=\"string\" offset=\"6\" length=\"\" bitmask=\"\" comparator=\"=\">\\mac</test>\n\t</match>\n\t<match>\n\t\t<mimetype>IBM PC, code page 437</mimetype>\n\t\t<extension></extension>\n\t\t<description>IBM PC, code page 437</description>\n\t\t<test type=\"string\" offset=\"6\" length=\"\" bitmask=\"\" comparator=\"=\">\\pc</test>\n\t</match>\n\t<match>\n\t\t<mimetype>IBM PS2, code page 850</mimetype>\n\t\t<extension></extension>\n\t\t<description>IBM PS2, code page 850</description>\n\t\t<test type=\"string\" offset=\"6\" length=\"\" bitmask=\"\" comparator=\"=\">\\pca</test>\n\t</match>\n\t</match-list>\n</match>\n<match>\n\t<mimetype>application/postscript</mimetype>\n\t<extension>ps</extension>\n\t<description>PostScript Level 2 program data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">%!PS-Adobe-2.0</test>\n</match>\n<match>\n\t<mimetype>text/plain</mimetype>\n\t<extension>.txt</extension>\n\t<description>ASCII Text Document</description>\n\t<test offset=\"0\" type=\"regex\" comparator=\"!\">/[^[:ascii:][:space:]]/</test>\n</match>\n<match>\n\t<mimetype>application/vnd.oasis.opendocument.text</mimetype>\n\t<extension>odt</extension>\n\t<description>Open Document Format</description>\n</match>\n</match-list>\n</magic>"
  },
  {
    "path": "src/main/resources/magic_1_0.dtd",
    "content": "<!ELEMENT magic (info?,match-list)>\n<!ELEMENT info (version?,author?,description?)>\n<!ELEMENT version (#PCDATA)>\n<!ELEMENT author (#PCDATA)>\n<!ELEMENT description (#PCDATA)>\n<!ELEMENT match-list (match*)>\n<!ELEMENT match (mimetype,extension,description,test,submatch-list?)>\n<!ELEMENT extension (#PCDATA)>\n<!ELEMENT mimetype (#PCDATA)>\n<!ELEMENT description (#PCDATA)>\n<!ELEMENT test (#PCDATA)>\n<!ATTLIST test offset CDATA \"0\">\n<!ATTLIST test type CDATA \"string\">\n<!ATTLIST test bitmask CDATA \"\">\n<!ATTLIST test comparator CDATA \"=\">\n<!ELEMENT submatch-list (match+)>\n\t       \n               \n"
  },
  {
    "path": "src/main/resources/template.xml",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE magic PUBLIC \"-//jmimemagic//DTD magic config 1.0//EN\" \"magic_1_0.dtd\">\n<magic>\n<info>\n<version></version>\n<author></author>\n<description>file</description>\n</info>\n\n<match-list>\n<!--\n<match>\n\t<mimetype></mimetype>        # the mime type if matched \n\t<extension></extension>      # the likely extension for this matched stream \n\t<description></description>  # description if matched \n\t<test type=\"\" \n\t      offset=\"\" \n\t\t  length=\"\" \n\t\t  bitmask=\"\" \n\t\t  comparator=\"\">\n\t</test>                      # the test which defines this match \n\t\t# test   - this value may contain a '.', which represents any value\n\t\t#          '.' must be replaced with '\\.'.  \n\t\t#          \\xNN where N is [0-9] represents a hex value\n\t\t# type   - one of:\n\t\t#\t\t\t long        - long, platform byte order\n\t\t#\t\t\t lelong      - long, little endian\n\t\t#\t\t\t belong      - long, big endian\n\t\t#\t\t\t short       - short\n\t\t#\t\t\t leshort     - short, little endian\n\t\t#\t\t\t beshort     - short, big endian\n\t\t#\t\t\t string      - string\n\t\t#\t\t\t string-ZZZZ - string with encoding defined by ZZZZ (any \n\t\t#\t\t\t               length encoding name)\n\t\t#\t\t\t byte        - byte\n\t\t#\t\t\t regex       - regular expression in perl 5 style\n\t\t#\t\t\t plugin      - call the specified class to determine if\n\t\t#\t\t\t               the stream is of this mime type\n\t\t# offset     - location match should start from on the stream\n\t\t#              normal offset - n (0-indexed byte position in stream)\n\t\t#              indirect offset - for which types???\n\t\t# length     - this is implicit when data is specified in <test/>, but\n\t\t# \t\t\t   for regex and plugin this will limit the amount of data\n\t\t# \t\t\t   used for comparison, as if the rest of the stream didn't\n\t\t# \t\t\t   exist\n\t\t# bitmask    - a bitmask that should be applied to the stream segment\n\t\t# \t\t\t   before it is tested against the value or passed to\n\t\t# \t\t\t   regex/plugin\n\t\t# comparator - one of:\n\t\t#                = - equals\n\t\t#\t\t\t\t ! - not equals\n\t\t#\t\t\t\t > - greater than\n\t\t#\t\t\t\t < - less than\n\t\t#\t\t\t\t & - all bits set\n\t\t#\t\t\t\t ^ - all bit cleared\n\t\n\t<match-list>                    # example sub-match\n\t\t<match>\n\t\t<mimetype></mimetype>       # if submatch has diff mime type\n\t\t<extension></extension>     # if submatch has diff ext \n\t\t<description \n\t\t\t  supplemental=\"\">      # defined if this is a supplemental desc\n\t\t</description>              # description if matched\n\t\t<test offset=\"\"\n\t\t\t  length=\"\"\n\t\t\t  type=\"\"\n\t\t\t  bitmask=\"\"\n\t\t\t  comparator=\"\">\n\t\t</test>                     # the test which defines this match \n\t\t</match>\n\t</match-list>\n</match>\n\n-->\n<match>\n\t<mimetype></mimetype>\n\t<extension></extension>\n\t<description></description>\n\t<test type=\"\" offset=\"\" length=\"\" bitmask=\"\" comparator=\"\"></test>\n\t<match-list>\n\t\t<match>\n\t\t\t<mimetype></mimetype>\n\t\t\t<extension></extension>\n\t\t\t<description supplemental=\"\"></description>\n\t\t\t<test offset=\"\" length=\"\" type=\"\" bitmask=\"\" comparator=\"\"></test>\n\t\t</match>\n\t\t<match>\n\t\t\t<mimetype></mimetype>\n\t\t\t<extension></extension>\n\t\t\t<description supplemental=\"\"></description>\n\t\t\t<test offset=\"\" length=\"\" type=\"\" bitmask=\"\" comparator=\"\"></test>\n\t\t</match>\n\t</match-list>\n</match>\n</match-list>\n</magic>\n\n"
  },
  {
    "path": "src/test/java/net/sf/jmimemagic/MagicTest.java",
    "content": "package net.sf.jmimemagic;\r\n\r\nimport junit.framework.*;\r\nimport java.io.File;\r\n\r\npublic class MagicTest extends TestCase {\r\n\tprivate static String gifFile = \"test_docs/test.gif\";\r\n\tprivate static String pngFile = \"test_docs/test.png\";\r\n\tprivate static String tifFile = \"test_docs/test_nocompress.tif\";\r\n\tprivate static String jpgFile = \"test_docs/test.jpg\";\r\n\tprivate static String textFile = \"test_docs/test.txt\";\r\n\tprivate static String officeOpenXmlDocumentFile = \"test_docs/test_word.docx\";\r\n\tprivate static String officeOpenXmlDocumentFile2 = \"test_docs/test_word.docm\";\r\n\tprivate static String word2KFile = \"test_docs/test_word_2000.doc\";\r\n\tprivate static String word95File = \"test_docs/test_word_6.0_95.doc\";\r\n\tprivate static String rtfFile = \"test_docs/test.rtf\";\r\n\tprivate static String officeOpenXmlWorkbookFile = \"test_docs/test_excel.xlsx\";\r\n\tprivate static String officeOpenXmlWorkbookFile2 = \"test_docs/test_excel.xlsm\";\r\n\tprivate static String officeOpenXmlPresentationFile = \"test_docs/test_powerpoint.pptx\";\r\n\tprivate static String officeOpenXmlPresentationFile2 = \"test_docs/test_powerpoint.pptm\";\r\n\tprivate static String excel2KFile = \"test_docs/test_excel_2000.xls\";\r\n\tprivate static String pdfFile = \"test_docs/test.pdf\";\r\n\tprivate static String psFile = \"test_docs/test.ps\";\r\n\tprivate static String javaClass12File = \"test_docs/test_1.2.class\";\r\n\tprivate static String javaClass13File = \"test_docs/test_1.3.class\";\r\n\tprivate static String javaClass14File = \"test_docs/test_1.4.class\";\r\n\tprivate static String mp3_128_44_jstereoFile = \"test_docs/test_128_44_jstereo.mp3\";\r\n\tprivate static String wavFile = \"test_docs/test.wav\";\r\n\tprivate static String odtFile = \"test_docs/test.odt\";\r\n\tprivate static String zipFile = \"test_docs/test.zip\";\r\n\r\n\tpublic static void main(String args[]) {\r\n\t\tjunit.textui.TestRunner.run(MagicTest.class);\r\n\t}\r\n\r\n\t// IMAGE TESTS\r\n\r\n\tpublic void testGIF() {\r\n\t\tSystem.out.print(\"\\ntesting GIF image...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(gifFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"image/gif\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testGIF()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testGIF(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testGIF(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testPNG() {\r\n\t\tSystem.out.print(\"\\ntesting PNG image...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(pngFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"image/png\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testPNG()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testPNG(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testPNG(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testTIF() {\r\n\t\tSystem.out.print(\"\\ntesting TIF image...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(tifFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"image/tiff\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testTIF()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testTIF(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testTIF(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testJPEG() {\r\n\t\tSystem.out.print(\"\\ntesting JPEG image...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(jpgFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"image/jpeg\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testJPEG()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testJPEG(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testJPEG(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\t// DOCUMENT TESTS\r\n\r\n\tpublic void testText() {\r\n\t\tSystem.out.print(\"\\ntesting Plain Text Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(textFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"text/plain\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testText()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testText(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testText(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testOfficeOpenXmlDocument() {\r\n\t\tSystem.out.print(\"\\ntesting Word Office Open XML Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(officeOpenXmlDocumentFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/vnd.openxmlformats-officedocument.wordprocessingml.document\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOfficeOpenXmlDocument()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testOfficeOpenXmlDocument(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testOfficeOpenXmlDocument(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testOfficeOpenXmlDocument2() {\r\n\t\tSystem.out.print(\"\\ntesting Word Office Open XML Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(officeOpenXmlDocumentFile2), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/vnd.openxmlformats-officedocument.wordprocessingml.document\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOfficeOpenXmlDocument2()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testOfficeOpenXmlDocument2(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testOfficeOpenXmlDocument2(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testWord2K() {\r\n\t\tSystem.out.print(\"\\ntesting Word 2000 Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(word2KFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/msword\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testWord2K()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testWord2K(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testWord2K(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testWord95() {\r\n\t\tSystem.out.print(\"\\ntesting Word 95 Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(word95File), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/msword\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testWord95()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testWord95(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testWord95(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testRTF() {\r\n\t\tSystem.out.print(\"\\ntesting RTF Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(rtfFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"text/rtf\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testRTF()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testRTF(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testRTF(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testOfficeOpenXmlWorkbook() {\r\n\t\tSystem.out.print(\"\\ntesting Word Office Open XML Workbook...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(officeOpenXmlWorkbookFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOfficeOpenXmlWorkbook()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testOfficeOpenXmlWorkbook(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testOfficeOpenXmlWorkbook(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testOfficeOpenXmlWorkbook2() {\r\n\t\tSystem.out.print(\"\\ntesting Word Office Open XML Workbook...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(officeOpenXmlWorkbookFile2), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOfficeOpenXmlWorkbook2()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testOfficeOpenXmlWorkbook2(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testOfficeOpenXmlWorkbook2(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n    \r\n\tpublic void testExcel2K() {\r\n\t\tSystem.out.print(\"\\ntesting Excel 2000 Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(excel2KFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/msword\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testExcel2K()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testExcel2K(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testExcel2K(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\r\n\tpublic void testOfficeOpenXmlPresentation() {\r\n\t\tSystem.out.print(\"\\ntesting Word Office Open XML Presentation...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(officeOpenXmlPresentationFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/vnd.openxmlformats-officedocument.presentationml.presentation\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOfficeOpenXmlPresentation()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testOfficeOpenXmlPresentation(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testOfficeOpenXmlPresentation(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testOfficeOpenXmlPresentation2() {\r\n\t\tSystem.out.print(\"\\ntesting Word Office Open XML Presentation...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(officeOpenXmlPresentationFile2), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/vnd.openxmlformats-officedocument.presentationml.presentation\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOfficeOpenXmlPresentation2()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testOfficeOpenXmlPresentation2(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testOfficeOpenXmlPresentation2(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\t// OTHER\r\n\r\n\tpublic void testPDF() {\r\n\t\tSystem.out.print(\"\\ntesting PDF Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(pdfFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/pdf\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testPDF()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testPDF(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testPDF(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testPostscript() {\r\n\t\tSystem.out.print(\"\\ntesting Postscript Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(psFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/postscript\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testPostscript()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testPostscript(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testPostscript(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testJavaClass12() {\r\n\t\tSystem.out.print(\"\\ntesting Java Class File (v1.2)...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(javaClass12File), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/java\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testJavaClass12()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testJavaClass12(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testJavaClass12(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testJavaClass13() {\r\n\t\tSystem.out.print(\"\\ntesting Java Class File (v1.3)...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(javaClass13File), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/java\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testJavaClass13()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testJavaClass13(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testJavaClass13(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testJavaClass14() {\r\n\t\tSystem.out.print(\"\\ntesting Java Class File (v1.4)...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(javaClass14File), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/java\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testJavaClass14()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testJavaClass14(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testJavaClass14(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testMP3() {\r\n\t\tSystem.out.print(\"\\ntesting MPEG Layer 3...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(mp3_128_44_jstereoFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"audio/mp3\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testMP3()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testMP3(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testMP3(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\r\n\tpublic void testWave() {\r\n\t\tSystem.out.print(\"\\ntesting WAVE...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(wavFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"RIFF (little-endian) data\", match.getDescription());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testWave()\");\r\n\t\t\t}\r\n\t\t\tassertTrue(match.descriptionMatches(\"Microsoft PCM\"));\r\n\t\t\tassertTrue(match.descriptionMatches(\"stereo\"));\r\n\t\t\tassertTrue(match.mimeTypeMatches(\"application/x-wav\"));\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testWave(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testWave(). message: \" + e.getMessage());\r\n\t\t}\r\n\t}\r\n\tpublic void testOdt(){\r\n\t\tSystem.out.print(\"\\ntesting ODT Document...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(odtFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/vnd.oasis.opendocument.text\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOdt()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testOdt(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testOdt(). message: \" + e.getMessage());\r\n\t\t}\r\n\t\t\r\n\t}\r\n\t\r\n\tpublic void testZip(){\r\n\t\tSystem.out.print(\"\\ntesting Zip File...\");\r\n\t\ttry {\r\n\t\t\tMagicMatch match = Magic.getMagicMatch(new File(zipFile), true, false);\r\n\t\t\tif (match != null) {\r\n\t\t\t\tassertEquals(\"application/zip\", match.getMimeType());\r\n\t\t\t} else {\r\n\t\t\t\tSystem.out.print(\"failed\");\r\n\t\t\t\tfail(\"no match in testOdt()\");\r\n\t\t\t}\r\n\t\t\tSystem.out.print(\"ok\");\r\n\t\t} catch (Exception e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"exception in testZip(). message: \" + e);\r\n\t\t} catch (Error e) {\r\n\t\t\te.printStackTrace();\r\n\t\t\tfail(\"error in testZip(). message: \" + e.getMessage());\r\n\t\t}\r\n\t\t\r\n\t}\r\n\t   \r\n    public void testSubMatches(){\r\n        System.out.print(\"\\ntesting Submatches...\");\r\n        try {\r\n            MagicMatch match = Magic.getMagicMatch(new File(gifFile), true, false);\r\n            Assert.assertEquals(3, match.getSubMatches().size());\r\n            match = Magic.getMagicMatch(new File(gifFile), true, false);\r\n            Assert.assertEquals(3, match.getSubMatches().size());           \r\n            System.out.print(\"ok\");\r\n        } catch (Exception e) {\r\n            e.printStackTrace();\r\n            fail(\"exception in testSubMatches(). message: \" + e);\r\n        } catch (Error e) {\r\n            e.printStackTrace();\r\n            fail(\"error in testSubMatches(). message: \" + e.getMessage());\r\n        }\r\n        \r\n    }\r\n\r\n}\r\n"
  },
  {
    "path": "test",
    "content": "#!/bin/sh\n\nmvn exec:java -Dexec.mainClass=\"net.sf.jmimemagic.Magic\" -Dexec.args=\"$1\"\n"
  },
  {
    "path": "test_docs/test.dtd",
    "content": "<!ELEMENT magic (info?,match-list)>\n<!ELEMENT info (version?,author?,description?)>\n<!ELEMENT version (#PCDATA)>\n<!ELEMENT author (#PCDATA)>\n<!ELEMENT description (#PCDATA)>\n<!ELEMENT match-list (match*)>\n<!ELEMENT match (mimetype,extension,description,test,submatch-list?)>\n<!ELEMENT extension (#PCDATA)>\n<!ELEMENT mimetype (#PCDATA)>\n<!ELEMENT description (#PCDATA)>\n<!ELEMENT test (#PCDATA)>\n<!ATTLIST test offset CDATA \"0\">\n<!ATTLIST test type CDATA \"string\">\n<!ATTLIST test bitmask CDATA \"\">\n<!ATTLIST test comparator CDATA \"=\">\n<!ELEMENT submatch-list (match+)>\n\t       \n               \n"
  },
  {
    "path": "test_docs/test.eps",
    "content": "%!PS-Adobe-3.0 EPSF-3.0\n%%Creator: GIMP PostScript file plugin V 1.16 by Peter Kirchgessner\n%%Title: /home/arimus/test.eps\n%%CreationDate: Tue Jun 15 19:43:49 2004\n%%DocumentData: Clean7Bit\n%%LanguageLevel: 2\n%%Pages: 1\n%%BoundingBox: 14 14 115 115\n%%EndComments\n%%BeginProlog\n% Use own dictionary to avoid conflicts\n10 dict begin\n%%EndProlog\n%%Page: 1 1\n% Translate for offset\n14.173228346456694 14.173228346456694 translate\n% Translate to begin of first scanline\n0 99.999999999999986 translate\n99.999999999999986 -99.999999999999986 scale\n% Image geometry\n100 100 8\n% Transformation matrix\n[ 100 0 0 100 0 0 ]\n% Strings to hold RGB-samples per scanline\n/rstr 100 string def\n/gstr 100 string def\n/bstr 100 string def\n{currentfile /ASCII85Decode filter /RunLengthDecode filter rstr readstring pop}\n{currentfile /ASCII85Decode filter /RunLengthDecode filter gstr readstring pop}\n{currentfile /ASCII85Decode filter /RunLengthDecode filter bstr readstring pop}\ntrue 3\n%%BeginData:         4976 ASCII Bytes\ncolorimage\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\np]'IX^]/f~>\np]'IX^]/f~>\np]'IX^]/f~>\np]'IXf`1mMm/MS~>\np]'IXf`1mMm/MS~>\np]'IXf`1mMm/MS~>\np]'IXf`1mMm/MS~>\np]'IXf`1mMm/MS~>\np]'IXf`1mMm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bcN!hCm/MS~>\nmJm+bp\\tTsX'R7b!t-Pd[f6\"#$/9nr)@?QZ2/^>,s8;ras*t~>\nmJm+bp\\tTsX'R7b!t-Pd[f6\"#$/9nr)@?QZ2/^>,s8;ras*t~>\nmJm+bp\\tTsX'R7b!t-Pd[f6\"#$/9nr)@?QZ2/^>,s8;ras*t~>\nmJm+bq#:Aq*V]U81t2:#!qp@1p](=F[f-6t!;$5@~>\nmJm+bq#:Aq*V]U81t2:#!qp@1p](=F[f-6t!;$5@~>\nmJm+bq#:Aq*V]U81t2:#!qp@1p](=F[f-6t!;$5@~>\nmJm+bqYpTqE:j23%)Dc?!W5@X!<)rh!;$5@~>\nmJm+bqYpTqE:j23%)Dc?!W5@X!<)rh!;$5@~>\nmJm+bqYpTqE:j23%)Dc?!W5@X!<)rh!;$5@~>\nmJm+bqYpP=rW!0*?b5S\"jeOC*!!*Yfr;Qbbr;[.#[HID]h5*jJ!<)rh!;$5@~>\nmJm+bqYpP=rW!0*?b5S\"jeOC*!!*Yfr;Qbbr;[.#[HID]h5*jJ!<)rh!;$5@~>\nmJm+bqYpP=rW!0*?b5S\"jeOC*!!*Yfr;Qbbr;[.#[HID]h5*jJ!<)rh!;$5@~>\nmJm+bqu6Z-rVus1_Ya?6pJ(Ve!(m+g!'1#Y!-.i7!SgBFs8;ras*t~>\nmJm+bqu6Z-rVus1_Ya?6pJ(Ve!(m+g!'1#Y!-.i7!SgBFs8;ras*t~>\nmJm+bqu6Z-rVus1_Ya?6pJ(Ve!(m+g!'1#Y!-.i7!SgBFs8;ras*t~>\nmJm+bqu6XJrVur,q>UKd*<#p<d/EtE$iU,+jm`<K!:9`9~>\nmJm+bqu6XJrVur,q>UKd*<#p<d/EtE$iU,+jm`<K!:9`9~>\nmJm+bqu6XJrVur,q>UKd*<#p<d/EtE$iU,+jm`<K!:9`9~>\nmJm+br;Qc5rVupdp\\t5OrVuqDrVlj$rVurpnGiFem/MS~>\nmJm+br;Qc5rVupdp\\t5OrVuqDrVlj$rVurpnGiFem/MS~>\nmJm+br;Qc5rVupdp\\t5OrVuqDrVlj$rVurpnGiFem/MS~>\nmJm+br;Qb:rVuqhp\\t6ArVup]rVlj@rVur6nGiFem/MS~>\nmJm+br;Qb:rVuqhp\\t6ArVup]rVlj@rVur6nGiFem/MS~>\nmJm+br;Qb:rVuqhp\\t6ArVup]rVlj@rVur6nGiFem/MS~>\nmJm+br;QaXrVurEp\\t6brVup8rVlk5rVus?\\af^u!:9`9~>\nmJm+br;QaXrVurEp\\t6brVup8rVlk5rVus?\\af^u!:9`9~>\nmJm+br;QaXrVurEp\\t6brVup8rVlk5rVus?\\af^u!:9`9~>\nmJm+br;Qa5rW)m!rW<'\"qu?^$rVloZ(&\\+7+DIk?p&Fsjm/MS~>\nmJm+br;Qa5rW)m!rW<'\"qu?^$rVloZ(&\\+7+DIk?p&Fsjm/MS~>\nmJm+br;Qa5rW)m!rW<'\"qu?^$rVloZ(&\\+7+DIk?p&Fsjm/MS~>\nmJm+br;Qa#mK!1b!RiOp!!4Zth\"^pJ!:9`9~>\nmJm+br;Qa#mK!1b!RiOp!!4Zth\"^pJ!:9`9~>\nmJm+br;Qa#mK!1b!RiOp!!4Zth\"^pJ!:9`9~>\nmJm+br;Q`umK!.a\"8nua#5\\B%!b1]rs8;ras*t~>\nmJm+br;Q`umK!.a\"8nua#5\\B%!b1]rs8;ras*t~>\nmJm+br;Q`umK!.a\"8nua#5\\B%!b1]rs8;ras*t~>\nmJm+br;Qa-rVurdl2Ln[^4&-Gr;ZjSp&\"df!:9`9~>\nmJm+br;Qa-rVurdl2Ln[^4&-Gr;ZjSp&\"df!:9`9~>\nmJm+br;Qa-rVurdl2Ln[^4&-Gr;ZjSp&\"df!:9`9~>\nmJm+br;QaMrVur?jo5DHJdD>U!/(1Kr;c3aJ,~>\nmJm+br;QaMrVur?jo5DHJdD>U!/(1Kr;c3aJ,~>\nmJm+br;QaMrVur?jo5DHJdD>U!/(1Kr;c3aJ,~>\nmJm+br;Qb-rVuqOj8T+NrVupKqu?Tpm/MS~>\nmJm+br;Qb-rVuqOj8T+NrVupKqu?Tpm/MS~>\nmJm+br;Qb-rVuqOj8T+NrVupKqu?Tpm/MS~>\nmJm+br;Qc'rVusAq;hPUoDS^i#lFW%\"o\\K%r9aN7~>\nmJm+br;Qc'rVusAq;hPUoDS^i#lFW%\"o\\K%r9aN7~>\nmJm+br;Qc'rVusAq;hPUoDS^i#lFW%\"o\\K%r9aN7~>\nmJm+br;Qfq,5qQBHK>)+l2CY_%/^&)'E.t3lL\"V%~>\nmJm+br;Qfq,5qQBHK>)+l2CY_%/^&)'E.t3lL\"V%~>\nmJm+br;Qfq,5qQBHK>)+l2CY_%/^&)'E.t3lL\"V%~>\nmJm+bqu6Z#r;ZkIr:p9m]L)Pr!^XEsq>UG:rVup]qu6XTrVur+mJh\\~>\nmJm+bqu6Z#r;ZkIr:p9m]L)Pr!^XEsq>UG:rVup]qu6XTrVur+mJh\\~>\nmJm+bqu6Z#r;ZkIr:p9m]L)Pr!^XEsq>UG:rVup]qu6XTrVur+mJh\\~>\nmJm+bqYpP8r;[3PNR%\"in(Ojb,6.`As8N'),':6Oq>BHb:]17nW;HSpFoD@C-bJmInGe\"~>\nmJm+bqYpP8r;[3PNR%\"in(Ojb,6.`As8N'),':6Oq>BHb:]17nW;HSpFoD@C-bJmInGe\"~>\nmJm+bqYpP8r;[3PNR%\"in(Ojb,6.`As8N'),':6Oq>BHb:]17nW;HSpFoD@C-bJmInGe\"~>\nmJm+bqYpTqFn,P1s763j@J^!)g'7<PoDa=~>\nmJm+bqYpTqFn,P1s763j@J^!)g'7<PoDa=~>\nmJm+bqYpTqFn,P1s763j@J^!)g'7<PoDa=~>\nmJm+bq#:B(.e`oE\"B!/9s7H?n%Z^ParrJo%q#L$dJ,~>\nmJm+bq#:B(.e`oE\"B!/9s7H?n%Z^ParrJo%q#L$dJ,~>\nmJm+bq#:B(.e`oE\"B!/9s7H?n%Z^ParrJo%q#L$dJ,~>\nmJm+bp\\tX#]l#bD\"9T5g>b:<Yrs[qfGYTh)#6PG_<1<7Krrq>46Q6C6rW)QiJ,~>\nmJm+bp\\tX#]l#bD\"9T5g>b:<Yrs[qfGYTh)#6PG_<1<7Krrq>46Q6C6rW)QiJ,~>\nmJm+bp\\tX#]l#bD\"9T5g>b:<Yrs[qfGYTh)#6PG_<1<7Krrq>46Q6C6rW)QiJ,~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\nSc=3~>\n%%EndData\nshowpage\n%%Trailer\nend\n%%EOF\n"
  },
  {
    "path": "test_docs/test.java",
    "content": "public class test {\n\tpublic static void main(String[] args) {\n\t\tSystem.out.println(\"this is a test java source file\");\n\t}\n}\n"
  },
  {
    "path": "test_docs/test.pl",
    "content": "#!/usr/bin/perl -w\n\nuse strict;\n\nprint \"this is a test perl script\\n\";\n"
  },
  {
    "path": "test_docs/test.pnm",
    "content": "P6\n100 100\n255\n\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000^^^***\r\r\r\u0003\u0003\u0003\u000b\u000b\u000b)))aaa~~~CCC\u001a\u001a\u001a\n\n\n\u0003\u0003\u0003\u0012\u0012\u0012555nnn\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u001d\u001d\u001d\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000444jjj\u0002\u0002\u0002\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000+++\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000ppp\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\f\f\fDDD\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000vvv\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0003\u0003\u0003___夤***\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0010\u0010\u0010\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000PPPݥNNN\u0002\u0002\u0002\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0010\u0010\u0010MMM\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000III999\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000qqqLLL\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000---\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u001c\u001c\u001c\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u000b\u000b\u000b\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000DDD\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000yyy\u0005\u0005\u0005\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000qqq\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000===!!!\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000:::\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0018\u0018\u0018kkk\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u001e\u001e\u001e\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0017\u0017\u0017\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0002\u0002\u0002\u0002\u0002\u0002\u0002\u0002\u0002\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0006\u0006\u0006\u0015\u0015\u0015\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000   iii\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0005\u0005\u0005\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000***\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000+++{{{\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0002\u0002\u0002\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000EEE\u0006\u0006\u0006\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0002\u0002\u0002bbb\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u000f\u000f\u000f\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000~~~;;;\u0003\u0003\u0003\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000333\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000///\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000邂\b\b\b\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000ddd\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000+++\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000   \u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\b\b\b\u0005\u0005\u0005\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\"\"\"\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000zzz\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\f\f\f\u0013\u0013\u0013\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000~~~BBBAAAttt\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000===777\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000qqq\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000&&&ڬttt###\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\"\"\"ttt趶OOO\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000uuu\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000'''\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000uuu\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000aaa\u0006\u0006\u0006\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000***\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0004\u0004\u0004QQQ\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u000e\u000e\u000e\t\t\t\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000nnn777\u0015\u0015\u0015\u0004\u0004\u0004\u0003\u0003\u0003\u0011\u0011\u0011...\\\\\\㪪xxxNNN---\u0014\u0014\u0014\u0007\u0007\u0007\u0003\u0003\u0003\u000e\u000e\u000e&&&TTTCCC\u001b\u001b\u001b\u000b\u000b\u000b\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000"
  },
  {
    "path": "test_docs/test.ppm",
    "content": "P6\n100 100\n255\n\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000^^^***\r\r\r\u0003\u0003\u0003\u000b\u000b\u000b)))aaa~~~CCC\u001a\u001a\u001a\n\n\n\u0003\u0003\u0003\u0012\u0012\u0012555nnn\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u001d\u001d\u001d\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000444jjj\u0002\u0002\u0002\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000+++\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000ppp\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\f\f\fDDD\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000vvv\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0003\u0003\u0003___夤***\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0010\u0010\u0010\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000PPPݥNNN\u0002\u0002\u0002\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0010\u0010\u0010MMM\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000III999\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000qqqLLL\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000---\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u001c\u001c\u001c\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u000b\u000b\u000b\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000DDD\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000yyy\u0005\u0005\u0005\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000qqq\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000===!!!\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000:::\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0018\u0018\u0018kkk\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u001e\u001e\u001e\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0017\u0017\u0017\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0003\u0002\u0002\u0002\u0002\u0002\u0002\u0002\u0002\u0002\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0006\u0006\u0006\u0015\u0015\u0015\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000   iii\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0005\u0005\u0005\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000***\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000+++{{{\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0002\u0002\u0002\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000EEE\u0006\u0006\u0006\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0002\u0002\u0002bbb\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u000f\u000f\u000f\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000~~~;;;\u0003\u0003\u0003\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000333\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000///\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000邂\b\b\b\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000ddd\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000+++\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000   \u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\b\b\b\u0005\u0005\u0005\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\"\"\"\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000zzz\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\f\f\f\u0013\u0013\u0013\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000~~~BBBAAAttt\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000===777\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000qqq\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000&&&ڬttt###\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\"\"\"ttt趶OOO\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000uuu\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000'''\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000uuu\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000aaa\u0006\u0006\u0006\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000***\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0004\u0004\u0004QQQ\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u000e\u000e\u000e\t\t\t\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000nnn777\u0015\u0015\u0015\u0004\u0004\u0004\u0003\u0003\u0003\u0011\u0011\u0011...\\\\\\㪪xxxNNN---\u0014\u0014\u0014\u0007\u0007\u0007\u0003\u0003\u0003\u000e\u000e\u000e&&&TTTCCC\u001b\u001b\u001b\u000b\u000b\u000b\u0001\u0001\u0001\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000\u0000"
  },
  {
    "path": "test_docs/test.ps",
    "content": "%!PS-Adobe-2.0\n%%DocumentFonts: Courier Times-Bold\n%%Title: <stdin> (mpage)\n%%Creator: mpage 2.5.1pre2 March 1998\n%%CreationDate: Tue Jun 15 20:04:08 2004\n%%Orientation: Portrait\n%%DocumentMedia: A4 596 842\n%%BoundingBox: 20 20 576 822\n%%Pages: (atend)\n%%EndComments\n\n%%BeginProlog\n\n/mp_stm usertime def\n/mp_pgc statusdict begin pagecount end def\nstatusdict begin /jobname (<stdin>) def end\n/reencsmalldict 12 dict def /ReEncodeSmall { reencsmalldict begin\n/newcodesandnames exch def /newfontname exch def /basefontname exch def\n/basefontdict basefontname findfont def /newfont basefontdict maxlength dict def\nbasefontdict { exch dup /FID ne { dup /Encoding eq { exch dup length array copy newfont 3 1 roll put } { exch newfont 3 1 roll put }\nifelse }\n  { pop pop }\n  ifelse } forall\nnewfont /FontName newfontname put\nnewcodesandnames aload pop newcodesandnames length 2 idiv\n{ newfont /Encoding get 3 1 roll put } repeat\nnewfontname newfont definefont pop end } def\n/charvec [\n026 /Scaron\n027 /Ydieresis\n028 /Zcaron\n029 /scaron\n030 /trademark\n031 /zcaron\n032 /space\n033 /exclam\n034 /quotedbl\n035 /numbersign\n036 /dollar\n037 /percent\n038 /ampersand\n039 /quoteright\n040 /parenleft\n041 /parenright\n042 /asterisk\n043 /plus\n044 /comma\n045 /minus\n046 /period\n047 /slash\n048 /zero\n049 /one\n050 /two\n051 /three\n052 /four\n053 /five\n054 /six\n055 /seven\n056 /eight\n057 /nine\n058 /colon\n059 /semicolon\n060 /less\n061 /equal\n062 /greater\n063 /question\n064 /at\n065 /A\n066 /B\n067 /C\n068 /D\n069 /E\n070 /F\n071 /G\n072 /H\n073 /I\n074 /J\n075 /K\n076 /L\n077 /M\n078 /N\n079 /O\n080 /P\n081 /Q\n082 /R\n083 /S\n084 /T\n085 /U\n086 /V\n087 /W\n088 /X\n089 /Y\n090 /Z\n091 /bracketleft\n092 /backslash\n093 /bracketright\n094 /asciicircum\n095 /underscore\n096 /quoteleft\n097 /a\n098 /b\n099 /c\n100 /d\n101 /e\n102 /f\n103 /g\n104 /h\n105 /i\n106 /j\n107 /k\n108 /l\n109 /m\n110 /n\n111 /o\n112 /p\n113 /q\n114 /r\n115 /s\n116 /t\n117 /u\n118 /v\n119 /w\n120 /x\n121 /y\n122 /z\n123 /braceleft\n124 /bar\n125 /braceright\n126 /asciitilde\n127 /.notdef\n128 /fraction\n129 /florin\n130 /quotesingle\n131 /quotedblleft\n132 /guilsinglleft\n133 /guilsinglright\n134 /fi\n135 /fl\n136 /endash\n137 /dagger\n138 /daggerdbl\n139 /bullet\n140 /quotesinglbase\n141 /quotedblbase\n142 /quotedblright\n143 /ellipsis\n144 /dotlessi\n145 /grave\n146 /acute\n147 /circumflex\n148 /tilde\n149 /oe\n150 /breve\n151 /dotaccent\n152 /perthousand\n153 /emdash\n154 /ring\n155 /Lslash\n156 /OE\n157 /hungarumlaut\n158 /ogonek\n159 /caron\n160 /lslash\n161 /exclamdown\n162 /cent\n163 /sterling\n164 /currency\n165 /yen\n166 /brokenbar\n167 /section\n168 /dieresis\n169 /copyright\n170 /ordfeminine\n171 /guillemotleft\n172 /logicalnot\n173 /hyphen\n174 /registered\n175 /macron\n176 /degree\n177 /plusminus\n178 /twosuperior\n179 /threesuperior\n180 /acute\n181 /mu\n182 /paragraph\n183 /periodcentered\n184 /cedilla\n185 /onesuperior\n186 /ordmasculine\n187 /guillemotright\n188 /onequarter\n189 /onehalf\n190 /threequarters\n191 /questiondown\n192 /Agrave\n193 /Aacute\n194 /Acircumflex\n195 /Atilde\n196 /Adieresis\n197 /Aring\n198 /AE\n199 /Ccedilla\n200 /Egrave\n201 /Eacute\n202 /Ecircumflex\n203 /Edieresis\n204 /Igrave\n205 /Iacute\n206 /Icircumflex\n207 /Idieresis\n208 /Eth\n209 /Ntilde\n210 /Ograve\n211 /Oacute\n212 /Ocircumflex\n213 /Otilde\n214 /Odieresis\n215 /multiply\n216 /Oslash\n217 /Ugrave\n218 /Uacute\n219 /Ucircumflex\n220 /Udieresis\n221 /Yacute\n222 /Thorn\n223 /germandbls\n224 /agrave\n225 /aacute\n226 /acircumflex\n227 /atilde\n228 /adieresis\n229 /aring\n230 /ae\n231 /ccedilla\n232 /egrave\n233 /eacute\n234 /ecircumflex\n235 /edieresis\n236 /igrave\n237 /iacute\n238 /icircumflex\n239 /idieresis\n240 /eth\n241 /ntilde\n242 /ograve\n243 /oacute\n244 /ocircumflex\n245 /otilde\n246 /odieresis\n247 /divide\n248 /oslash\n249 /ugrave\n250 /uacute\n251 /ucircumflex\n252 /udieresis\n253 /yacute\n254 /thorn\n255 /ydieresis\n] def\n/Courier /OurCharSet charvec ReEncodeSmall\n/textfont /OurCharSet findfont 11 scalefont def\n/fnamefont /Times-Bold findfont 14 scalefont def\n/headerfont /Times-Bold findfont 12 scalefont def\ntextfont setfont\n(a) stringwidth pop /mp_a_x exch def\n%%EndProlog\n%%Page: 1 1\nsave\ngsave\n20 421 translate\n0 0 moveto 0 401 rlineto 278 0 rlineto 0 -401 rlineto closepath clip\n278 80 mp_a_x mul div 401 792 div scale\n4 7 translate 270 278 div 784 792 div scale\ntextfont setfont\n0 780 moveto (This is a plain text file) show\ngrestore\nrestore\nshowpage\n%%Trailer\n%%Pages: 1\n"
  },
  {
    "path": "test_docs/test.py",
    "content": "\"\"\"Append module search paths for third-party packages to sys.path.\n\n****************************************************************\n* This module is automatically imported during initialization. *\n****************************************************************\n\nIn earlier versions of Python (up to 1.5a3), scripts or modules that\nneeded to use site-specific modules would place ``import site''\nsomewhere near the top of their code.  Because of the automatic\nimport, this is no longer necessary (but code that does it still\nworks).\n\nThis will append site-specific paths to to the module search path.  On\nUnix, it starts with sys.prefix and sys.exec_prefix (if different) and\nappends lib/python<version>/site-packages as well as lib/site-python.\nOn other platforms (mainly Mac and Windows), it uses just sys.prefix\n(and sys.exec_prefix, if different, but this is unlikely).  The\nresulting directories, if they exist, are appended to sys.path, and\nalso inspected for path configuration files.\n\nFOR DEBIAN, this sys.path is augmented with directories in /usr/local.\nLocal addons go into /usr/local/lib/python<version>/site-packages\n(resp. /usr/local/lib/site-python), Debian addons install into\n/usr/{lib,share}/python<version>/site-packages.\n\nA path configuration file is a file whose name has the form\n<package>.pth; its contents are additional directories (one per line)\nto be added to sys.path.  Non-existing directories (or\nnon-directories) are never added to sys.path; no directory is added to\nsys.path more than once.  Blank lines and lines beginning with\n'#' are skipped. Lines starting with 'import' are executed.\n\nFor example, suppose sys.prefix and sys.exec_prefix are set to\n/usr/local and there is a directory /usr/local/lib/python2.3/site-packages\nwith three subdirectories, foo, bar and spam, and two path\nconfiguration files, foo.pth and bar.pth.  Assume foo.pth contains the\nfollowing:\n\n  # foo package configuration\n  foo\n  bar\n  bletch\n\nand bar.pth contains:\n\n  # bar package configuration\n  bar\n\nThen the following directories are added to sys.path, in this order:\n\n  /usr/local/lib/python2.3/site-packages/bar\n  /usr/local/lib/python2.3/site-packages/foo\n\nNote that bletch is omitted because it doesn't exist; bar precedes foo\nbecause bar.pth comes alphabetically before foo.pth; and spam is\nomitted because it is not mentioned in either path configuration file.\n\nAfter these path manipulations, an attempt is made to import a module\nnamed sitecustomize, which can perform arbitrary additional\nsite-specific customizations.  If this import fails with an\nImportError exception, it is silently ignored.\n\n\"\"\"\n\nimport sys, os\n\n\ndef makepath(*paths):\n    dir = os.path.abspath(os.path.join(*paths))\n    return dir, os.path.normcase(dir)\n\nfor m in sys.modules.values():\n    if hasattr(m, \"__file__\") and m.__file__:\n        m.__file__ = os.path.abspath(m.__file__)\ndel m\n\n# This ensures that the initial path provided by the interpreter contains\n# only absolute pathnames, even if we're running from the build directory.\nL = []\n_dirs_in_sys_path = {}\ndir = dircase = None  # sys.path may be empty at this point\nfor dir in sys.path:\n    # Filter out duplicate paths (on case-insensitive file systems also\n    # if they only differ in case); turn relative paths into absolute\n    # paths.\n    dir, dircase = makepath(dir)\n    if not dircase in _dirs_in_sys_path:\n        L.append(dir)\n        _dirs_in_sys_path[dircase] = 1\nsys.path[:] = L\ndel dir, dircase, L\n\n# Append ./build/lib.<platform> in case we're running in the build dir\n# (especially for Guido :-)\n# XXX This should not be part of site.py, since it is needed even when\n# using the -S option for Python.  See http://www.python.org/sf/586680\nif (os.name == \"posix\" and sys.path and\n    os.path.basename(sys.path[-1]) == \"Modules\"):\n    from distutils.util import get_platform\n    s = \"build/lib.%s-%.3s\" % (get_platform(), sys.version)\n    s = os.path.join(os.path.dirname(sys.path[-1]), s)\n    sys.path.append(s)\n    del get_platform, s\n\ndef _init_pathinfo():\n    global _dirs_in_sys_path\n    _dirs_in_sys_path = d = {}\n    for dir in sys.path:\n        if dir and not os.path.isdir(dir):\n            continue\n        dir, dircase = makepath(dir)\n        d[dircase] = 1\n\ndef addsitedir(sitedir):\n    global _dirs_in_sys_path\n    if _dirs_in_sys_path is None:\n        _init_pathinfo()\n        reset = 1\n    else:\n        reset = 0\n    sitedir, sitedircase = makepath(sitedir)\n    if not sitedircase in _dirs_in_sys_path:\n        sys.path.append(sitedir)        # Add path component\n    try:\n        names = os.listdir(sitedir)\n    except os.error:\n        return\n    names.sort()\n    for name in names:\n        if name[-4:] == os.extsep + \"pth\":\n            addpackage(sitedir, name)\n    if reset:\n        _dirs_in_sys_path = None\n\ndef addpackage(sitedir, name):\n    global _dirs_in_sys_path\n    if _dirs_in_sys_path is None:\n        _init_pathinfo()\n        reset = 1\n    else:\n        reset = 0\n    fullname = os.path.join(sitedir, name)\n    try:\n        f = open(fullname)\n    except IOError:\n        return\n    while 1:\n        dir = f.readline()\n        if not dir:\n            break\n        if dir[0] == '#':\n            continue\n        if dir.startswith(\"import\"):\n            exec dir\n            continue\n        if dir[-1] == '\\n':\n            dir = dir[:-1]\n        dir, dircase = makepath(sitedir, dir)\n        if not dircase in _dirs_in_sys_path and os.path.exists(dir):\n            sys.path.append(dir)\n            _dirs_in_sys_path[dircase] = 1\n    if reset:\n        _dirs_in_sys_path = None\n\nprefixes = [os.path.join(sys.prefix, \"local\"), sys.prefix]\nsitedir = None # make sure sitedir is initialized because of later 'del'\nif sys.exec_prefix != sys.prefix:\n    prefixes.append(os.path.join(sys.exec_prefix, \"local\"))\nfor prefix in prefixes:\n    if prefix:\n        if sys.platform in ('os2emx', 'riscos'):\n            sitedirs = [os.path.join(prefix, \"Lib\", \"site-packages\")]\n        elif os.sep == '/':\n            sitedirs = [os.path.join(prefix,\n                                     \"lib\",\n                                     \"python\" + sys.version[:3],\n                                     \"site-packages\"),\n                        os.path.join(prefix, \"lib\", \"site-python\")]\n        else:\n            sitedirs = [prefix, os.path.join(prefix, \"lib\", \"site-packages\")]\n        if sys.platform == 'darwin':\n            # for framework builds *only* we add the standard Apple\n            # locations. Currently only per-user, but /Library and\n            # /Network/Library could be added too\n            if 'Python.framework' in prefix:\n                home = os.environ.get('HOME')\n                if home:\n                    sitedirs.append(\n                        os.path.join(home,\n                                     'Library',\n                                     'Python',\n                                     sys.version[:3],\n                                     'site-packages'))\n        for sitedir in sitedirs:\n            if os.path.isdir(sitedir):\n                addsitedir(sitedir)\ndel prefix, sitedir\n\n_dirs_in_sys_path = None\n\n\n# Define new built-ins 'quit' and 'exit'.\n# These are simply strings that display a hint on how to exit.\nif os.sep == ':':\n    exit = 'Use Cmd-Q to quit.'\nelif os.sep == '\\\\':\n    exit = 'Use Ctrl-Z plus Return to exit.'\nelse:\n    exit = 'Use Ctrl-D (i.e. EOF) to exit.'\nimport __builtin__\n__builtin__.quit = __builtin__.exit = exit\ndel exit\n\n# interactive prompt objects for printing the license text, a list of\n# contributors and the copyright notice.\nclass _Printer:\n    MAXLINES = 23\n\n    def __init__(self, name, data, files=(), dirs=()):\n        self.__name = name\n        self.__data = data\n        self.__files = files\n        self.__dirs = dirs\n        self.__lines = None\n\n    def __setup(self):\n        if self.__lines:\n            return\n        data = None\n        for dir in self.__dirs:\n            for file in self.__files:\n                file = os.path.join(dir, file)\n                try:\n                    fp = open(file)\n                    data = fp.read()\n                    fp.close()\n                    break\n                except IOError:\n                    pass\n            if data:\n                break\n        if not data:\n            data = self.__data\n        self.__lines = data.split('\\n')\n        self.__linecnt = len(self.__lines)\n\n    def __repr__(self):\n        self.__setup()\n        if len(self.__lines) <= self.MAXLINES:\n            return \"\\n\".join(self.__lines)\n        else:\n            return \"Type %s() to see the full %s text\" % ((self.__name,)*2)\n\n    def __call__(self):\n        self.__setup()\n        prompt = 'Hit Return for more, or q (and Return) to quit: '\n        lineno = 0\n        while 1:\n            try:\n                for i in range(lineno, lineno + self.MAXLINES):\n                    print self.__lines[i]\n            except IndexError:\n                break\n            else:\n                lineno += self.MAXLINES\n                key = None\n                while key is None:\n                    key = raw_input(prompt)\n                    if key not in ('', 'q'):\n                        key = None\n                if key == 'q':\n                    break\n\n__builtin__.copyright = _Printer(\"copyright\", sys.copyright)\nif sys.platform[:4] == 'java':\n    __builtin__.credits = _Printer(\n        \"credits\",\n        \"Jython is maintained by the Jython developers (www.jython.org).\")\nelse:\n    __builtin__.credits = _Printer(\"credits\", \"\"\"\\\nThanks to CWI, CNRI, BeOpen.com, Zope Corporation and a cast of thousands\nfor supporting Python development.  See www.python.org for more information.\"\"\")\nhere = os.path.dirname(os.__file__)\n__builtin__.license = _Printer(\n    \"license\", \"See http://www.python.org/%.3s/license.html\" % sys.version,\n    [\"LICENSE.txt\", \"LICENSE\"],\n    [os.path.join(here, os.pardir), here, os.curdir])\n\n\n# Define new built-in 'help'.\n# This is a wrapper around pydoc.help (with a twist).\n\nclass _Helper:\n    def __repr__(self):\n        return \"Type help() for interactive help, \" \\\n               \"or help(object) for help about object.\"\n    def __call__(self, *args, **kwds):\n        import pydoc\n        return pydoc.help(*args, **kwds)\n\n__builtin__.help = _Helper()\n\n\n# On Windows, some default encodings are not provided\n# by Python (e.g. \"cp932\" in Japanese locale), while they\n# are always available as \"mbcs\" in each locale.\n# Make them usable by aliasing to \"mbcs\" in such a case.\n\nif sys.platform == 'win32':\n    import locale, codecs\n    enc = locale.getdefaultlocale()[1]\n    if enc.startswith('cp'):            # \"cp***\" ?\n        try:\n            codecs.lookup(enc)\n        except LookupError:\n            import encodings\n            encodings._cache[enc] = encodings._unknown\n            encodings.aliases.aliases[enc] = 'mbcs'\n\n# Set the string encoding used by the Unicode implementation.  The\n# default is 'ascii', but if you're willing to experiment, you can\n# change this.\n\nencoding = \"ascii\" # Default value set by _PyUnicode_Init()\n\nif 0:\n    # Enable to support locale aware default string encodings.\n    import locale\n    loc = locale.getdefaultlocale()\n    if loc[1]:\n        encoding = loc[1]\n\nif 0:\n    # Enable to switch off string to Unicode coercion and implicit\n    # Unicode to string conversion.\n    encoding = \"undefined\"\n\nif encoding != \"ascii\":\n    # On Non-Unicode builds this will raise an AttributeError...\n    sys.setdefaultencoding(encoding) # Needs Python Unicode build !\n\n#\n# Run custom site specific code, if available.\n#\ntry:\n    import sitecustomize\nexcept ImportError:\n    pass\n\n#\n# Remove sys.setdefaultencoding() so that users cannot change the\n# encoding after initialization.  The test for presence is needed when\n# this module is run as a script, because this code is executed twice.\n#\nif hasattr(sys, \"setdefaultencoding\"):\n    del sys.setdefaultencoding\n\ndef _test():\n    print \"sys.path = [\"\n    for dir in sys.path:\n        print \"    %s,\" % `dir`\n    print \"]\"\n\nif __name__ == '__main__':\n    _test()\n"
  },
  {
    "path": "test_docs/test.rtf",
    "content": "{\\rtf1\\ansi\\ansicpg1252\\uc1\\deff0\\stshfdbch0\\stshfloch0\\stshfhich0\\stshfbi0\\deflang1033\\deflangfe1033{\\fonttbl{\\f0\\froman\\fcharset0\\fprq2{\\*\\panose 02020603050405020304}Times New Roman;}{\\f36\\froman\\fcharset238\\fprq2 Times New Roman CE;}\r\n{\\f37\\froman\\fcharset204\\fprq2 Times New Roman Cyr;}{\\f39\\froman\\fcharset161\\fprq2 Times New Roman Greek;}{\\f40\\froman\\fcharset162\\fprq2 Times New Roman Tur;}{\\f41\\froman\\fcharset177\\fprq2 Times New Roman (Hebrew);}\r\n{\\f42\\froman\\fcharset178\\fprq2 Times New Roman (Arabic);}{\\f43\\froman\\fcharset186\\fprq2 Times New Roman Baltic;}{\\f44\\froman\\fcharset163\\fprq2 Times New Roman (Vietnamese);}}{\\colortbl;\\red0\\green0\\blue0;\\red0\\green0\\blue255;\\red0\\green255\\blue255;\r\n\\red0\\green255\\blue0;\\red255\\green0\\blue255;\\red255\\green0\\blue0;\\red255\\green255\\blue0;\\red255\\green255\\blue255;\\red0\\green0\\blue128;\\red0\\green128\\blue128;\\red0\\green128\\blue0;\\red128\\green0\\blue128;\\red128\\green0\\blue0;\\red128\\green128\\blue0;\r\n\\red128\\green128\\blue128;\\red192\\green192\\blue192;}{\\stylesheet{\\ql \\li0\\ri0\\widctlpar\\aspalpha\\aspnum\\faauto\\adjustright\\rin0\\lin0\\itap0 \\fs24\\lang1033\\langfe1033\\cgrid\\langnp1033\\langfenp1033 \\snext0 Normal;}{\\*\\cs10 \\additive \\ssemihidden \r\nDefault Paragraph Font;}{\\*\\ts11\\tsrowd\\trftsWidthB3\\trpaddl108\\trpaddr108\\trpaddfl3\\trpaddft3\\trpaddfb3\\trpaddfr3\\trcbpat1\\trcfpat1\\tscellwidthfts0\\tsvertalt\\tsbrdrt\\tsbrdrl\\tsbrdrb\\tsbrdrr\\tsbrdrdgl\\tsbrdrdgr\\tsbrdrh\\tsbrdrv \r\n\\ql \\li0\\ri0\\widctlpar\\aspalpha\\aspnum\\faauto\\adjustright\\rin0\\lin0\\itap0 \\fs20\\lang1024\\langfe1024\\cgrid\\langnp1024\\langfenp1024 \\snext11 \\ssemihidden Normal Table;}}{\\*\\rsidtbl \\rsid5531693}{\\*\\generator Microsoft Word 10.0.2627;}{\\info\r\n{\\title This is a test RTF document}{\\author David Castro}{\\operator David Castro}{\\creatim\\yr2004\\mo6\\dy17\\hr19\\min29}{\\revtim\\yr2004\\mo6\\dy17\\hr19\\min30}{\\version1}{\\edmins1}{\\nofpages1}{\\nofwords4}{\\nofchars25}{\\*\\company Azusa Pacific University}\r\n{\\nofcharsws28}{\\vern16437}}\\widowctrl\\ftnbj\\aenddoc\\noxlattoyen\\expshrtn\\noultrlspc\\dntblnsbdb\\nospaceforul\\formshade\\horzdoc\\dgmargin\\dghspace180\\dgvspace180\\dghorigin1800\\dgvorigin1440\\dghshow1\\dgvshow1\r\n\\jexpand\\viewkind1\\viewscale100\\pgbrdrhead\\pgbrdrfoot\\splytwnine\\ftnlytwnine\\htmautsp\\nolnhtadjtbl\\useltbaln\\alntblind\\lytcalctblwd\\lyttblrtgr\\lnbrkrule\\nobrkwrptbl\\snaptogridincell\\allowfieldendsel\\wrppunct\\asianbrkrule\\rsidroot5531693 \\fet0\\sectd \r\n\\linex0\\endnhere\\sectlinegrid360\\sectdefaultcl\\sftnbj {\\*\\pnseclvl1\\pnucrm\\pnstart1\\pnindent720\\pnhang {\\pntxta .}}{\\*\\pnseclvl2\\pnucltr\\pnstart1\\pnindent720\\pnhang {\\pntxta .}}{\\*\\pnseclvl3\\pndec\\pnstart1\\pnindent720\\pnhang {\\pntxta .}}{\\*\\pnseclvl4\r\n\\pnlcltr\\pnstart1\\pnindent720\\pnhang {\\pntxta )}}{\\*\\pnseclvl5\\pndec\\pnstart1\\pnindent720\\pnhang {\\pntxtb (}{\\pntxta )}}{\\*\\pnseclvl6\\pnlcltr\\pnstart1\\pnindent720\\pnhang {\\pntxtb (}{\\pntxta )}}{\\*\\pnseclvl7\\pnlcrm\\pnstart1\\pnindent720\\pnhang {\\pntxtb (}\r\n{\\pntxta )}}{\\*\\pnseclvl8\\pnlcltr\\pnstart1\\pnindent720\\pnhang {\\pntxtb (}{\\pntxta )}}{\\*\\pnseclvl9\\pnlcrm\\pnstart1\\pnindent720\\pnhang {\\pntxtb (}{\\pntxta )}}\\pard\\plain \\ql \\li0\\ri0\\widctlpar\\aspalpha\\aspnum\\faauto\\adjustright\\rin0\\lin0\\itap0 \r\n\\fs24\\lang1033\\langfe1033\\cgrid\\langnp1033\\langfenp1033 {\\insrsid5531693 This is a test RTF document\r\n\\par \r\n\\par }}"
  },
  {
    "path": "test_docs/test.sh",
    "content": "#!/bin/bash\n\necho \"this is a test bash script\"\n"
  },
  {
    "path": "test_docs/test.txt",
    "content": "This is a plain text file\n"
  },
  {
    "path": "test_docs/test.xml",
    "content": "<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n<!DOCTYPE magic PUBLIC \"-//jMimeMagic//DTD magic config 1.0//EN\" \"magic_1_0.dtd\">\n<magic>\n<info>\n<version>0.1</version>\n<author>arimus@users.sourceforge.net</author>\n<description>XML magic file</description>\n</info>\n<match-list>\n<match>\n\t<mimetype>application/x-tar</mimetype>\n\t<extension>tar</extension>\n\t<description>POSIX tar archive</description>\n\t<test offset=\"257\" type=\"string\" comparator=\"=\">ustar\\000</test>\n</match>\n<match>\n\t<mimetype>application/x-tar</mimetype>\n\t<extension>tar</extension>\n\t<description>tar archive</description>\n\t<test offset=\"257\" type=\"string\" comparator=\"=\">ustar  \\000GNU</test>\n</match>\n<match>\n\t<mimetype>application/zip</mimetype>\n\t<extension>zip</extension>\n\t<description>archive data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">PK\\003\\004</test>\n</match>\n<match>\n\t<mimetype>application/x-gzip</mimetype>\n\t<extension>gz</extension>\n\t<description>gzip compressed data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">\\037\\213</test>\n</match>\n<match>\n\t<mimetype>application/x-bzip2</mimetype>\n\t<extension>bz2</extension>\n\t<description>bzip2 compressed data</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">BZh</test>\n</match>\n<match>\n\t<mimetype>???</mimetype>\n\t<extension>bat</extension>\n\t<description>MS-DOS batch file text</description>\n\t<test offset=\"0\" type=\"string\" comparator=\"=\">@echo off</test>\n</match>\n</match-list>\n</magic>\n"
  },
  {
    "path": "test_docs/test.xpm",
    "content": "/* XPM */\nstatic char * test_xpm[] = {\n\"100 100 152 2\",\n\"  \tc #FFFFFF\",\n\". \tc #000000\",\n\"+ \tc #FAFAFA\",\n\"@ \tc #ABABAB\",\n\"# \tc #5E5E5E\",\n\"$ \tc #2A2A2A\",\n\"% \tc #0D0D0D\",\n\"& \tc #030303\",\n\"* \tc #0B0B0B\",\n\"= \tc #292929\",\n\"- \tc #616161\",\n\"; \tc #B6B6B6\",\n\"> \tc #FEFEFE\",\n\", \tc #DBDBDB\",\n\"' \tc #7E7E7E\",\n\") \tc #434343\",\n\"! \tc #1A1A1A\",\n\"~ \tc #0A0A0A\",\n\"{ \tc #121212\",\n\"] \tc #353535\",\n\"^ \tc #6E6E6E\",\n\"/ \tc #C3C3C3\",\n\"( \tc #1D1D1D\",\n\"_ \tc #343434\",\n\": \tc #D3D3D3\",\n\"< \tc #F6F6F6\",\n\"[ \tc #6A6A6A\",\n\"} \tc #020202\",\n\"| \tc #2B2B2B\",\n\"1 \tc #707070\",\n\"2 \tc #0C0C0C\",\n\"3 \tc #C0C0C0\",\n\"4 \tc #FCFCFC\",\n\"5 \tc #444444\",\n\"6 \tc #767676\",\n\"7 \tc #5F5F5F\",\n\"8 \tc #BABABA\",\n\"9 \tc #EBEBEB\",\n\"0 \tc #E5E5E5\",\n\"a \tc #A4A4A4\",\n\"b \tc #101010\",\n\"c \tc #DEDEDE\",\n\"d \tc #999999\",\n\"e \tc #505050\",\n\"f \tc #B5B5B5\",\n\"g \tc #E7E7E7\",\n\"h \tc #F8F8F8\",\n\"i \tc #DDDDDD\",\n\"j \tc #A5A5A5\",\n\"k \tc #4E4E4E\",\n\"l \tc #C2C2C2\",\n\"m \tc #F7F7F7\",\n\"n \tc #4D4D4D\",\n\"o \tc #494949\",\n\"p \tc #393939\",\n\"q \tc #717171\",\n\"r \tc #DCDCDC\",\n\"s \tc #4C4C4C\",\n\"t \tc #2D2D2D\",\n\"u \tc #F2F2F2\",\n\"v \tc #1C1C1C\",\n\"w \tc #D0D0D0\",\n\"x \tc #C1C1C1\",\n\"y \tc #8B8B8B\",\n\"z \tc #797979\",\n\"A \tc #050505\",\n\"B \tc #9D9D9D\",\n\"C \tc #D2D2D2\",\n\"D \tc #3D3D3D\",\n\"E \tc #212121\",\n\"F \tc #3A3A3A\",\n\"G \tc #CFCFCF\",\n\"H \tc #F3F3F3\",\n\"I \tc #181818\",\n\"J \tc #6B6B6B\",\n\"K \tc #1E1E1E\",\n\"L \tc #B9B9B9\",\n\"M \tc #171717\",\n\"N \tc #010101\",\n\"O \tc #060606\",\n\"P \tc #E4E4E4\",\n\"Q \tc #151515\",\n\"R \tc #202020\",\n\"S \tc #696969\",\n\"T \tc #AAAAAA\",\n\"U \tc #E9E9E9\",\n\"V \tc #7B7B7B\",\n\"W \tc #454545\",\n\"X \tc #626262\",\n\"Y \tc #F1F1F1\",\n\"Z \tc #0F0F0F\",\n\"` \tc #EEEEEE\",\n\" .\tc #BEBEBE\",\n\"..\tc #3B3B3B\",\n\"+.\tc #333333\",\n\"@.\tc #F5F5F5\",\n\"#.\tc #2F2F2F\",\n\"$.\tc #C9C9C9\",\n\"%.\tc #828282\",\n\"&.\tc #080808\",\n\"*.\tc #838383\",\n\"=.\tc #646464\",\n\"-.\tc #848484\",\n\";.\tc #9E9E9E\",\n\">.\tc #B3B3B3\",\n\",.\tc #F9F9F9\",\n\"'.\tc #222222\",\n\").\tc #7A7A7A\",\n\"!.\tc #131313\",\n\"~.\tc #EAEAEA\",\n\"{.\tc #B0B0B0\",\n\"].\tc #BCBCBC\",\n\"^.\tc #424242\",\n\"/.\tc #414141\",\n\"(.\tc #747474\",\n\"_.\tc #373737\",\n\":.\tc #262626\",\n\"<.\tc #8D8D8D\",\n\"[.\tc #CECECE\",\n\"}.\tc #EFEFEF\",\n\"|.\tc #FBFBFB\",\n\"1.\tc #DADADA\",\n\"2.\tc #ACACAC\",\n\"3.\tc #232323\",\n\"4.\tc #E1E1E1\",\n\"5.\tc #E8E8E8\",\n\"6.\tc #4F4F4F\",\n\"7.\tc #A8A8A8\",\n\"8.\tc #757575\",\n\"9.\tc #272727\",\n\"0.\tc #BBBBBB\",\n\"a.\tc #F0F0F0\",\n\"b.\tc #B7B7B7\",\n\"c.\tc #040404\",\n\"d.\tc #515151\",\n\"e.\tc #C5C5C5\",\n\"f.\tc #0E0E0E\",\n\"g.\tc #8E8E8E\",\n\"h.\tc #090909\",\n\"i.\tc #BDBDBD\",\n\"j.\tc #111111\",\n\"k.\tc #2E2E2E\",\n\"l.\tc #5C5C5C\",\n\"m.\tc #ECECEC\",\n\"n.\tc #E3E3E3\",\n\"o.\tc #787878\",\n\"p.\tc #141414\",\n\"q.\tc #070707\",\n\"r.\tc #545454\",\n\"s.\tc #9A9A9A\",\n\"t.\tc #E0E0E0\",\n\"u.\tc #1B1B1B\",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                    . . . . . . . . . . . . . . . . . . . . . . . .                                                                                                                                     \",\n\"                    . . . . . . . . . . . . . . . . . . . . . . . .                                                                                   . . . .                                           \",\n\"                    . . . . . . . . . . . . . . . . . . . . . . . .                                                                                   . . . .                                           \",\n\"                                        . . . .                                                                                                       . . . .                                           \",\n\"                                        . . . .                                                                                                       . . . .                                           \",\n\"                                        . . . .                                                                                                       . . . .                                           \",\n\"                                        . . . .                     + @ # $ % & * = - ; >                       , ' ) ! ~ & { ] ^ /                   . . . .                                           \",\n\"                                        . . . .                   @ ( . . . . . . . . . _ :                 < [ } . . . . . . . . . | ;         . . . . . . . . . . . . . .                             \",\n\"                                        . . . .               > 1 . . . . . . . . . . . . 2 3             4 5 . . . . . . . . . . . . .         . . . . . . . . . . . . . .                             \",\n\"                                        . . . .               6 . . . & 7 8 9 + 0 a $ . . . b c           d . . . . e f g + h i j k } .         . . . . . . . . . . . . . .                             \",\n\"                                        . . . .             8 . . . b l             m n . . . o           p . . . q                 r s               . . . .                                           \",\n\"                                        . . . .             t . . . ;                 u v . . . w         * . . . 0                                   . . . .                                           \",\n\"                                        . . . .           x . . . 5                     y . . . z         A . . . +                                   . . . .                                           \",\n\"                                        . . . .           q . . . B                     C . . . D         E . . . 3                                   . . . .                                           \",\n\"                                        . . . .           F . . . G                     H . . . I         J . . . K L                                 . . . .                                           \",\n\"                                        . . . .           M . . . & & & & } } } N N N . . . . . O         P Q . . . . R S T U                         . . . .                                           \",\n\"                                        . . . .           A . . . . . . . . . . . . . . . . . . .           : $ . . . . . . . | V r                   . . . .                                           \",\n\"                                        . . . .           } . . . . . . . . . . . . . . . . . . .             4 j W O . . . . . . } X Y               . . . .                                           \",\n\"                                        . . . .           Z . . . `                                                 <  .' ..& . . . . +.@.            . . . .                                           \",\n\"                                        . . . .           #.. . . $.                                                        U %.&.. . . *.            . . . .                                           \",\n\"                                        . . . .           =.. . . -.                                                            ;.. . . |             . . . .                                           \",\n\"                                        . . . .           >.. . . R ,.                                                          H . . . &.            A . . . 4                                         \",\n\"                                        . . . .           4 '.. . . ).                                                          U . . . 2             !.. . . ~.                                        \",\n\"                                        . . . .             {.. . . . ' 4                   ].^.          /.8 >                 (.. . . D             _.. . . f                                         \",\n\"                                        . . . .               q . . . . :.<.[.}.|.}.1.2.(.3.. .           . . '.(.f 4.,.4 5.; 6.. . . . 7.            8.. . . 9.0.a.>                                   \",\n\"                                        . . . .               > 8.. . . . . . . . . . . . . . .           . . . . . . . . . . . . . . -               1.O . . . . . . . . .                             \",\n\"                                        . . . .                   b.$ . . . . . . . . . . c.d.e.          . . . . . . . . . . . . f.g.>                 a h.. . . . . . . .                             \",\n\"                                        . . . .                     > i.^ _.Q c.& j.k.l.;.m.              n.T o.k t p.q.& f.:.r.s.`                       t.%.) u.* N . . .                             \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \",\n\"                                                                                                                                                                                                        \"};\n"
  },
  {
    "path": "test_docs/test_excel_spreadsheet.xml",
    "content": "<?xml version=\"1.0\"?>\r\n<Workbook xmlns=\"urn:schemas-microsoft-com:office:spreadsheet\"\r\n xmlns:o=\"urn:schemas-microsoft-com:office:office\"\r\n xmlns:x=\"urn:schemas-microsoft-com:office:excel\"\r\n xmlns:ss=\"urn:schemas-microsoft-com:office:spreadsheet\"\r\n xmlns:html=\"http://www.w3.org/TR/REC-html40\">\r\n <DocumentProperties xmlns=\"urn:schemas-microsoft-com:office:office\">\r\n  <Author>David Castro</Author>\r\n  <LastAuthor>David Castro</LastAuthor>\r\n  <Created>2004-06-16T02:29:05Z</Created>\r\n  <LastSaved>2004-06-16T02:29:24Z</LastSaved>\r\n  <Company>Azusa Pacific University</Company>\r\n  <Version>10.2625</Version>\r\n </DocumentProperties>\r\n <OfficeDocumentSettings xmlns=\"urn:schemas-microsoft-com:office:office\">\r\n  <DownloadComponents/>\r\n  <LocationOfComponents HRef=\"file:///Z:\\mnt\\c\\Documents%20and%20Settings\\Administrator\\Desktop\\download\\Office%20XP%20Pro\\\"/>\r\n </OfficeDocumentSettings>\r\n <ExcelWorkbook xmlns=\"urn:schemas-microsoft-com:office:excel\">\r\n  <WindowHeight>12660</WindowHeight>\r\n  <WindowWidth>17100</WindowWidth>\r\n  <WindowTopX>360</WindowTopX>\r\n  <WindowTopY>60</WindowTopY>\r\n  <ProtectStructure>False</ProtectStructure>\r\n  <ProtectWindows>False</ProtectWindows>\r\n </ExcelWorkbook>\r\n <Styles>\r\n  <Style ss:ID=\"Default\" ss:Name=\"Normal\">\r\n   <Alignment ss:Vertical=\"Bottom\"/>\r\n   <Borders/>\r\n   <Font/>\r\n   <Interior/>\r\n   <NumberFormat/>\r\n   <Protection/>\r\n  </Style>\r\n </Styles>\r\n <Worksheet ss:Name=\"Sheet1\">\r\n  <Table ss:ExpandedColumnCount=\"1\" ss:ExpandedRowCount=\"1\" x:FullColumns=\"1\"\r\n   x:FullRows=\"1\">\r\n   <Row>\r\n    <Cell><Data ss:Type=\"String\">Test excel 2000 spreadsheet</Data></Cell>\r\n   </Row>\r\n  </Table>\r\n  <WorksheetOptions xmlns=\"urn:schemas-microsoft-com:office:excel\">\r\n   <Selected/>\r\n   <ProtectObjects>False</ProtectObjects>\r\n   <ProtectScenarios>False</ProtectScenarios>\r\n  </WorksheetOptions>\r\n </Worksheet>\r\n <Worksheet ss:Name=\"Sheet2\">\r\n  <WorksheetOptions xmlns=\"urn:schemas-microsoft-com:office:excel\">\r\n   <ProtectObjects>False</ProtectObjects>\r\n   <ProtectScenarios>False</ProtectScenarios>\r\n  </WorksheetOptions>\r\n </Worksheet>\r\n <Worksheet ss:Name=\"Sheet3\">\r\n  <WorksheetOptions xmlns=\"urn:schemas-microsoft-com:office:excel\">\r\n   <ProtectObjects>False</ProtectObjects>\r\n   <ProtectScenarios>False</ProtectScenarios>\r\n  </WorksheetOptions>\r\n </Worksheet>\r\n</Workbook>\r\n"
  },
  {
    "path": "test_docs/test_excel_web_archive.mht",
    "content": "MIME-Version: 1.0\r\nX-Document-Type: Worksheet\r\nContent-Location: file:///C:/2A65B325/test_excel_web_archive.htm\r\nContent-Transfer-Encoding: quoted-printable\r\nContent-Type: text/html; charset=\"us-ascii\"\r\n\r\n<html xmlns:o=3D\"urn:schemas-microsoft-com:office:office\"\r\nxmlns:x=3D\"urn:schemas-microsoft-com:office:excel\"\r\nxmlns=3D\"http://www.w3.org/TR/REC-html40\">\r\n\r\n<head>\r\n<meta http-equiv=3DContent-Type content=3D\"text/html; charset=3Dus-ascii\">\r\n<meta name=3DProgId content=3DExcel.Sheet>\r\n<meta name=3DGenerator content=3D\"Microsoft Excel 10\">\r\n<link rel=3DFile-List href=3D\"test_excel_web_archive_files/filelist.xml\">\r\n<link rel=3DEdit-Time-Data href=3D\"test_excel_web_archive_files/editdata.ms=\r\no\">\r\n<link rel=3DOLE-Object-Data href=3D\"test_excel_web_archive_files/oledata.ms=\r\no\">\r\n<!--[if gte mso 9]><xml>\r\n <o:DocumentProperties>\r\n  <o:Author>David Castro</o:Author>\r\n  <o:LastAuthor>David Castro</o:LastAuthor>\r\n  <o:Created>2004-06-16T02:29:05Z</o:Created>\r\n  <o:LastSaved>2004-06-16T02:31:29Z</o:LastSaved>\r\n  <o:Company>Azusa Pacific University</o:Company>\r\n  <o:Version>10.2625</o:Version>\r\n </o:DocumentProperties>\r\n <o:OfficeDocumentSettings>\r\n  <o:DownloadComponents/>\r\n  <o:LocationOfComponents HRef=3D\"file:///Z:\\mnt\\c\\Documents%20and%20Settin=\r\ngs\\Administrator\\Desktop\\download\\Office%20XP%20Pro\\\"/>\r\n </o:OfficeDocumentSettings>\r\n</xml><![endif]-->\r\n<style>\r\n<!--table\r\n\t{mso-displayed-decimal-separator:\"\\.\";\r\n\tmso-displayed-thousand-separator:\"\\,\";}\r\n@page\r\n\t{margin:1.0in .75in 1.0in .75in;\r\n\tmso-header-margin:.5in;\r\n\tmso-footer-margin:.5in;}\r\ntr\r\n\t{mso-height-source:auto;}\r\ncol\r\n\t{mso-width-source:auto;}\r\nbr\r\n\t{mso-data-placement:same-cell;}\r\n.style0\r\n\t{mso-number-format:General;\r\n\ttext-align:general;\r\n\tvertical-align:bottom;\r\n\twhite-space:nowrap;\r\n\tmso-rotate:0;\r\n\tmso-background-source:auto;\r\n\tmso-pattern:auto;\r\n\tcolor:windowtext;\r\n\tfont-size:10.0pt;\r\n\tfont-weight:400;\r\n\tfont-style:normal;\r\n\ttext-decoration:none;\r\n\tfont-family:Arial;\r\n\tmso-generic-font-family:auto;\r\n\tmso-font-charset:0;\r\n\tborder:none;\r\n\tmso-protection:locked visible;\r\n\tmso-style-name:Normal;\r\n\tmso-style-id:0;}\r\ntd\r\n\t{mso-style-parent:style0;\r\n\tpadding-top:1px;\r\n\tpadding-right:1px;\r\n\tpadding-left:1px;\r\n\tmso-ignore:padding;\r\n\tcolor:windowtext;\r\n\tfont-size:10.0pt;\r\n\tfont-weight:400;\r\n\tfont-style:normal;\r\n\ttext-decoration:none;\r\n\tfont-family:Arial;\r\n\tmso-generic-font-family:auto;\r\n\tmso-font-charset:0;\r\n\tmso-number-format:General;\r\n\ttext-align:general;\r\n\tvertical-align:bottom;\r\n\tborder:none;\r\n\tmso-background-source:auto;\r\n\tmso-pattern:auto;\r\n\tmso-protection:locked visible;\r\n\twhite-space:nowrap;\r\n\tmso-rotate:0;}\r\n-->\r\n</style>\r\n<!--[if gte mso 9]><xml>\r\n <x:ExcelWorkbook>\r\n  <x:ExcelWorksheets>\r\n   <x:ExcelWorksheet>\r\n    <x:Name>Sheet1</x:Name>\r\n    <x:WorksheetOptions>\r\n     <x:Selected/>\r\n     <x:ProtectContents>False</x:ProtectContents>\r\n     <x:ProtectObjects>False</x:ProtectObjects>\r\n     <x:ProtectScenarios>False</x:ProtectScenarios>\r\n    </x:WorksheetOptions>\r\n   </x:ExcelWorksheet>\r\n   <x:ExcelWorksheet>\r\n    <x:Name>Sheet2</x:Name>\r\n    <x:WorksheetOptions>\r\n     <x:ProtectContents>False</x:ProtectContents>\r\n     <x:ProtectObjects>False</x:ProtectObjects>\r\n     <x:ProtectScenarios>False</x:ProtectScenarios>\r\n    </x:WorksheetOptions>\r\n   </x:ExcelWorksheet>\r\n   <x:ExcelWorksheet>\r\n    <x:Name>Sheet3</x:Name>\r\n    <x:WorksheetOptions>\r\n     <x:ProtectContents>False</x:ProtectContents>\r\n     <x:ProtectObjects>False</x:ProtectObjects>\r\n     <x:ProtectScenarios>False</x:ProtectScenarios>\r\n    </x:WorksheetOptions>\r\n   </x:ExcelWorksheet>\r\n  </x:ExcelWorksheets>\r\n  <x:WindowHeight>12660</x:WindowHeight>\r\n  <x:WindowWidth>17100</x:WindowWidth>\r\n  <x:WindowTopX>360</x:WindowTopX>\r\n  <x:WindowTopY>60</x:WindowTopY>\r\n  <x:ProtectStructure>False</x:ProtectStructure>\r\n  <x:ProtectWindows>False</x:ProtectWindows>\r\n </x:ExcelWorkbook>\r\n</xml><![endif]-->\r\n</head>\r\n\r\n<body link=3Dblue vlink=3Dpurple>\r\n\r\n<table x:str border=3D0 cellpadding=3D0 cellspacing=3D0 width=3D192 style=\r\n=3D'border-collapse:\r\n collapse;table-layout:fixed;width:144pt'>\r\n <col width=3D64 span=3D3 style=3D'width:48pt'>\r\n <tr height=3D17 style=3D'height:12.75pt'>\r\n  <td height=3D17 colspan=3D3 width=3D192 style=3D'height:12.75pt;mso-ignor=\r\ne:colspan;\r\n  width:144pt'>Test excel 2000 spreadsheet</td>\r\n </tr>\r\n <![if supportMisalignedColumns]>\r\n <tr height=3D0 style=3D'display:none'>\r\n  <td width=3D64 style=3D'width:48pt'></td>\r\n  <td width=3D64 style=3D'width:48pt'></td>\r\n  <td width=3D64 style=3D'width:48pt'></td>\r\n </tr>\r\n <![endif]>\r\n</table>\r\n\r\n</body>\r\n\r\n</html>\r\n"
  }
]