Skip to content

JS/TS ANTLR spike - #564

Draft
Siddhartha20242 wants to merge 1 commit into
cbomkit:mainfrom
Siddhartha20242:feat/js-ts-antlr-spike
Draft

Siddhartha20242 wants to merge 1 commit into
cbomkit:mainfrom
Siddhartha20242:feat/js-ts-antlr-spike

Conversation

@Siddhartha20242

@Siddhartha20242 Siddhartha20242 commented Nov 6, 2026 •

Copy link
Copy Markdown

Follow-up to #539, as requested in #521. Feasibility spike only.

It parses a typed TypeScript fixture with an ANTLR grammar, converts the tree into the engine's blocks, scopes and calls, and runs one rule (crypto.createHash with dependent update and digest) through the shared DetectionEngine and DetectionStore to a CBOM digest node. The test covers the sequential form, the inline chain, and a case where an unrelated logger.update must not attach.

About 1,300 of the lines are the vendored antlr/grammars-v4 TypeScript grammar (MIT). Nothing is registered in the plugin yet and there is no sensor.

The evaluation, known gaps and open questions are in my comment on #521: #521 (comment)

Signed-off-by: Siddhartha bhat <bhattaraiankit2212@gmail.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant