Let a user set a git token for a private repository #303

Closed
opened 2026-09-21 16:04:54 +00:00 by sharang · 0 comments
Owner

Found while doing #260 (PR #302).

Problem: no API path stores credentials on an artifact. ArtifactInput (target create, PATCH artifacts, add artifact) has no auth, so a private repository can't be cloned. The pilot's repositories will be private, and git access is HTTPS-token only since #255.

Change: accept an optional token (and username) per git artifact on create, add and update. Seal it with SecretBox (#260), never return it, and show only "token set" in the wizard and the target editor.

Acceptance:

  • A private repo can be onboarded and scanned with a PAT.
  • The token is stored as enc:v1:, is absent from every response, and can be replaced or cleared.
Found while doing #260 (PR #302). **Problem:** no API path stores credentials on an artifact. `ArtifactInput` (target create, `PATCH` artifacts, add artifact) has no `auth`, so a private repository can't be cloned. The pilot's repositories will be private, and git access is HTTPS-token only since #255. **Change:** accept an optional token (and username) per git artifact on create, add and update. Seal it with `SecretBox` (#260), never return it, and show only "token set" in the wizard and the target editor. **Acceptance:** - A private repo can be onboarded and scanned with a PAT. - The token is stored as `enc:v1:`, is absent from every response, and can be replaced or cleared.
sharang added this to the Production MVP milestone 2026-09-21 16:04:54 +00:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: platform/pruefwerk#303