`void platform install --app-access public` fails when Cloudflare reports Access is disabled

Offen Anfängerfreundlich
#835 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen

Maintainer antworten meist innerhalb von 1 Tag

Dieses Issue hat noch niemand übernommen.

Bewertung

Schwierigkeit
2/5
Geschätzter Aufwand
1-3 Stunden
Anfängerfreundlichkeit
72/100
Issue-Typ
Bug
Klarheit
Klar beschrieben
Aktivitätsstatus
Aktiv
Tech-Stack
typescript
Bereich
authentication, cli

Rechercherichtung

Beginne in packages/void/src/cli/platform-app-access.ts bei den Zeilen 175-241, wo der Installer Default-Deny über GET /accounts/{account_id}/access/organizations prüft und 403s in den App-Access-Token-Flow schickt. Verfolge, wie --app-access public und --no-access-protection diese Prüfung erreichen, und behandle dann Cloudflares Antwort access.api.error.not_enabled als öffentliches Setup, während andere 403s den bestehenden Pfad beibehalten. Aktualisiere die CLI-Tests, die Access disabled abdecken. Fertig, wenn die Reproduktion ohne Token-Prompt abschließt und andere Auth-Fehler weiterhin einen Prompt auslösen.

Vom Indexierungsmodell aus dem Issue-Text verfasst.

Beschreibung

Affected version
Void CLI 1.9.1

Steps to reproduce
  1. Start a fresh install in a Cloudflare account where Access is disabled. Set CLOUDFLARE_API_TOKEN to an installer token with the usual install permissions and account-level Access: Organizations, Identity Providers, and Groups Read. Leave VOID_PLATFORM_APP_ACCESS_TOKEN and appAccess.tokenEnv unset.

  2. Use a platform login method that does not rely on Cloudflare Access. Run the following in a non-interactive shell with the rest of your installation settings. --no-access-protection disables Access protection for the platform itself, so the reproduction reaches the separate check for deployed apps.

    void platform install --app-access public --no-access-protection --yes
    
Actual behavior

The install stops while checking whether the account enforces Access Default-Deny.

platform: App access requires VOID_PLATFORM_APP_ACCESS_TOKEN or appAccess.tokenEnv in --auth-config, scoped to the hosting account.

A separate request to GET /accounts/{account_id}/access/organizations with the account-level read permission returned HTTP 403 with access.api.error.not_enabled: Access is not enabled. The 1.9.1 installer sends that response through the same credential flow as other 403 responses. In an interactive install, that flow prompts for an App Access API token. Void CLI 1.9.1 source

Expected behavior

When --app-access public is selected and Cloudflare explicitly reports that Access is disabled, the installer should continue with public app setup without requesting a separate App Access token or creating Access policies. Other authorization failures and accounts with Default-Deny enabled should continue through the existing checks.

Vorherrschende Sprache
TypeScript
Sterne
684
Forks
83
Ø Merge
15 Std. 22 Min.
Gemergte PRs (30 T.)
219

Entwicklungsumgebung

Dieses Projekt bietet weder Dev-Container noch Dockerfile noch Beitragsleitfaden – die Einrichtung liegt bei Ihnen. Beginnen Sie mit der README; die allgemeinen Schritte stehen in unserem Leitfaden für den ersten Beitrag.

Erste Schritte

  1. Lesen Sie das ganze Issue und danach den Beitragsleitfaden des Projekts.
  2. Schreiben Sie ins Issue, dass Sie es übernehmen — das erspart doppelte Arbeit.
  3. Forken Sie das Repository und arbeiten Sie in einem Branch.
  4. Öffnen Sie einen Pull Request, der die Issue-Nummer nennt.

Mehr aus voidzero-dev/void

Alle Issues in voidzero-dev/void

Ähnliche Issues

Weitere Issues zu TypeScript

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.