2295 bug new sysmon profile cant paste srql query #2668
No reviewers
Labels
No labels
1week
2weeks
Failed compliance check
IP cameras
NATS
Possible security concern
Review effort 1/5
Review effort 2/5
Review effort 3/5
Review effort 4/5
Review effort 5/5
UI
aardvark
accessibility
amd64
api
arm64
auth
back-end
bgp
blog
bug
build
checkers
ci-cd
cleanup
cnpg
codex
core
dependencies
device-management
documentation
duplicate
dusk
ebpf
enhancement
eta 1d
eta 1hr
eta 3d
eta 3hr
feature
fieldsurvey
github_actions
go
good first issue
help wanted
invalid
javascript
k8s
log-collector
mapper
mtr
needs-triage
netflow
network-sweep
observability
oracle
otel
plug-in
proton
python
question
reddit
redhat
research
rperf
rperf-checker
rust
sdk
security
serviceradar-agent
serviceradar-agent-gateway
serviceradar-web
serviceradar-web-ng
siem
snmp
sysmon
topology
ubiquiti
wasm
wontfix
zen-engine
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
carverauto/serviceradar!2668
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "refs/pull/2668/head"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from GitHub pull request.
Original GitHub pull request: #2297
Original author: @mfreeman451
Original URL: https://github.com/carverauto/serviceradar/pull/2297
Original created: 2026-01-14T16:20:35Z
Original updated: 2026-01-14T17:31:46Z
Original head: carverauto/serviceradar:2295-bug-new-sysmon-profile----cant-paste-srql-query
Original base: staging
Original merged: 2026-01-14T17:31:44Z by @mfreeman451
User description
IMPORTANT: Please sign the Developer Certificate of Origin
Thank you for your contribution to ServiceRadar. Please note, when contributing, the developer must include
a DCO sign-off statement indicating the DCO acceptance in one commit message. Here
is an example DCO Signed-off-by line in a commit message:
Describe your changes
Issue ticket number and link
Code checklist before requesting a review
PR Type
Bug fix, Tests
Description
Parse SRQL query input and sync builder state when valid
Add form ID and conditional builder updates on validation
Create comprehensive tests for SRQL paste and sync behavior
Document change with specs and implementation tasks
Diagram Walkthrough
File Walkthrough
index.ex
Sync builder state on target query validationweb-ng/lib/serviceradar_web_ng_web/live/settings/sysmon_profiles_live/index.ex
validate_profileevent handler
builder_syncstate tracking to indicate if builder matches parsedquery
sysmon_profiles_live_test.exs
Add SRQL paste and builder sync testsweb-ng/test/serviceradar_web_ng_web/live/settings/sysmon_profiles_live_test.exs
proposal.md
Change proposal for SRQL builder syncopenspec/changes/update-sysmon-profile-srql-input/proposal.md
spec.md
Update spec with builder sync scenariosopenspec/changes/update-sysmon-profile-srql-input/specs/build-web-ui/spec.md
tasks.md
Implementation and validation task trackingopenspec/changes/update-sysmon-profile-srql-input/tasks.md
Imported GitHub PR comment.
Original author: @qodo-code-review[bot]
Original URL: https://github.com/carverauto/serviceradar/pull/2297#issuecomment-3750374934
Original created: 2026-01-14T16:21:18Z
PR Compliance Guide 🔍
Below is a summary of compliance checks for this PR:
No security concerns identified
No security vulnerabilities detected by AI analysis. Human verification advised for critical code.🎫 #2295
New Sysmon ProfileTarget Query input, thequery builder should update automatically to match the input.
legal/valid SRQL query).
updates the visible builder UI state as expected (including any "applied" indicators) and
does not introduce UX regressions.
Codebase context is not defined
Follow the guide to enable codebase context checks.
Generic: Comprehensive Audit Trails
Objective: To create a detailed and reliable record of critical system actions for security analysis
and compliance.
Status: Passed
Generic: Meaningful Naming and Self-Documenting Code
Objective: Ensure all identifiers clearly express their purpose and intent, making code
self-documenting
Status: Passed
Generic: Secure Logging Practices
Objective: To ensure logs are useful for debugging and auditing without exposing sensitive
information like PII, PHI, or cardholder data.
Status: Passed
Generic: Robust Error Handling and Edge Case Management
Objective: Ensure comprehensive error handling that provides meaningful context and graceful
degradation
Status:
Unhandled parse failures: The new
parse_target_query_to_builder(target_query)call has no visible guarding or errorhandling in this diff, so failures on
nil/invalid SRQL could crash the LiveView orsilently desync without actionable feedback.
Referred Code
Generic: Secure Error Handling
Objective: To prevent the leakage of sensitive system information through error messages while
providing sufficient detail for internal debugging.
Status:
Parser error exposure: Because SRQL parsing is newly introduced via
parse_target_query_to_builder/1and no errorpathway is shown here, it is unclear whether parsing errors could surface internal details
to the UI instead of being handled generically.
Referred Code
Generic: Security-First Input Validation and Data Handling
Objective: Ensure all data inputs are validated, sanitized, and handled securely to prevent
vulnerabilities
Status:
SRQL input validation: The PR adds parsing of user-provided
target_queryinto builder state, but the diff doesnot show input validation/sanitization or safeguards ensuring SRQL cannot trigger unsafe
downstream behavior.
Referred Code
Compliance status legend
🟢 - Fully Compliant🟡 - Partial Compliant
🔴 - Not Compliant
⚪ - Requires Further Human Verification
🏷️ - Compliance label
Imported GitHub PR comment.
Original author: @qodo-code-review[bot]
Original URL: https://github.com/carverauto/serviceradar/pull/2297#issuecomment-3750379796
Original created: 2026-01-14T16:22:24Z
PR Code Suggestions ✨
Explore these optional code suggestions:
Gracefully handle parse errors
Add a
try/rescueblock around theparse_target_query_to_builder/1call toprevent crashes from malformed SRQL input and gracefully handle parsing
failures.
web-ng/lib/serviceradar_web_ng_web/live/settings/sysmon_profiles_live/index.ex [116]
Suggestion importance[1-10]: 8
__
Why: This is a critical improvement for robustness, as it prevents the LiveView process from crashing due to unexpected input in
target_query, which is a common source of errors in user-facing forms.Clear stale builder on unsynced
When
builder_syncis false, reset the:builderstate to an empty map to clearstale data from the UI and prevent user confusion.
web-ng/lib/serviceradar_web_ng_web/live/settings/sysmon_profiles_live/index.ex [125-130]
Suggestion importance[1-10]: 7
__
Why: This suggestion correctly identifies that stale data could be left in the builder UI when an un-parseable query is entered, and proposes a good solution to clear it, improving UI consistency.