Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds custom logging using tflog and removes sensitive fields from HTTP requests and responses #341

Merged
merged 20 commits into from
Jan 27, 2023

Conversation

gdavison
Copy link
Contributor

Replaces calls to log.Printf(...) with tflog calls.

Adds custom HTTP request and response logging that removes sensitive fields. Includes:

  • IAM unique ID values, such as User IDs and temporary STS credentials
  • HTTP request Authorization headers

Public functions now take a context.Context parameter.

@gdavison gdavison requested a review from a team as a code owner January 25, 2023 21:33
jar-b
jar-b previously approved these changes Jan 26, 2023
Copy link
Member

@jar-b jar-b left a comment

Choose a reason for hiding this comment

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

LGTM - just a couple sections of commented code that possibly could be removed?

v2/awsv1shim/session.go Outdated Show resolved Hide resolved
v2/awsv1shim/logger.go Outdated Show resolved Hide resolved
logger.go Outdated Show resolved Hide resolved
go.work Show resolved Hide resolved
aws_config.go Outdated Show resolved Hide resolved
Copy link
Member

@jar-b jar-b left a comment

Choose a reason for hiding this comment

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

LGTM 🎉

@gdavison gdavison merged commit 950aa16 into main Jan 27, 2023
@gdavison gdavison deleted the logging branch January 27, 2023 23:51
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.

2 participants