Skip to content

fix(ng-dev): sanitize credentials and tokens from GitClient logs and errors#3762

Merged
josephperrott merged 1 commit into
angular:mainfrom
josephperrott:fix/sec-git-client-sanitize-58c20eaf
Jun 8, 2026
Merged

fix(ng-dev): sanitize credentials and tokens from GitClient logs and errors#3762
josephperrott merged 1 commit into
angular:mainfrom
josephperrott:fix/sec-git-client-sanitize-58c20eaf

Conversation

@josephperrott

Copy link
Copy Markdown
Member

Addresses 58c20eaf. Redacts credentials and GitHub tokens from GitClient and AuthenticatedGitClient logs and error messages/stacks.

@josephperrott josephperrott added the target: patch This PR is targeted for the next patch release label Jun 6, 2026
@josephperrott josephperrott requested a review from alan-agius4 June 6, 2026 02:20

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request enhances the GitClient and AuthenticatedGitClient to sanitize HTTP credentials and process errors in console outputs, and introduces a new test suite to verify these changes. The feedback recommends improving cross-platform compatibility in the tests by replacing hardcoded /tmp paths with os.tmpdir(), and requests the removal of leftover debugging console.log statements.

Comment thread ng-dev/utils/test/git-client.spec.ts
Comment thread ng-dev/utils/test/git-client.spec.ts Outdated
Comment thread ng-dev/utils/test/git-client.spec.ts Outdated
Comment thread ng-dev/utils/test/git-client.spec.ts Outdated
Comment thread ng-dev/utils/test/git-client.spec.ts Outdated
Comment thread ng-dev/utils/test/git-client.spec.ts Outdated
Comment thread ng-dev/utils/test/git-client.spec.ts Outdated
@josephperrott josephperrott added action: merge The PR is ready for merge by the caretaker and removed target: patch This PR is targeted for the next patch release labels Jun 6, 2026
@josephperrott josephperrott force-pushed the fix/sec-git-client-sanitize-58c20eaf branch 2 times, most recently from f6636ea to fccae4f Compare June 6, 2026 21:49
@josephperrott josephperrott force-pushed the fix/sec-git-client-sanitize-58c20eaf branch 3 times, most recently from 91ebc33 to 1864883 Compare June 8, 2026 14:34
@josephperrott josephperrott force-pushed the fix/sec-git-client-sanitize-58c20eaf branch from 1864883 to 787ac61 Compare June 8, 2026 14:41
@josephperrott josephperrott merged commit 8f2bf2b into angular:main Jun 8, 2026
16 checks passed
@josephperrott

Copy link
Copy Markdown
Member Author

This PR was merged into the repository. The changes were merged into the following branches:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

action: merge The PR is ready for merge by the caretaker

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants