tool_operate: reset the URL --url-query between --next#20802
tool_operate: reset the URL --url-query between --next#20802
Conversation
|
@aisle-analyzer augment review |
🔒 Aisle Security Analysis✅ We scanned this PR and did not find any security vulnerabilities. Aisle supplements but does not replace security review. Analyzed PR: #20802 at commit Last updated on: 2026-03-03T18:11:33Z |
🤖 Augment PR SummarySummary: This PR fixes Changes:
Technical Notes: The new test validates that a sensitive query token is not inadvertently reused on the subsequent URL after 🤖 Was this summary useful? React with 👍 or 👎 |
|
Analysis of PR #20802 at 47c8a0f9: Test 48 failed, which has NOT been flaky recently, so there could be a real issue in this PR. Note that this test has failed in 280 different CI jobs (the link just goes to one of them). Test 199 failed, which has NOT been flaky recently, so there could be a real issue in this PR. Note that this test has failed in 250 different CI jobs (the link just goes to one of them). Test 2500 failed, but it has been 60.3% flaky lately, so it's probably NOT a fault of the PR. Note that this test has failed in 2 different CI jobs (the link just goes to one of them). Note that this CI job has had a number of other flaky tests recently (3, to be exact) so it may be that this failure is rather a systemic issue with this job and not with this specific PR. Generated by Testclutch |
Pointed out by Codex Security Verify in test 1624
To make it reset properly after --next, but not before
There was a problem hiding this comment.
Pull request overview
This PR fixes a state-leak bug in tool_operate where --url-query could incorrectly carry over across --next operations (as flagged by Codex Security), and adds a regression test to ensure query parameters are properly reset between operations.
Changes:
- Move
httpgetfieldsfrom globalStateto per-OperationConfigso it does not persist across--next. - Update URL query appending logic to use
config->httpgetfieldsinstead ofstate->httpgetfields. - Add test
1624and register it in the test suite to verify correct behavior.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
src/tool_operate.c |
Switches query-append source from global state to per-operation config, preventing cross---next leakage. |
src/tool_cfgable.h |
Moves httpgetfields storage to OperationConfig (removes it from State). |
tests/data/test1624 |
New regression test verifying --url-query applies only to the first operation before --next. |
tests/data/Makefile.am |
Adds test1624 to the test list so it runs in CI. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
There was a problem hiding this comment.
Pull request overview
Copilot reviewed 4 out of 4 changed files in this pull request and generated no new comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
You can also share your feedback on Copilot code review. Take the survey.
Pointed out by Codex Security
Verify in test 1624