Skip to content

fix(db): bound asset DSL length and parenthesis depth - #353

Merged
BaaRai merged 1 commit into
BaaRai:mainfrom
Coff0xc:fix/dsl-nesting-limit
Nov 19, 2026
Merged

BaaRai merged 1 commit into
BaaRai:mainfrom
Coff0xc:fix/dsl-nesting-limit

Conversation

@Coff0xc

@Coff0xc Coff0xc commented Nov 19, 2026

Copy link
Copy Markdown
Contributor

ParseDSL recursed on every ( with no depth or size cap, so a query of nested parentheses could grow the goroutine stack until the process died.

Cap input at 4 KiB and nesting at 32.

Tested: go test ./db -run TestParseDSL pass.

Copilot AI balanced review requested due to automatic review settings November 19, 2026 02:18

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

ParseDSL recursed on every '(' with no depth or size cap, so a
query of nested parentheses could grow the goroutine stack until
the process died. Cap input at 4 KiB and nesting at 32.
@BaaRai
BaaRai force-pushed the fix/dsl-nesting-limit branch from ff71272 to 16b04cf Compare November 19, 2026 13:25
@BaaRai
BaaRai merged commit 8f92caa into BaaRai:main Nov 19, 2026
5 checks passed
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.

3 participants