CVE-2026-42503 PUBLISHED

Accidental binding to INADDR_ANY might lead to RCE in golang.org/x/tools/gopls

Assigner: Go
Reserved: 28.04.2026 Published: 06.05.2026 Updated: 07.05.2026

gopls by default communicates via pipe. However, -port and -listen flags are supported as means of debugging. If -listen is given a value without an explicit host (e.g. :8080), or -port is used, gopls will listen on 0.0.0.0.  As a result, users might inadvertently cause gopls to bind 0.0.0.0. This can allow a malicious party on the same network to execute code arbitrarily via gopls.

Product Status

Vendor golang.org/x/tools
Product golang.org/x/tools/gopls
Versions Default: unaffected
  • affected from 0.0.0 to 0.22.0 (excl.)

References

Problem Types

  • CWE-1327 Binding to an unrestricted IP address CWE