Skip to main content
https://img.shields.io/github/last-commit/jfjlaros/bin-parser.svg https://travis-ci.org/jfjlaros/bin-parser.svg?branch=master https://readthedocs.org/projects/bin-parser/badge/?version=latest https://img.shields.io/github/release-date/jfjlaros/bin-parser.svg https://img.shields.io/github/release/jfjlaros/bin-parser.svg https://img.shields.io/pypi/v/bin-parser.svg https://img.shields.io/npm/v/bin-parser.svg https://img.shields.io/github/languages/code-size/jfjlaros/bin-parser.svg https://img.shields.io/github/languages/count/jfjlaros/bin-parser.svg https://img.shields.io/github/languages/top/jfjlaros/bin-parser.svg https://img.shields.io/github/license/jfjlaros/bin-parser.svg

This library provides general binary file parsing by interpreting documentation of a file structure and data types. By default, it supports basic data types like big-endian and little-endian integers, floats and doubles, variable length (delimited) strings, maps and bit fields (flags) and it can iterate over sub structures. Other data types are easily added.

The file structure and the types are stored in nested dictionaries. The structure is separated from the types, this way multiple file formats using the same types (within one project for example) can be easily supported without much duplication.

The design of the library is such that all operations can be reversed. This means that fully functional binary editing is possible using this implementation; first use the reader to convert a binary file to a serialised dictionary representation, this representation is easily edited using a text editor, and then use the writer to convert back to binary.

This idea is implemented in two languages; Python and JavaScript. All main development is done in Python. We chose YAML as our preferred serialised dictionary format, but other serialisation formats (JSON for example) can be used too.

Please see ReadTheDocs for the latest documentation.

Metadata

Release files for bin-parser 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for bin-parser 1.0.1
File Size Uploaded
bin-parser-1.0.1.tar.gz 11.2 kB Details

Release files / bin-parser-1.0.1.tar.gz

Download URL bin-parser-1.0.1.tar.gz
Size 11.2 kB
Tags Source
SHA-256 checksum
How to use checksums
596b236459e58c7e4835a98d6c3ad59293c96ea2bbf57e96f883d316d3feed26
BLAKE2b-256 checksum
How to use checksums
38d13362023f97a4da7d4de9628415090a8a21b7c1c6d52cefd2ef829b0a4756
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

1.0.1 This release

1 release file

1.0.0

1 release file

0.0.20

1 release file

0.0.16

1 release file

0.0.15

1 release file

0.0.14

1 release file

0.0.13

1 release file

0.0.12

1 release file

0.0.10

1 release file

0.0.9

1 release file

0.0.8

1 release file

0.0.5

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page