internal/proxy, cmd/vulnreport: fix infinite loop on root module paths

Prevent FindModule from looping indefinitely when path is "/" or
contains a leading slash where path.Dir returns itself. Also ignore
standalone slashes in vulnreport issue title parsing.

Change-Id: I76f19ab826d4816a949686079fdd7f25009c0bba
Reviewed-on: https://go-review.googlesource.com/c/vulndb/+/821280
LUCI-TryBot-Result: golang-scoped@luci-project-accounts.iam.gserviceaccount.com <golang-scoped@luci-project-accounts.iam.gserviceaccount.com>
Reviewed-by: Damien Neil <dneil@google.com>
4 files changed
tree: 99f31a65aa918208b3822a48d861b19d62d0fc09
  1. .github/
  2. cmd/
  3. data/
  4. deploy/
  5. devtools/
  6. doc/
  7. internal/
  8. report/
  9. terraform/
  10. webconfig/
  11. .gitignore
  12. all_test.go
  13. checks.bash
  14. CONTRIBUTING.md
  15. go.mod
  16. go.sum
  17. LICENSE
  18. PATENTS
  19. README.md
  20. tools_test.go
README.md

The Go Vulnerability Database

Go Reference

This repository contains the infrastructure and internal reports to create the Go Vulnerability Database.

Warning: Packages here are internal to the Go Security Team and its needs; Some may be modified arbitrarily or even disappear altogether. In short, code in this repository is NOT subject to the Go 1 Compatibility Promise.

Check out https://go.dev/security/vuln for more information about the Go vulnerability management system.

Reporting a vulnerability or feedback

Click here to report a public vulnerability in the Go ecosystem, or give feedback about the project.

Privacy Policy

The privacy policy for govulncheck can be found at https://vuln.go.dev/privacy.

License

Unless otherwise noted, the Go source files are distributed under the BSD-style license found in the LICENSE file.

Database entries are distributed under the terms of the CC-BY-4.0 license. See go.dev/security/vuln/database for information on how to access these entries.