-
Notifications
You must be signed in to change notification settings - Fork 9
Fix path traversal vulnerabilities in update-readme tool #40
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
Conversation
[APPROVALNOTIFIER] This PR is NOT APPROVED This pull-request has been approved by: harche 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 |
/hold until |
5c01dfe
to
7172f3e
Compare
Add input validation to prevent path traversal attacks in the update-readme internal tool: - Clean file path using filepath.Clean to remove path traversal sequences - Validate that only README.md files can be updated - Add argument count validation This fixes Snyk code scan findings: - MEDIUM severity path traversal in os.ReadFile (line 28) - MEDIUM severity path traversal in os.WriteFile (line 84) 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <noreply@anthropic.com>
7172f3e
to
2516eac
Compare
/test fips-image-scan-openshift-mcp-server |
@harche: The following test failed, say
Full PR test history. Your PR dashboard. 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-sigs/prow repository. I understand the commands that are listed here. |
/hold cancel lint job failures are fixed in #39 |
/cc @manusa |
@ardaguclu: GitHub didn't allow me to request PR reviews from the following users: manusa. Note that only openshift 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-sigs/prow repository. |
Hey @harche I think we fixed this on the upstream repo here: containers#345 and just need to backport that here (cc @ardaguclu @manusa) |
Great, thanks. /close |
IT's fixed, if snyk still complains we'll need to add the exception. |
@harche: Closed this PR. 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-sigs/prow repository. |
Summary
Fix path traversal vulnerabilities detected by Snyk code scan in the
internal/tools/update-readme
tool.🤖 Generated with Claude Code