fabro/lib/components/fabro-agent/src
Bryan Helmkamp 370a6c96d5
Give the checkout its GitHub credentials through the driver's store
The GitHub App token reached the agent's git commands through the origin
URL: after the clone fabro ran `git remote set-url origin` with the
token embedded, then tracked which generation the URL carried, held an
embed lease across every push so a refresh could not rewrite the URL
mid-operation, re-embedded on the first auth-shaped push failure in
case the agent had rewritten origin, and redacted the URL out of every
log line and output tail. The token showed in `git remote -v` and
`.git/config`.

The driver now installs ambient credentials for a checkout: one
credential-store line beside the checkout and a `credential.helper`
entry pointing at it, with the remote URL untouched. Fabro's part is
`credentials.rs`: the token source, one mint for the clone, one resolve
per push operation, and the facet call. The clone carries the token per
call and installs it afterwards; the ACP refresh tick rewrites the store
instead of the URL; fabro's own pushes pin one resolved token for the
whole operation and pass it per call, so nothing is ever re-embedded and
a retry after replication lag presents the same token by construction.

Gone with the URL: `push_credentials.rs`, `redact.rs`, the lease and
drift repair in `git_push`, `RefreshOutcome`, and the `credential_action`
and `refresh_error` fields on push attempt events. Stored events that
carry those keys still read. A failed store install after the clone now
fails setup, where a failed `set-url` used to be logged and repaired by
the first push. The one remaining caller of the URL redactor, the
server's repository probe, uses `DisplaySafeUrl::redact_in`.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-11 10:02:01 -06:00
..
profiles Read a mock sandbox's recordings from the driver double 2026-09-10 16:55:05 -06:00
agent_profile.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
apply_patch.lark refactor: organize crates into three layers 2026-07-23 17:59:34 -04:00
apply_patch.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
cli.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
compaction.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
config.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
context_window.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
error.rs Name built-in providers through lithos catalog::builtin 2026-09-10 09:48:37 -06:00
event.rs Speak the driver's exec vocabulary instead of mirroring it 2026-09-10 16:11:45 -06:00
file_tracker.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
history.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
lib.rs Give the checkout its GitHub credentials through the driver's store 2026-09-11 10:02:01 -06:00
local_sandbox.rs Retire the fabro Sandbox trait for one concrete RunSandbox 2026-09-10 00:14:42 -06:00
loop_detection.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
mcp_integration.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
memory.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
native_tool.rs refactor(agent): give Claude 5 subagent tools fabro canonical names 2026-07-26 07:57:42 -04:00
question_tools.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
sandbox.rs Give the checkout its GitHub credentials through the driver's store 2026-09-11 10:02:01 -06:00
session.rs Speak the driver's exec vocabulary instead of mirroring it 2026-09-10 16:11:45 -06:00
skills.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
subagent.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
task_reminder.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
test_support.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
todo_runtime.rs Retire the fabro Sandbox trait for one concrete RunSandbox 2026-09-10 00:14:42 -06:00
todo_tools.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00
tool_execution.rs Speak the driver's exec vocabulary instead of mirroring it 2026-09-10 16:11:45 -06:00
tool_permissions.rs refactor(agent): model built-in tools as an enum with per-profile vocabularies 2026-07-24 20:04:11 -04:00
tool_registry.rs Speak the driver's exec vocabulary instead of mirroring it 2026-09-10 16:11:45 -06:00
tools.rs Speak the driver's exec vocabulary instead of mirroring it 2026-09-10 16:11:45 -06:00
truncation.rs Speak the driver's exec vocabulary instead of mirroring it 2026-09-10 16:11:45 -06:00
types.rs Import lithos-llm types directly instead of through fabro-types 2026-09-10 10:03:08 -06:00
web_search.rs Merge origin/main into the sandbox-driver adoption 2026-09-10 13:37:11 -06:00