Skip to content

docs: align Connection authorization with OpenConnector - #133

Closed
LichKing-2234 wants to merge 12 commits into
codex/connection-m1-hldfrom
codex/connection-m1-hld-openconnector
Closed

LichKing-2234 wants to merge 12 commits into
codex/connection-m1-hldfrom
codex/connection-m1-hld-openconnector

Conversation

@LichKing-2234

@LichKing-2234 LichKing-2234 commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

Closes #4

变更摘要

  • 将 HLD 收敛为 M1 active contract:Connection 是独立的授权权威,Local Codex 走 Direct MCP,Agent Platform 等服务走通用 Delegated HTTP。
  • 明确 Connection 在请求入口校验当前 ConsumerGrant、Connection、Action、Credential 和 scope,并形成单请求快照;入口后的撤权或停用不取消、不回滚在途 Provider 请求。
  • 保留多用户/多 Consumer/多账号隔离、Credential 边界、ActionCall/Effect intent、幂等、审计和真实 Provider 验收。
  • 继续以 OpenConnector 的 Provider/Action、OAuth、Credential 刷新和请求级执行行为为参考,但不复用其 Runtime Server 作为产品入口。
  • 删除 speculative GrantSlot/ExecutionPermit/redeem、跨系统 epoch、Recovery Control/Evidence Journal、独立 Egress admission 和 terminal proof 等协议。

验证

  • pnpm install --frozen-lockfile
  • pnpm check
  • pnpm check-types
  • pnpm test
  • pnpm build
  • pnpm smoke
  • pnpm docker:build
  • 全量 Markdown lint 与 link check
  • workflow policy、actionlint、git diff --check

关联

@LichKing-2234
LichKing-2234 requested a review from a team as a code owner August 13, 2026 11:40
@github-actions

Copy link
Copy Markdown
Contributor

PR Code Suggestions ✨

No code suggestions found for the PR.

@github-actions

github-actions Bot commented Aug 13, 2026

Copy link
Copy Markdown
Contributor

PR Reviewer Guide 🔍

(Review updated until commit 5dff2d1)

Here are some key observations to aid the review process:

⚡ Recommended focus areas for review

Contract Conflict

The delegated-token contract unconditionally binds and validates an Idempotency-Key hash, but the PRD requires that header only for write Actions. As written, a delegated read Action cannot satisfy this contract unless it supplies an otherwise undocumented idempotency key. Limit this requirement to write Actions, or explicitly require idempotency keys for all delegated calls in the PRD.

Delegated Consumer 先认证注册 workload,再提交由 Connection 或受信公司身份系统签发的短期委托令牌。签发方必须同时认证当前 Principal 和 workload,并校验 workload 与已注册 Consumer/ConsumerInstance 的映射,不能根据 Consumer 自报字段签发。令牌绑定稳定 Principal subject、组织或租户、workload、consumer、consumer instance、actor、audience、action、args hash、业务幂等键 hash、期限和一次性 `jti`。Connection 校验签发方、签名、全部绑定字段和注册映射,确认令牌中的业务幂等键 hash 与请求 `Idempotency-Key` 一致,并拒绝重复 `jti` 后,仍以 Connection DB 中的 Grant 解析唯一 Connection;普通用户登录令牌不能作为委托令牌使用。重试必须使用新的 `jti` 和原业务调用的同一 `Idempotency-Key`,该键由 Consumer 生成并跨重试保持稳定,不能使用每次变化的传输 request ID 代替。

⚠️ Review coverage: The following files were not included in this review because of the token budget:

  • docs/architecture/HLD-connection-M1.md

@github-actions

Copy link
Copy Markdown
Contributor

Persistent review updated to latest commit 1ed61c8

Comment thread docs/architecture/HLD-connection-M1.md Outdated
@github-actions

Copy link
Copy Markdown
Contributor

Persistent review updated to latest commit 2782887

Comment thread docs/architecture/HLD-connection-M1.md Outdated
Comment thread docs/architecture/HLD-connection-M1.md
Comment thread docs/architecture/HLD-connection-M1.md Outdated
@github-actions

Copy link
Copy Markdown
Contributor

Persistent review updated to latest commit c5de631

Comment thread docs/architecture/HLD-connection-M1.md Outdated
…dex/connection-m1-hld-openconnector

# Conflicts:
#	docs/architecture/HLD-connection-M1.md
…dex/connection-m1-hld-openconnector

# Conflicts:
#	docs/architecture/HLD-connection-M1.md
@github-actions

Copy link
Copy Markdown
Contributor

Persistent review updated to latest commit 8326c3e

Comment thread docs/architecture/SPEC-agent-infra-M1-engineering-architecture.md Outdated
@github-actions

Copy link
Copy Markdown
Contributor

Persistent review updated to latest commit dda628c

Comment thread docs/architecture/HLD-connection-M1.md Outdated
…dex/connection-m1-hld-openconnector

# Conflicts:
#	docs/architecture/HLD-connection-M1.md
@github-actions

Copy link
Copy Markdown
Contributor

Persistent review updated to latest commit 2392771

@github-actions

Copy link
Copy Markdown
Contributor

PR Code Suggestions ✨

No code suggestions found for the PR.

…dex/connection-m1-hld-openconnector

# Conflicts:
#	docs/architecture/HLD-connection-M1.md
#	docs/architecture/SPEC-agent-infra-M1-engineering-architecture.md
…dex/connection-m1-hld-openconnector

# Conflicts:
#	docs/architecture/HLD-connection-M1.md
#	docs/prd/PRD-connection-M1.md
…dex/connection-m1-hld-openconnector

# Conflicts:
#	docs/architecture/HLD-connection-M1.md
@github-actions

Copy link
Copy Markdown
Contributor

Persistent review updated to latest commit 5dff2d1

@github-actions

Copy link
Copy Markdown
Contributor

PR Code Suggestions ✨

No code suggestions found for the PR.

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.

2 participants