Skip to content

[WRONG BRANCH] fix(devin): fail closed for legacy custom ACP rows - #530

Draft
luvs01 wants to merge 1 commit into
mainfrom
codex/propose-fix-for-acp-migration-vulnerability
Draft

luvs01 wants to merge 1 commit into
mainfrom
codex/propose-fix-for-acp-migration-vulnerability

Conversation

@luvs01

@luvs01 luvs01 commented Sep 14, 2026

Copy link
Copy Markdown
Owner

Motivation

  • The startup migration silently rewrote custom provider rows that referenced the retired devin-cli ACP adapter into the cloud devin adapter, which could cause unrelated caller bearers or stored keys to be treated as Devin credentials and be forwarded to Cognition.
  • To avoid credential disclosure from legacy custom rows, custom-named rows must not be auto-converted; they should fail closed and require explicit operator action to enable cloud Devin usage.
  • Update user-facing docs and the adapter architecture contract so operators are informed and can safely migrate custom rows.

Description

  • Change projectDevinCliAuthMode in src/providers/devin-cli-authmode-migration.ts to leave custom-named rows that still reference devin-cli unchanged and emit an actionable startup warning instead of rewriting them to devin (fail-closed behavior).
  • Preserve the existing canonical devin-cli -> devin migration for the registry-id row; only custom-named rows are disabled pending operator configuration.
  • Add/adjust focused regression tests in tests/providers/devin-cli-authmode-migration.test.ts to assert that a custom devin-acp row is left disabled and that the registry-id row still migrates.
  • Update the adapter registry contract and public docs (including translated pages) to document the new fail-closed migration behavior and operator guidance.

Testing

  • Ran the focused regression tests with bun test tests/providers/devin-cli-authmode-migration.test.ts, which passed.
  • Ran static checks bun run typecheck, bun run privacy:scan, and bun run structure:check, all of which passed.
  • Built the docs with cd docs-site && bun install --frozen-lockfile && bun run build, which succeeded.
  • Ran git diff --check to ensure no whitespace/patch issues, which passed.
  • Ran the full test suite (bun run test) for context; the focused change passes, while the full repo run exposed unrelated environment/container and lab-test failures documented elsewhere and not caused by this change.

Codex Task

@coderabbitai

coderabbitai Bot commented Sep 14, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Advanced

Run ID: 4adc28f1-8794-4ef5-9522-c024dea5b2cd


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@chatgpt-codex-connector chatgpt-codex-connector Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

💡 Codex Review

Here are some automated review suggestions for this pull request.

Reviewed commit: c70fe8d74f

ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review".

If Codex has suggestions, it will comment; otherwise it will react with 👍.

Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".

`left custom provider "${name}" disabled because adapter ${RETIRED_ACP_ADAPTER} was removed: `
+ "choose adapter devin and configure Devin authentication explicitly before using this provider.",
);
continue;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

P1 Badge Block per-model overrides on retired custom rows

When a legacy custom row also has a valid modelAdapters[model] value, this continue preserves that override; resolveWireProtocolOverride() in src/server/adapter-resolve.ts:35-45 then replaces the unknown devin-cli adapter with openai-chat or openai-responses before adapter construction. The request therefore does not fail closed and can send a configured API key to the legacy row's saved baseUrl, even though the removed ACP adapter ignored that credential. Remove/disable these overrides during migration or reject the retired adapter before model-level wire resolution.

AGENTS.md reference: AGENTS.md:L366-L372

Useful? React with 👍 / 👎.

@chatgpt-codex-connector

Copy link
Copy Markdown

Codex Review Summary

This comment shows the latest Codex review activity on this pull request.

Review Status Commit Review trigger
📝 Code Review Completed 2026-09-14T01:17:27.629929Z c70fe8d PR opened
ℹ️ About Codex in GitHub

Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you

  • Open a pull request for review
  • Mark a draft as ready
  • Comment "@codex review" or "@codex security review".

Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings.

@github-actions

Copy link
Copy Markdown

Deterministic PR hygiene checks passed.

@github-actions github-actions Bot added the bug Something isn't working label Sep 14, 2026
@github-actions github-actions Bot changed the title fix(devin): fail closed for legacy custom ACP rows [WRONG BRANCH] fix(devin): fail closed for legacy custom ACP rows Sep 14, 2026
@github-actions

github-actions Bot commented Sep 14, 2026

Copy link
Copy Markdown

⏳ DRAFT

  • wrong target branch (main); retarget to dev.

What to do

  • Retarget this PR to dev — all contributions go to dev.

Its title has been prefixed with [WRONG BRANCH].
This pull request was already a draft. Its draft status will be preserved after every issue above is resolved.

@github-actions
github-actions Bot marked this pull request as draft September 14, 2026 01:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

aardvark bug Something isn't working codex

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant