Downloads .ksy
files and their dependencies straight from the official kaitai-struct format gallery.
This tool will:
This makes it easy to include, modify, and share official and community created kaitai-struct specifications in individual projects.
$ git clone https://github.com/tins2831/ksy-dl.git
$ cd ksy-dl
$ python3 -m pip install --user -r requirements.txt
usage: python3 ksy-dl.py QUERY OUTPUT_DIR
...
Examples:
$ python3 ksy-dl.py "network/pcap" .
$ python3 ksy-dl.py "pcap" ../kaitai # will create non-existing directories too
$ python3 ksy-dl.py "/network/pcap" network/
$ python3 ksy-dl.py "pcap.ksy" .
$ python3 ksy-dl.py "google_protobuf" .
First, clone the kaitai format gallery from github:
$ git clone https://github.com/kaitai-io/kaitai_struct_formats.git
Then adjust and append this to your crontab:
# Update ksy-dl format db.
# Runs every day at midnight.
00 00 * * * (KAITAI_FMT_REPO=<path to repo> <path to ksy-dl repo>/tools/db-update.sh)