refactor(go-website): implement the linter page in go - #5841
Open
michaelkedar wants to merge 1 commit into
Open
Conversation
michaelkedar
force-pushed
the
weblinter
branch
6 times, most recently
from
August 25, 2026 02:03
b3edd20 to
919d10f
Compare
michaelkedar
force-pushed
the
weblinter
branch
2 times, most recently
from
August 25, 2026 03:10
919d10f to
788bc04
Compare
another-rex
approved these changes
Aug 25, 2026
another-rex
reviewed
Aug 27, 2026
|
|
||
| // GetFindings downloads the result.json findings file for the specified source. | ||
| func (s *LinterStore) GetFindings(ctx context.Context, source string) ([]byte, error) { | ||
| if source == "" || strings.Contains(source, "/") || strings.Contains(source, "..") { |
Contributor
There was a problem hiding this comment.
also check for "." by itself as well. (prevents access to the linter-result/results.json page)
| t.Parallel() | ||
|
|
||
| s := gcs.NewLinterStore(nil, "") | ||
| invalidSources := []string{"", "../etc/passwd", "a/b", "..", "/root"} |
Contributor
There was a problem hiding this comment.
Suggested change
| invalidSources := []string{"", "../etc/passwd", "a/b", "..", "/root"} | |
| invalidSources := []string{"", "../etc/passwd", "a/b", "..", "/root", "."} |
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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Did all the Database logic for getting the osv linter results webpage to work in go.
Stack created with GitHub Stacks CLI • Give Feedback 💬