Credential placeholder model breaks SDKs that validate token format before making network calls

未关闭
#894 4 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看

还没有人认领这个 Issue。

评估

难度
5/5
预计耗时
一周以上
新手友好度
38/100
Issue 类型
功能
描述清晰度
需要澄清
活跃度
活跃
技术栈
javascript

调研方向

首先追踪 issues #112、#538 和 #689 中引用的占位凭据模型及 L7 凭据注入工作,然后查看 docs/sandboxes/manage-providers.mdx。在 @slack/web-api 和 @slack/socket-mode 中复现网络前验证行为;完成的实现应解决这些初始化失败,同时保留文档中规定的不变量:sandbox 进程永远不会看到真实的凭据值。

由索引模型根据 Issue 内容生成。

描述

The placeholder credential model (openshell:resolve:env:*) assumes credentials flow through HTTP requests where the L7 proxy can intercept and substitute real values. This works well for header-based auth, URL path tokens (Telegram), query parameters, and Basic auth.

However, some SDKs validate credential format in-process before making any network call. When the process reads an env var and sees openshell:resolve:env:SLACK_BOT_TOKEN instead of a value matching the expected format (e.g., xoxb-*), the SDK rejects the credential immediately. No HTTP request is made, so the proxy never gets an opportunity to resolve the placeholder.

Concrete case

Slack's @slack/web-api validates the xoxb- prefix on bot tokens and @slack/socket-mode validates the xapp- prefix on app tokens. Both checks happen at initialization, before any network I/O. The placeholder fails validation, and the SDK either throws invalid_auth or silently skips channel initialization.

Scope

This affects any SDK or library that performs client-side credential format validation before its first network call. Slack is the first confirmed case, but the pattern is common — OAuth libraries checking token structure, AWS SDKs validating key format, etc.

Downstream impact

NemoClaw #1569 and #2085 are blocked on this. Slack is one of three messaging channels NemoClaw supports, and it is currently non-functional inside OpenShell sandboxes.

References

  • The placeholder model was introduced in #112
  • L7 credential injection was generalized in #538 and #689
  • OpenShell provider docs state: "The agent process inside the sandbox never sees real credential values" — this invariant is the root of the conflict
主要语言
Rust
星标
8.7k
派生
1.3k
平均合并
2 天 7 小时
30 天内合并 PR
243

贡献指南

打开贡献指南

从这里开始

  1. 先读完整个 Issue,再读项目的贡献指南。
  2. 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
  3. Fork 仓库,在一个分支上完成修改。
  4. 提交 Pull Request,并在描述里引用这个 Issue 编号。

NVIDIA/OpenShell 的其他 Issue

查看 NVIDIA/OpenShell 的全部 Issue

相似的 Issue

更多 Rust Issue

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。