Skip to content

fs: default writeSecureFile to 0600 (owner-only)#155

Closed
1seal wants to merge 1 commit intogoogle-github-actions:mainfrom
1seal:codex/fs-writeSecureFile-0600
Closed

fs: default writeSecureFile to 0600 (owner-only)#155
1seal wants to merge 1 commit intogoogle-github-actions:mainfrom
1seal:codex/fs-writeSecureFile-0600

Conversation

@1seal
Copy link

@1seal 1seal commented Mar 3, 2026

writeSecureFile currently defaults to 0o640, which makes created files group-readable. Since this helper is used to write credential material (directly or via downstream actions), this changes the default to 0o600 while keeping the ability for callers to override mode explicitly.

Changes:

  • Update writeSecureFile default mode to 0o600
  • Update unit tests to assert the new default and keep coverage for custom mode
  • Update generated docs/dist outputs accordingly

Compatibility:

  • Callers that relied on group-readable defaults can restore the previous behavior by passing mode: 0o640 explicitly.

Testing:

  • npm test
  • npm run lint

@1seal 1seal requested a review from a team as a code owner March 3, 2026 17:12
@1seal 1seal requested review from R2wenD2 and verbanicm March 3, 2026 17:12
@1seal
Copy link
Author

1seal commented Mar 3, 2026

closing as duplicate of #154 (same writeSecureFile 0600 change).

@1seal 1seal closed this Mar 3, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

1 participant