-
Notifications
You must be signed in to change notification settings - Fork 80
KDZ File Format Detail
Elliott Mitchell edited this page Jul 30, 2016
·
1 revision
#KDZ File Format Detail
_dz_format_dict = OrderedDict([
('name', ('256s', True)),
('length', ('Q', False)),
('offset', ('Q', False)),
])
The KDZ format is quite simple. There is an 8-byte magic number, followed by some number of these headers, then appropriate payload. The next to last header is preceded by a "\x03" (control-C, interesting choice), but the null characters can also be used for detecting end of headers. The "\x03" is NOT part of any header and must be removed! This means the last header will have odd alignment.
"offset" is an 8-byte number indicating how far from the start of KDZ file data starts. "length" is an 8-byte length of the file. "name" is a 256-byte string for an output filename, padded with zero characters.