-
Notifications
You must be signed in to change notification settings - Fork 11
[KDM-TEST-FIX-324] Fix:critical security vulnerability in the file cache system #324
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
Merged
Merged
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
18d21c9
🛡️ Sentinel: [MEDIUM] Add request size limit and security headers to …
utkarsh232005 ec7d479
Fix path traversal vulnerability in FileCacheProvider
utkarsh232005 3b87225
🛡️ Sentinel: [CRITICAL] Fix path traversal in cache
utkarsh232005 f03e906
Merge pull request #11 from utkarsh232005/sentinel/fix-cache-path-tra…
utkarsh232005 3834a5f
Merge branch 'main' into sentinel/fix-path-traversal-cache-2927887491…
utkarsh232005 86e1cc9
Merge pull request #12 from utkarsh232005/sentinel/fix-path-traversal…
utkarsh232005 318b73f
Merge branch 'main' into sentinel-http-server-security-15678774515527…
utkarsh232005 87f5654
Merge pull request #6 from utkarsh232005/sentinel-http-server-securit…
utkarsh232005 3c6361d
Merge branch 'KDM-cli:main' into main
utkarsh232005 23a60e7
🛡️ Sentinel: [HIGH] Fix Symlink-based Path Traversal in File Cache
utkarsh232005 79bb30c
Merge pull request #13 from utkarsh232005/fix-cache-symlink-traversal…
utkarsh232005 a3425db
Merge branch 'KDM-cli:main' into main
utkarsh232005 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,8 @@ | ||
| ## 2023-11-20 - [Missing input length limits and security headers in local HTTP server] | ||
| **Vulnerability:** The local CLI dashboard HTTP server did not limit the length of POST request bodies, introducing a DoS risk. In addition, it lacked basic security headers. | ||
| **Learning:** Even local CLI HTTP servers require fundamental HTTP security controls (like payload limits and headers) to prevent exploitation, particularly since they may interact with browsers or external services via custom endpoints. | ||
| **Prevention:** Always enforce a request size limit on raw Node.js streams and return generic security headers for JSON API responses. | ||
| ## 2024-05-24 - [Critical] Path Traversal in File Cache | ||
| **Vulnerability:** Path Traversal vulnerability in FileCacheProvider due to unsanitized cache keys. | ||
| **Learning:** User input acting as filenames must always be validated to ensure it cannot escape the intended directory. | ||
| **Prevention:** Always use path.resolve and verify the resulting path starts with the intended base directory. |
This file contains hidden or 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 hidden or 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 hidden or 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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.