Skip to content

net: panic in Dial and LookupPort when handling NUL byte on Windows (fix CVE-2026-39836) #79006

Description

@thatnealpatel

The Dial and LookupPort functions would panic on Windows when provided
with an input containing a NUL (0). These functions now return an error
rather than panicking.

This is CVE-2026-39836 and Go issue https://go.dev/issue/79006.


This was a PRIVATE track issue, tracked in http://b/502138517.

Activity

  1. thatnealpatel commented on Apr 29, 2026

    @thatnealpatel
    MemberAuthor

    Hi @gopherbot, please open backport issues for this security issue.

  2. gopherbot commented on Apr 29, 2026

    @gopherbot
    Contributor

    Backport issue(s) opened: #79028 (for 1.25), #79029 (for 1.26).

    Remember to create the cherry-pick CL(s) as soon as the patch is submitted to master, according to https://go.dev/wiki/MinorReleases.

  3. added
    NeedsFixThe path to resolution is known, but the work has not been done.
    on Apr 29, 2026
  4. gopherbot commented on May 7, 2026

    @gopherbot
    Contributor

    Change https://go.dev/cl/775160 mentions this issue: [release-branch.go1.25] all: avoid unsafe StringToUTF16Ptr on Windows

  5. gopherbot commented on May 7, 2026

    @gopherbot
    Contributor

    Change https://go.dev/cl/775162 mentions this issue: [release-branch.go1.26] all: avoid unsafe StringToUTF16Ptr on Windows

  6. changed the title [-]security: fix CVE-2026-39836[/-] [+]net: panic in Dial and LookupPort when handling NUL byte on Windows (fix CVE-2026-39836)[/+] on May 7, 2026
  7. gopherbot commented on May 7, 2026

    @gopherbot
    Contributor

    Change https://go.dev/cl/775320 mentions this issue: all: avoid unsafe StringToUTF16Ptr on Windows

  8. added a commit that references this issue on May 7, 2026
    788b1c5
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    NeedsFixThe path to resolution is known, but the work has not been done.Securityrelease-blockervulncheck or vulndbIssues for the x/vuln or x/vulndb repo

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions