[security] Token can leak unmasked into git failure logs (URL-encoded credential) #6

Closed
opened 2026-06-23 20:14:55 +00:00 by stephen · 0 comments
Owner

Autonomous security audit finding (HIGH).

The token is embedded in the push URL (src/main.js:146-154). core.setSecret masks the raw token, but git's stderr echoes the URL-encoded credential, which doesn't match the registered mask — so on a push failure (setFailed ~:356) the encoded token can appear in logs.

Fix: use http.extraheader (Authorization) or GIT_ASKPASS and never embed the credential in the remote URL.

Autonomous security audit finding (HIGH). The token is embedded in the push URL (`src/main.js:146-154`). `core.setSecret` masks the raw token, but git's stderr echoes the URL-**encoded** credential, which doesn't match the registered mask — so on a push failure (`setFailed` ~:356) the encoded token can appear in logs. Fix: use `http.extraheader` (Authorization) or `GIT_ASKPASS` and never embed the credential in the remote URL.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
rasterstate/create-pull-request-action#6
No description provided.