-
Notifications
You must be signed in to change notification settings - Fork 39.7k
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
Add datapolicy tags to staging/src/k8s.io/cri-api/ #96000
Conversation
@serathius: GitHub didn't allow me to request PR reviews from the following users: PurelyApplied. Note that only kubernetes members and repo collaborators can review this PR, and authors cannot review their own PRs. In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: serathius The full list of commands accepted by this bot can be found here.
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
/assign @derekwaynecarr |
@serathius: The following test failed, say
Full PR test history. Your PR dashboard. Please help us cut down on flakes by linking to an open issue when you hit one in your PR. Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here. |
I don't think it makes sense to add these to the generated go files because this is generated from api.proto. Have you done this with any other proto based interface yet? /cc @mrunalp |
@serathius Did you check if there is a way to pass these down from the proto file? |
@@ -5270,14 +5270,14 @@ func (m *ImageStatusResponse) GetInfo() map[string]string { | |||
// AuthConfig contains authorization information for connecting to a registry. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we link to the datapolicy kep here and/or provide a brief explanation of any client and server processing requirements? I believe the expectation here is these fields if output to a log would cause the log entry to be filterable by some datapolicy filtering tool. What's not clear is if there is any new expectation (or not) that container runtime integrations must apply a filter/mask for these fields (remove them from the logs replace with xxx etc.). I'd have to check to make sure but I believe I remember seeing commits over time that removed these fields from the logs.
@mrunalp Not to speak for @serathius, but there's an old protobuf Issue#52 about adding the ability to export field tags from protobuf. The long and short seems to be that protobuf doesn't want it to be possible by default. People have made plugins for it, but being unfamiliar with the nitty gritty of generating from |
/milestone clear |
https://blog.golang.org/protobuf-apiv2 describes |
I agree with the above fwiw; I think if we add the tags directly to the generated file, they'll just get overwritten. |
/assign @ehashman |
/hold |
Issues go stale after 90d of inactivity. If this issue is safe to close now please do so with Send feedback to sig-contributor-experience at kubernetes/community. |
/kind feature
What this PR does / why we need it:
This PR adds "datapolicy" tags to golang structures as described in Kubernetes system components logs sanitization KEP. Those tags will be used by for ensuring this data will not be written to logs by Kubernetes system components.
List of datapolicy tags available:
security-key
- for TLS certificate keys. Keywords:key
,cert
,pem
token
- for HTTP authorization tokens. Keywords:token
,secret
,header
,auth
password
- anything passwordlike. Keywords:password
Special notes for your reviewer:
Due to size of Kubernetes codebase first iteration of tagging was done based on greping for particular keyword. Please ensure that tagged fields do contain type of sensitive data that matches their tag. Feel free to suggest any additional places that you think should be tagged.
Does this PR introduce a user-facing change?:
No
Additional documentation e.g., KEPs (Kubernetes Enhancement Proposals), usage docs, etc.:
/cc @PurelyApplied
/sig instrumentation security
/priority important-soon
/milestone v1.20