gs1-syntax-engine: initial integration - #16076
Open
terryburton wants to merge 1 commit into
Open
Conversation
|
terryburton is integrating a new project: |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The Syntax Engine is the reference implementation for processing GS1 barcode
data: Application Identifier element strings (bracketed and unbracketed), GS1
Digital Link URIs, and raw scan data from GS1 symbologies. It is part of the
GS1 Barcode Syntax Resource, the suite of tools GS1 provides for implementing
its standards.
https://www.gs1.org/standards/gs1-barcodes/gs1-barcode-syntax-resource
Why it is worth fuzzing:
intended for integration into software that processes barcode data from
untrusted sources — retail point of sale, logistics scanning, healthcare
traceability, and regulatory verification systems.
Java (JNI), Swift and JavaScript/WebAssembly, plus an npm package, an
Android library and an iOS package. A memory-safety defect in the C core is
reachable from all of them.
compare against, so defects here propagate.
What is being integrated:
Five libFuzzer targets that already exist upstream and are maintained
alongside the code they exercise:
gs1encoders-fuzzer-aisgs1encoders-fuzzer-datags1encoders-fuzzer-dlgs1encoders-fuzzer-scandatags1encoders-fuzzer-synBeyond crash-freedom, the harnesses assert semantic invariants: the
dltargetround-trips parsed data back through the parser and asserts stability, and the
syntarget asserts structural contracts on every table entryproduced from hostile input.
The build script lives upstream at
maintenance/ossfuzz/build.sh;build.shhere delegates to it so that changes to the source layout or the fuzzer set do
not need a PR against this repository. It emits per-target seed corpora (the
Syntax Dictionary itself for the
syntarget, string literals extracted fromthe test suite and parsers for the others) and
.optionsfiles cappinggenerated input at the largest length the harnesses accept.
The library has no third-party runtime dependencies, so MemorySanitizer is
viable; it is enabled as experimental for the initial integration.
I am a maintainer of the project.