Skip to content

Commit

Permalink
add specification for bzip3
Browse files Browse the repository at this point in the history
  • Loading branch information
armijnhemel committed May 15, 2023
1 parent 8be72c8 commit 42772db
Showing 1 changed file with 35 additions and 0 deletions.
35 changes: 35 additions & 0 deletions archive/bzip3.ksy
Original file line number Diff line number Diff line change
@@ -0,0 +1,35 @@
meta:
id: bzip3
title: Bzip3 header
file-extension: bz3
license: LGPL-3.0
encoding: UTF-8
endian: le
doc-ref: https://github.com/kspalaiologos/bzip3
seq:
- id: header
type: header
- id: blocks
type: compressed_data_block
repeat: until
repeat-until: _io.eof or _.is_last
types:
header:
seq:
- id: signature
contents: 'BZ3v1'
- id: block_size
type: u4
compressed_data_block:
seq:
- id: len_compressed
type: u4
- id: len_uncompressed
type: u4
valid:
max: _root.header.block_size
- id: data
size: len_compressed
instances:
is_last:
value: len_uncompressed < _root.header.block_size

0 comments on commit 42772db

Please sign in to comment.