Skip to content

Commit

Permalink
add safety comment on the SQL op
Browse files Browse the repository at this point in the history
  • Loading branch information
onur-ozkan authored Jan 9, 2024
1 parent 9ef736c commit 85cb71f
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions package-search-api.go
Original file line number Diff line number Diff line change
Expand Up @@ -138,6 +138,7 @@ func queryEndpoint(w http.ResponseWriter, r *http.Request) {
return
}

// SAFETY: pkg_search param is validated through a regex pattern in validateSearchValue function.
query := fmt.Sprintf(`
SELECT
name, v_readable as version, description, arch, kind, tags, installed_size as "installed size", maintainer, license, source_repository as "repository", mandatory_dependencies as "dependencies"
Expand Down

0 comments on commit 85cb71f

Please sign in to comment.