Member-only story
Secure Your Go Code With Vulnerability Check Tool
Official tools to protect your code
Security vulnerabilities exist in any language and any code, some are written by ourselves, but more are from the upstream dependencies, even the underlying Linux. We have discussed the security protection methods for Go and Kubernetes Image in Path to a Perfect Go Dockerfile and Image Vulnerability Scanning for Optimal Kubernetes Security, in which the security scanning was performed based on generic.
As the Go community grows, more and more open-source packages have caused more security vulnerabilities, which has raised the concern of Go officials, and then the security scanning tool Go Vulnerability Check was introduced in September 2022.

If you are interested in this tool, just follow me, and let’s digest its internal logic and then make full use of it.
Use Go Vulnerability Check
First, let’s try it.
Install(only supported from Go 1.18).
go install golang.org/x/vuln/cmd/govulncheck@latest