oasis-open / cti-pattern-validator

OASIS TC Open Repository: Validate patterns used to express cyber observable content in STIX Indicators
https://stix2-patterns.readthedocs.io/
BSD 3-Clause "New" or "Revised" License
26 stars 23 forks source link

Feat rebuild ANTLR bindings #96

Open vEpiphyte opened 11 months ago

vEpiphyte commented 11 months ago

Binding regeneration:

Using openjdk-19-jre-headless

java -jar ./antlr-4.13.1-complete.jar -Dlanguage=Python3 STIXPattern.g4 -visitor -o ./stix2patterns/v21/grammars
java -jar ./antlr-4.13.1-complete.jar -Dlanguage=Python3 STIXPattern.g4 -visitor -o ./stix2patterns/v20/grammars

Files taken from https://github.com/oasis-open/cti-stix2-json-schemas/blob/stix2.0/pattern_grammar/STIXPattern.g4 https://github.com/oasis-open/cti-stix2-json-schemas/blob/stix2.1/pattern_grammar/STIXPattern.g4

$ sha256sum STIXPattern.g4*
a5fab115c8973680f13274113ba1d9c1fe5708b00805a06644c7ce717c42ff19  STIXPattern.g4.20
b6429e8fed902133d2409d86c906b0c9dbaa4a54536023997ee73b460876b228  STIXPattern.g4.21

Bindings were committed as is.

The test suite for https://github.com/oasis-open/cti-pattern-matcher and https://github.com/oasis-open/cti-stix-validator pass with these updated bindings.

The tox suite seems to fail on a packaing step. That is unrelated to this PR.

Closes #84

vEpiphyte commented 10 months ago

@clenk @chisholm Can this be reviewed?