Skip to content

Commit

Permalink
all: remove build restrictions requiring go1.18
Browse files Browse the repository at this point in the history
govulncheck's go.mod file explicitly requires go1.21 and it can analyze
binaries built before go1.18. There is no need to have these build
restrictions.

Change-Id: I50a80da2490fd4bd8fb3d5b7a68f8796ff3ffe18
Reviewed-on: https://go-review.googlesource.com/c/vuln/+/597575
LUCI-TryBot-Result: Go LUCI <[email protected]>
Reviewed-by: Maceo Thompson <[email protected]>
  • Loading branch information
zpavlinovic committed Jul 10, 2024
1 parent 44e45ea commit d9ad522
Show file tree
Hide file tree
Showing 6 changed files with 1 addition and 20 deletions.
6 changes: 0 additions & 6 deletions cmd/govulncheck/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,6 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

// Only run this on Go 1.18 or higher, because govulncheck can't
// run on binaries before 1.18.

//go:build go1.18
// +build go1.18

package main

import (
Expand Down
3 changes: 0 additions & 3 deletions internal/scan/binary.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

//go:build go1.18
// +build go1.18

package scan

import (
Expand Down
3 changes: 0 additions & 3 deletions internal/scan/extract.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

//go:build go1.18
// +build go1.18

package scan

import (
Expand Down
3 changes: 0 additions & 3 deletions internal/vulncheck/binary.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

//go:build go1.18
// +build go1.18

package vulncheck

import (
Expand Down
3 changes: 0 additions & 3 deletions internal/vulncheck/binary_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,6 @@
// Use of this source code is governed by a BSD-style
// license that can be found in the LICENSE file.

//go:build go1.18
// +build go1.18

package vulncheck

import (
Expand Down
3 changes: 1 addition & 2 deletions internal/vulncheck/doc.go
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,7 @@ detection in Go source code and binaries, respectively.
[Source] accepts a list of [Package] objects, which
are a trimmed version of [golang.org/x/tools/go/packages.Package] objects to
reduce memory consumption. [Binary] accepts a path to a Go binary file that
must have been compiled with Go 1.18 or greater.
reduce memory consumption. [Binary] accepts a path to a Go binary file.
Both [Source] and [Binary] require information about known
vulnerabilities in the form of a vulnerability database,
Expand Down

0 comments on commit d9ad522

Please sign in to comment.