aKode fase 2b-2: rimosso login ChatGPT e tutti i sottosistemi solo-ChatGPT
- Login: resta solo chiave API (+ header, Bedrock). Rimossi OAuth/browser, device code, refresh/revoke su auth.openai.com, PAT, agent/workload identity, runtime agent instance, backend-client e openapi-models, workspace routing. - Rimossi: generazione immagini (ext + skill imagegen), history notes, plugin remoti (catalogo, sync, share), cyber access program, daybreak, cloud config e requirements (config_server ora fail-closed), attestation, frozen cloud skills, EMA MCP auth, Codex Apps/connettori, ricerca ospitata, header/zstd/ routing/cookie del backend Codex, fallback OPENAI_API_KEY del realtime. - Messaggi d'errore senza link a chatgpt.com. - Chiavi di config legacy accettate e ignorate; feature rimosse = Stage::Removed. - Test: cancellati solo quelli del codice rimosso; test di sicurezza (sandbox estensioni, permessi, redazione, auth storage, requirements) adattati. Restano solo fallimenti d'ambiente (code-mode-host/V8, ~/.agents). - Istruzioni di sistema invariate. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
@@ -81,7 +81,6 @@ pub enum RemoteEnvironmentTransport {
|
||||
enum RegistryAuthMode {
|
||||
Legacy,
|
||||
ExecutorCredential,
|
||||
ChatgptToken,
|
||||
}
|
||||
|
||||
#[derive(Clone)]
|
||||
@@ -310,7 +309,7 @@ impl EnvironmentRegistryClient {
|
||||
.map_err(auth::registry_auth_error)?;
|
||||
let scoped = self.auth_mode == RegistryAuthMode::ExecutorCredential;
|
||||
let credential = if self.auth_mode != RegistryAuthMode::Legacy {
|
||||
// Scoped credentials must be the only header. ChatGPT also carries its account ID.
|
||||
// Scoped credentials must be the only header.
|
||||
let token = (!scoped || headers.len() == 1)
|
||||
.then(|| headers.get(AUTHORIZATION))
|
||||
.flatten()
|
||||
@@ -721,12 +720,6 @@ impl RemoteEnvironmentConfig {
|
||||
Ok(self)
|
||||
}
|
||||
|
||||
/// Omit the bearer from registry diagnostics while retaining the account header.
|
||||
pub fn with_registry_bearer_redaction(mut self) -> Self {
|
||||
self.auth_mode = RegistryAuthMode::ChatgptToken;
|
||||
self
|
||||
}
|
||||
|
||||
pub fn with_telemetry(mut self, telemetry: ExecServerTelemetry) -> Self {
|
||||
self.telemetry = telemetry;
|
||||
self
|
||||
@@ -1474,11 +1467,6 @@ mod tests {
|
||||
assert_registry_diagnostics_omit_bearer(RegistryAuthMode::ExecutorCredential).await;
|
||||
}
|
||||
|
||||
#[tokio::test]
|
||||
async fn chatgpt_token_is_never_returned_in_registry_diagnostics() {
|
||||
assert_registry_diagnostics_omit_bearer(RegistryAuthMode::ChatgptToken).await;
|
||||
}
|
||||
|
||||
async fn assert_registry_diagnostics_omit_bearer(mode: RegistryAuthMode) {
|
||||
const TOKEN: &str = "synthetic-scoped-registry-secret";
|
||||
struct ExecutorAuth;
|
||||
|
||||
Reference in New Issue
Block a user