Skip to content

fix: redact legacy repository credentials and harden workspace binding - #976

Open
jxy162 wants to merge 3 commits into
Tencent:mainfrom
jxy162:fix/workspace-security-audit
Open

jxy162 wants to merge 3 commits into
Tencent:mainfrom
jxy162:fix/workspace-security-audit

Conversation

@jxy162

@jxy162 jxy162 commented Nov 16, 2026

Copy link
Copy Markdown

What changed

  • Redact legacy Git URL credentials from model-facing conversation workspace hints and run diagnostic views.
  • Keep untrusted repository names on one line before embedding them in tool descriptions.
  • Serialize the failed-workspace-open rollback of workspaceRunID with workspaceMu.
  • Accept explicit HTTPS port 443 for GitHub askpass while continuing to reject lookalike hosts and other ports.

Scope

  • Platform core / API / runner
  • Public adapter / deployment
  • Classic
  • Portable
  • Shared behavior contract
  • Installer / CLI
  • Documentation only

Compatibility

No schema, API, or runner-protocol changes. The askpass change only broadens an exact GitHub HTTPS host match from github.com to github.com plus the explicit default port 443; other hosts and ports remain rejected.

Validation

Executed locally:

  • go test ./internal/domain -count=1 -timeout=300s — passed
  • GOOS=linux GOARCH=amd64 go test -c ./internal/httpapi — passed
  • GOOS=linux GOARCH=amd64 go test -c ./internal/runtime — passed
  • go vet ./internal/httpapi ./internal/runtime — passed with Linux target
  • git diff --check — passed

Not run locally:

  • Full go test -p=2 ./... and Docker/native integration tests: this host is Windows and the project’s runtime imports Linux-only syscall APIs; Docker is not installed.
  • python3 scripts/check-public.py, bash scripts/scan-secrets.sh, and browser acceptance were not run because Python/Bash prerequisites are not available on this host.

Safety

  • I did not include credentials, internal endpoints, production data, or organization-specific infrastructure.
  • I preserved user files and unrelated changes.
  • No generated Classic host bundles are affected.
  • No third-party content or licensing changes are included.

Strip legacy URL credentials and one-line untrusted catalog text from workspace hints and run diagnostics. Add coverage for credential-bearing repository rows.
Protect the workspaceRunID rollback write with workspaceMu so failed workspace opens cannot race with concurrent workspace tools.
Allow the GitHub workspace askpass helper to answer https://github.com:443 prompts while still rejecting other ports and lookalike hosts. Extend the existing token-scope regression test.
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