Skip to content

fix: mask decoded PGP key in CI logs#20

Merged
endrju19 merged 2 commits intomainfrom
fix/pgp-key-masking
Apr 8, 2026
Merged

fix: mask decoded PGP key in CI logs#20
endrju19 merged 2 commits intomainfrom
fix/pgp-key-masking

Conversation

@endrju19
Copy link
Copy Markdown
Collaborator

@endrju19 endrju19 commented Apr 7, 2026

Summary

  • Decode base64 PGP key and mask with ::add-mask:: before passing to Gradle
  • Key stays in process memory, never written to $GITHUB_ENV
  • Empty lines filtered to avoid add-mask warnings

Test plan

  • Masking verified on test repo — decoded key shows as *** in logs
  • CI passes

Previous approach wrote the decoded key to $GITHUB_ENV, which leaked it
in the env block of subsequent step logs. Now decode + mask each line
with ::add-mask:: + export in the same step, so the key never appears
in logs.
@endrju19 endrju19 closed this Apr 7, 2026
@endrju19 endrju19 reopened this Apr 7, 2026
@endrju19 endrju19 merged commit a20713c into main Apr 8, 2026
8 checks passed
@endrju19 endrju19 deleted the fix/pgp-key-masking branch April 8, 2026 07:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant