Fix: Small update UI settings prompt injection#6830
Merged
dorien-koelemeijer merged 5 commits intomainfrom Jan 30, 2026
Merged
Conversation
…sing classifier models + small UI settings update
Contributor
There was a problem hiding this comment.
Pull request overview
This PR fixes a bug where the command and prompt injection ML classifiers were not working independently. The key issue was that combine_confidences was always using the confidence field from scan_conversation, even when the prompt classifier was disabled, which could incorrectly reduce command injection confidence scores.
Changes:
- Modified
combine_confidencesto acceptOption<f32>for context confidence and return tool confidence when None, preventing disabled prompt injection classifier from affecting command injection scores - Updated
is_ml_scanning_enabledto check both classifiers independently (OR logic instead of just checking prompt classifier) - Reordered UI sections to show command injection ML detection before prompt injection (prioritizes the more critical security feature)
Reviewed changes
Copilot reviewed 3 out of 3 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| crates/goose/src/security/scanner.rs | Fixed confidence combination logic to use ml_confidence (Option) instead of confidence, allowing classifiers to work independently |
| crates/goose/src/security/mod.rs | Updated is_ml_scanning_enabled to check both command and prompt classifier flags with OR logic |
| ui/desktop/src/components/settings/security/SecurityToggle.tsx | Reordered command injection detection section before prompt injection section and updated labels for clarity |
michaelneale
approved these changes
Jan 30, 2026
Collaborator
michaelneale
left a comment
There was a problem hiding this comment.
when clean build LGTM
Collaborator
Author
thank you 🙏 |
zanesq
added a commit
that referenced
this pull request
Jan 30, 2026
* 'main' of github.com:block/goose: Fix: Small update UI settings prompt injection (#6830) Remove autogenerated .gooseignore files that don't belong in repo (#6824) Fix case-insensitive matching for builtin extension names (#6825) docs: cli newline keybinding (#6823) Update version to 1.22.0 (#6821) Refactor: move persisting extension to session outside of route (#6685) acp: load configured extensions and refactor tests (#6803) docs: usage data collection (#6822) feat: platform extension migrator + code mode rename (#6611) feat: CLI flag to skip loading profile extensions (#6780)
lifeizhou-ap
added a commit
that referenced
this pull request
Feb 2, 2026
* main: fix: fixed the broken release (#6887) feat: Streamable HTTP transport for ACP + goose-acp usage (#6741) Add Laminar for Observability (#6514) Missed a couple of places that hard code J for the newline key (#6853) fix(ui): preserve working directory when creating new chat (#6789) blog: add 5 tips for building MCP Apps that work (#6855) docs: session isolation (#6846) upgrade react and electron to latest (#6845) Fix: Small update UI settings prompt injection (#6830) Remove autogenerated .gooseignore files that don't belong in repo (#6824) Fix case-insensitive matching for builtin extension names (#6825) docs: cli newline keybinding (#6823) Update version to 1.22.0 (#6821) Refactor: move persisting extension to session outside of route (#6685) acp: load configured extensions and refactor tests (#6803)
Tyler-Hardin
pushed a commit
to Tyler-Hardin/goose
that referenced
this pull request
Feb 11, 2026
Tyler-Hardin
pushed a commit
to Tyler-Hardin/goose
that referenced
this pull request
Feb 11, 2026
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
Type of Change
AI Assistance
Testing
Local testing.
Screenshots/Demos (for UX changes)
Before:

After:
