Skip to content

feat: flag insecure websocket transport in AW-005#4

Merged
brandonwise merged 2 commits into
mainfrom
auto/pm-presence-20260420
Apr 21, 2026
Merged

feat: flag insecure websocket transport in AW-005#4
brandonwise merged 2 commits into
mainfrom
auto/pm-presence-20260420

Conversation

@brandonwise
Copy link
Copy Markdown
Owner

@brandonwise brandonwise commented Apr 21, 2026

Summary

This ships a user-visible hardening upgrade to AW-005 by expanding cleartext transport detection beyond http:// to also catch ws:// endpoints.

Why now

Recent telemetry converged on MCP transport security and deterministic guardrails:

What changed

  • AW-005 now flags insecure ws:// endpoints in both url and args fields (alongside existing http:// checks).
  • Added localhost exceptions for IPv6 loopback ([::1]) to avoid noisy local false positives.
  • Updated remediation text to recommend TLS endpoints (https:// / wss://).
  • Added new fixture testdata/ws-no-auth.json and integration coverage for websocket detection.
  • Updated README rule docs and findings snapshot wording for AW-005.
  • Updated two report sort calls to sort_by_key(Reverse(...)) for Rust 1.95 clippy compatibility (no behavior change).

Deep validation

1) Full/repo-level suite

  • cargo test βœ… pass (212 unit + 37 integration tests passed)

2) Targeted tests (changed modules)

  • cargo test rules::transport::tests βœ… pass (8 passed)
  • cargo test test_detects_insecure_websocket_transport βœ… pass (1 passed)

3) Lint/type/build checks

  • cargo clippy --all-targets -- -D warnings βœ… pass
  • cargo build --release βœ… pass

4) Smoke/integration check for changed behavior

  • ./target/release/agentwise scan testdata/ws-no-auth.json --format json | jq -r '.findings[] | select(.rule_id=="AW-005") | .message' βœ… output:
    • Server 'realtime-api' uses unencrypted WS transport: ws://realtime.example.com/mcp
  • ./target/release/agentwise scan testdata/ws-no-auth.json --fail-on high βœ… expected failing gate behavior (EXIT_CODE=1)

Docs tone check

  • node /Users/bwise/.openclaw/workspace/projects/humanizer/src/cli.js score README.md --ignore-code β†’ 🟑 43/100

@brandonwise brandonwise merged commit 24e2079 into main Apr 21, 2026
8 checks passed
@brandonwise brandonwise deleted the auto/pm-presence-20260420 branch April 21, 2026 01:18
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.

1 participant