CVE Catalog

CVE-2026-42503

High
Published: Translated: NVD NIST

Summary

gopls by default communicates via pipe, but supports -port and -listen flags for debugging. Using -listen without an explicit host or using -port causes gopls to listen on 0.0.0.0, potentially exposing the service unintentionally.

Risk Assessment

This can allow malicious parties on the same network to execute arbitrary code via gopls, posing a serious security threat to the organization.

Recommendation

It is recommended to avoid using -listen and -port flags without specifying a concrete host. Consider restricting access to gopls only to trusted IP addresses.

Related vulnerabilities

Original NVD description (English source)

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.

Vulnerability data from NVD (NIST) · CISA KEV · EPSS