Repository navigation
Bound TinyCalc formula and JSON resource use - #120
Merged
Merged
Conversation
Owner
Author
|
Delivery gate note: all 22 technical checks on head ac4ba08 passed, including both Linux and Windows build/test runs, GSDB on Ubuntu/macOS/Windows, homogeneity, secrets, PSScriptAnalyzer, maintenance, and native-proof contracts. Claude Code Review failed before producing a review: its action returned subtype success with is_error:true, zero model usage, and no buffered inline comments. This is classified as a provider/agent execution failure rather than a technical or review finding. The user explicitly authorized MergeAndSync with Admin-Bypass; bypass is limited to the review requirement and this provider failure. |
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.
Summary
Scope
Problem
The Standard Security Scan identified two denial-of-service resource paths: repeated acyclic formula references could grow evaluation work exponentially, and JSON input was fully loaded before application-level size validation.
Solution
Formula evaluation now shares successful intermediate values only within one recalculation and accounts top-level evaluations, references, cache hits, and range visits against a deterministic budget. JSON loading uses one sequential file handle, a 128 KiB precheck plus bounded max-plus-one read, direct UTF-8 deserialization with depth 16, and staged state replacement.
Compatibility is preserved for valid formulas, cycle detection, maximum application-generated worksheets, small unknown JSON properties, and atomic failure behavior. No public API, dependency, serialized schema, SBOM, or runtime product-AI change is introduced.
Security evidence
Test Plan
Automated
Manual
Behavioral Notes
Risks
Checklist