{"id":13553063,"url":"https://github.com/digital-preservation/droid","last_synced_at":"2025-05-15T20:00:45.741Z","repository":{"id":3668969,"uuid":"4737996","full_name":"digital-preservation/droid","owner":"digital-preservation","description":"DROID (Digital Record and Object Identification)","archived":false,"fork":false,"pushed_at":"2025-05-12T09:52:57.000Z","size":23195,"stargazers_count":322,"open_issues_count":114,"forks_count":76,"subscribers_count":39,"default_branch":"main","last_synced_at":"2025-05-12T10:45:19.595Z","etag":null,"topics":["droid","file-identification","file-identity","identification","java","pronom"],"latest_commit_sha":null,"homepage":"","language":"Java","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":"ReactiveX/RxAndroid","license":"bsd-3-clause","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/digital-preservation.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2012-06-21T10:54:31.000Z","updated_at":"2025-05-08T13:53:00.000Z","dependencies_parsed_at":"2023-07-05T19:16:36.113Z","dependency_job_id":"85783987-ba96-4964-9616-414895e35a18","html_url":"https://github.com/digital-preservation/droid","commit_stats":{"total_commits":1508,"total_committers":44,"mean_commits":34.27272727272727,"dds":0.8236074270557029,"last_synced_commit":"2fdeab05e76191e920e91aadf0c4add3a3169f40"},"previous_names":[],"tags_count":40,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-preservation%2Fdroid","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-preservation%2Fdroid/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-preservation%2Fdroid/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/digital-preservation%2Fdroid/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/digital-preservation","download_url":"https://codeload.github.com/digital-preservation/droid/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":254414457,"owners_count":22067263,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["droid","file-identification","file-identity","identification","java","pronom"],"created_at":"2024-08-01T12:02:16.622Z","updated_at":"2025-05-15T20:00:45.534Z","avatar_url":"https://github.com/digital-preservation.png","language":"Java","readme":"# DROID (Digital Record Object Identification)  \n\n[![CI](https://github.com/digital-preservation/droid/workflows/CI/badge.svg)](https://github.com/digital-preservation/droid/actions?query=workflow%3ACI)\n[![Coverage Status](https://coveralls.io/repos/github/digital-preservation/droid/badge.svg?branch=master)](https://coveralls.io/github/digital-preservation/droid?branch=master)\n[![Maven Central](https://maven-badges.herokuapp.com/maven-central/uk.gov.nationalarchives/droid/badge.svg)](https://search.maven.org/search?q=g:uk.gov.nationalarchives)\n\n## General Information\n\nDROID is a software tool developed by [The National Archives](http://www.nationalarchives.gov.uk/ \"The National Archives Website\") to perform automated batch identification of file formats. Developed by its Digital Preservation Department as part of its broader digital preservation activities, DROID is designed to meet the fundamental requirement of any digital repository to be able to identify the precise format of all stored digital objects, and to link that identification to a central registry of technical information about that format and its dependencies.\n\nDROID uses internal signatures to identify and report the specific file format versions of digital files. These signatures are stored in an XML signature file, generated from information recorded in the [PRONOM technical registry](http://www.nationalarchives.gov.uk/PRONOM/Default.aspx \"PRONOM Technical Registry\"). New and updated signatures are regularly added to PRONOM, and DROID can be configured to automatically download updated signature files.\n\nDROID is a platform-independent Java application. It can be invoked from two interfaces:\n\n* Java Swing GUI\n* Command line interface\n\nDROID allows files and folders to be selected from a file system for identification. This file list can be saved at any point. After the identification process had been run, the results can be output in various report formats, including CSV.\n\nDROID is made available under the [New BSD License](https://raw.github.com/digital-preservation/droid/master/license.md).\n\nMore information can be found on the [DROID github pages](https://digital-preservation.github.io/droid/).\n\n## Installing DROID\n\nThe latest binary file can be downloaded from [The National Archives website](https://www.nationalarchives.gov.uk/information-management/manage-information/preserving-digital-records/droid/ \"The National Archives website\").\n\n## Running DROID\n\nDROID can be run either as a graphical desktop application (GUI) or as a command line tool (CLI). GUI usage is explained in the [DROID User Guide](https://cdn.nationalarchives.gov.uk/documents/information-management/droid-user-guide.pdf).\n\n### Basic command line examples\n\nAssuming the `droid` executable (the `droid.sh` or `droid.bat` file) is in your PATH, run one of the following two commands to identify the file `file.jpg` or the directory `directory` (recursively, thanks to the `-R`, or `--recurse` switch), respectively:\n\n~~~console\n$ droid file.jpg\n\"ID\",\"PARENT_ID\",\"URI\",\"FILE_PATH\",\"NAME\",\"METHOD\",\"STATUS\",\"SIZE\",\"TYPE\",\"EXT\",\"LAST_MODIFIED\",\"EXTENSION_MISMATCH\",\"HASH\",\"FORMAT_COUNT\",\"PUID\",\"MIME_TYPE\",\"FORMAT_NAME\",\"FORMAT_VERSION\"\n\"1\",\"\",\"file:/home/user/file.jpg\",\"/home/user/file.jpg\",\"file.jpg\",\"Signature\",\"Done\",\"1689552\",\"File\",\"jpg\",\"2017-11-21T06:52:50\",\"false\",\"\",\"1\",\"fmt/1507\",\"image/jpeg\",\"Exchangeable Image File Format (Compressed)\",\"2.3.x\"\n\n$ droid -R directory\n...\n~~~\n\nIf you don't need every bit of information that DROID outputs by default you can make it print only a limited set of columns using the `-co`, or `--columns` option (note the `-a`, it's required in this case!):\n\n~~~console\n$ droid -co NAME PUID -a file.jpg\n\"NAME\",\"PUID\"\n\"file.jpg\",\"fmt/1507\"\n~~~\n\nTo remove even more noise from the output you can use the `-qc`, or `--quote-commas` switch which tells DROID to use quotes only where necessary:\n\n~~~console\n$ droid -qc -co NAME PUID -a file.jpg\nNAME,PUID\nfile.jpg,fmt/1507\n~~~\n\nBeyond these basic invocations there are many additional options for advanced tweaking of DROID's operation. To learn about them run:\n\n~~~console\n$ droid --help\n~~~\n\n### Managing signature files in the command line interface\n\nIt's possible to update and switch signature files on the command line. Use `-c`, or `--check-signature-update` to check for updates; use `-d`, or `--download-signature-update` to download (and use) the latest signature files:\n\n~~~console\n$ droid -c\nContainer signature update Version 20231127 is available\nBinary signature update Version 116 is available\n\n$ droid -d\nSignature update version 20.231.127 has been downloaded\nSignature update version 116 has been downloaded\n~~~\n\nUse `-x`, or `--display-signature-file` to see the signature files that DROID currently uses for identification; use `-X`, or `--list-signature-files` to see all locally available signature files (i.e., all files that you have installed on your machine including those that are currently not in use):\n\n~~~console\n$ droid -x\nType: Container Version:  20231127  File name: container-signature-20231127.xml\nType: Binary Version:  116  File name: DROID_SignatureFile_V116.xml\n\n$ droid -X\nType: Binary Version:  114  File name: DROID_SignatureFile_V114.xml\nType: Binary Version:  116  File name: DROID_SignatureFile_V116.xml\nType: Container Version:  20230822  File name: container-signature-20230822.xml\nType: Container Version:  20231127  File name: container-signature-20231127.xml\n~~~\n\nIf for some reason you want to use another, possibly older signature file for identification you can change the default with the `-s`, or `--set-signature-file` option (remember to switch back to the latest version when you are done!):\n\n~~~console\n$ droid -s 114\nDefault signature file updated. Version: 114  File name: DROID_SignatureFile_V114.xml\n\n$ droid -s 20230822\nDefault signature file updated. Version: 20230822  File name: container-signature-20230822.xml\n~~~\n\n## Building DROID\n\nDROID can be built from source using Maven. The source code can be obtained from the Github repository at [https://github.com/digital-preservation/droid](https://github.com/digital-preservation/droid)\n   \nOnce the code is cloned into a folder (e.g. `droid`), executing `mvn clean install` inside it will build the code. After a successful build, two archives are provided inside the `droid-binary/target` folder.\n\n### Linux / OSX users\n\nYou will need JAVA 8 to 17 installed to run DROID.\n\nUnpack the archive `droid-binary-${VERSION}-bin.zip`, then use the `droid.sh` script to run the application.\n\n### Windows users\nArchive  `droid-binary-${VERSION}-bin-win64-with-jre.zip`\n\n\nYou will need JAVA 8 to 17 installed to run DROID. For Windows users who might not be able to install JAVA, the provided bundle includes JAVA 17.\n\nUnpack the archive `droid-binary-${VERSION}-bin-win64-with-jre.zip`, then use the `droid.bat` script to run the application.\n\n## Signatures\n\nSince version 6.5, DROID adds some new capabilities to support developing and testing signatures.\n\n[Signature syntax](Signature%20syntax.md) provides details on the types of signatures and regular expression syntax supported by DROID.\n\n### sigtool\n\nTo aid work on signatures, we provide `sigtool`, packaged with DROID. `sigtool` is a simple command line application which can:\n\n * test binary or container signatures directly against files.\n * generate signature XML from binary or container signatures.\n * convert signatures between the original (binary) and the newer (container) syntax.\n * produce summaries of signature XML files, converting the XML back into signatures.\n * convert standard XML signature files into a simpler format, which uses the signatures directly.\n\nMore details are provided in [Sigtool's user guide](droid-binary/bin/Using%20sigtool.txt) .\n\n### Simpler signature XML\n\nSince version 6.5, DROID can compile signatures itself, without needing a full XML specification. Inside current signature files, the actual sequences to match are specified in various sub-elements and attributes of `\u003cByteSequence\u003e` elements. \n\nFor example, the signature `{10-1024} 01 02 03 04 05 [00:30] * 01 02 03` is represented in signature XML by:\n\n```xml\n\u003cByteSequence Reference=\"BOFoffset\"\u003e\n    \u003cSubSequence SubSeqMinOffset=\"10\" SubSeqMaxOffset=\"1024\"\u003e\n        \u003cSequence\u003e01 02 03 04 05\u003c/Sequence\u003e\n        \u003cRightFragment MaxOffset=\"0\" MinOffset=\"0\" Position=\"1\"\u003e[00:30]\u003c/RightFragment\u003e\n    \u003c/SubSequence\u003e\n    \u003cSubSequence\u003e\n        \u003cSequence\u003e01 02 03\u003c/Sequence\u003e\n    \u003c/SubSequence\u003e\n\u003c/ByteSequence\u003e\n```\n\nDROID can now put a signature directly inside a `Sequence` attribute on the `\u003cByteSequence\u003e` element, with no further XML required.  For example, the signature above can be simply written as:\n\n```xml\n\u003cByteSequence Reference=\"BOFoffset\" Sequence=\"{10-1024} 01 02 03 04 05 [00:30] * 01 02 03\" /\u003e\n```\n\nThe full syntax can be used in either binary or container signature files.\n\n## Developer related guidance\n\nFor any detais about contributing, testing, releasing, please check the [wiki](https://github.com/digital-preservation/droid/wiki)\n\n","funding_links":[],"categories":["Java","java","SoftwareTools"],"sub_categories":["DROID"],"project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigital-preservation%2Fdroid","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdigital-preservation%2Fdroid","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdigital-preservation%2Fdroid/lists"}