Kaitai Struct: library of binary file formats (.ksy)
Switch branches/tags
Nothing to show
Clone or download
Latest commit 702e5be Oct 14, 2018
Permalink
Failed to load latest commit information.
.circleci Replaced key imported from keyserver with a key in a file Aug 22, 2018
_build Added some handling of xrefs Aug 1, 2018
archive Added support for extra fields parsing + some individual extra fields Jun 16, 2017
cad Fix some grammar and improved docs slightly Jul 18, 2017
common BCD: more docstrings Jun 5, 2018
database Added license Sep 26, 2017
executable Merge pull request #100 from yuvaljacoby/pe_ksy_fix Oct 7, 2018
filesystem Added title + license Oct 13, 2018
firmware Fixed the remaining style guide problems Sep 5, 2017
font ttf: more work on name, added platform enum, added orig IDs, fixed fi… Oct 10, 2017
game Added Allegro .dat file format Oct 7, 2018
geospatial Add Shapefile main (.shp) and index (.shx) formats (#29) Apr 1, 2017
hardware mifare_classic: fix meta ordering, added ks-version Aug 10, 2018
image Read GIFs till EOF block Jan 10, 2018
log Fixed license / title Sep 26, 2017
machine_code Added license and doc Jun 6, 2017
media Simplified `samples_data` by passing header inside, not just the inde… Aug 11, 2018
network [network/icmp_packet] add missing data field Mar 22, 2018
scientific Merge pull request #93 from FilipDominec/master Apr 17, 2018
security openpgp: fix id and metadata Aug 21, 2018
serialization Added license, docs and object_id notes Oct 13, 2018
windows Added Windows MiniDump (MDMP) format spec Oct 21, 2017
.editorconfig Added .editorconfig Oct 16, 2017
.gitattributes Add syntax highlighting for .ksy files Aug 17, 2017
README.md Reworked README: removed layout info (website shows it much clearer a… Jun 6, 2017

README.md

Kaitai Struct: formats library

This repository constitutes a library of ready-made binary file format descriptions using Kaitai Struct language (.ksy).

These formats can be useful for:

  • exploring a certain file format internals: one can load .ksy format + target binary in a Web IDE or visualizer and learn what's inside;

  • as a production-ready binary file parsing library: they can be compiled with a Kaitai Struct compiler into source code in any supported target programming language;

  • as a starting point for learning applications of Kaitai Struct in real world;

Exploring this repository

If you want to explore the repository, please visit Kaitai Struct format gallery — that's HTML rendition of this repository, which block diagrams, all the code compiled for all possible target languages, provided with usage examples and instructions, etc, etc.

Alternatively, you can start with Web IDE — this library of formats also comes pre-loaded with it.

Contributing

If you've developed a format specification using Kaitai Struct and would like to make the world a little better by sharing your knowledge, so other fellow developers don't have to redo the same parsing task again and again from scratch — that's great, your contribution would be most welcome!

Please follow these steps:

  • Choose open source license for your .ksy
    • We recommend either CC0-1.0 if it's a trivial transcription of some specification into formal .ksy, or MIT license if your .ksy is non-trivial and creative approach to a format, but you can choose any OSI-approved open source license that you want.
  • Ensure that your .ksy file passes basic checklist:
    • It MUST compile without errors with ksc
    • It MUST have licensing information (meta/license tag with valid SPDX open source license expression is mandatory, licensing comment is optional)
    • It SHOULD have some general information about the format and some documentation (meta/title, meta/file-extension, meta/application, doc, doc-ref tags).
  • Fork this repository
  • Choose a relevant folder and add your .ksy spec into it
  • Create a "pull request" at GitHub to pull your specs into this repo
    • Please add some general information about the formats and some instructions on how could we test it (i.e. where can we find sample files in that format, etc)

Licensing

This repository contains work of many individuals. Each .ksy is licensed separately: please see meta/license tag and comments in every .ksy file for permissions. Kaitai team claims no copyright over other people's contributions.