Go#
What licenseal reads in a Go module. The rules that hold for every ecosystem are under How a scan works.
- Registry: deps.dev for licenses, proxy.golang.org for a module's requirements
- Manifests:
go.mod(require,replace,tooldirective) - Lockfiles:
go.sum
What is read#
- With a
go.sum, the report holds its modules plus everygo.modrequirement at the required version; no version is chosen amonggo.sumrows, so a row for another version of a module stays in the report. replacedirectives of the scannedgo.modare applied: a requirement replaced by another module is scanned as that module. So are thereplacedirectives of ago.workin the scanned directory, for the modules it lists withuse; they override those modules' own.go.workusedirectories are followed only when they are relative paths.
Dev dependencies#
Only a module named by a tool directive (Go 1.24+) is a dev dependency, unless a production module also requires it. // indirect is not a dev marker, and test-only requirements cannot be told from production ones.
Off-registry dependencies#
A requirement replaced by a local path the scan does not read is reported as an off-registry dependency (one it reads is the project's own code). A path written in go.work is relative to go.work.
Not evaluated#
replacedirectives in a dependency'sgo.mod, and ago.workbelow the scanned directory.- A
go.modwith agodirective below 1.17, or none, lists direct requirements only: when one of them has nogo.sumrow, what it depends on is missing and thego.modis an analysis gap; committing an up-to-datego.sumremoves it.
See also#
- Dependency resolution and Versions and estimates, which apply to every ecosystem
- Network egress, for the hosts contacted and what each is asked