-
Notifications
You must be signed in to change notification settings - Fork 144
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: prevent path traversal attacks (#631)
This commit fixes a path traversal vulnerability in the repository management code. The `SanitizeRepo` function now correctly returns a sanitized version of the given repository name. It uses an absolute path along with `path.Clean` to ensure that the path is cleaned before being used.
- Loading branch information
1 parent
0fb868c
commit a8d1bf3
Showing
3 changed files
with
23 additions
and
21 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters