Advisory

GO-2026-4602

Also known as: BIT-golang-2026-27139, CVE-2026-27139

Summary

FileInfo can escape from a Root in os

Details

On Unix platforms, when listing the contents of a directory using File.ReadDir or File.Readdir the returned FileInfo could reference a file outside of the Root in which the File was opened.

The impact of this escape is limited to reading metadata provided by lstat from arbitrary locations on the filesystem without permitting reading or writing files outside the root.

Severity

Not rated by the source.

Dates

Published
2026-03-06 21:03 UTC
Modified
2026-05-15 10:59 UTC

Affected packages and fixes

stdlib

Go · All systems

Affected

  • introduced 0, fixed 1.25.8, introduced 1.26.0-0, fixed 1.26.1 (semver)

Fixed versions

1.25.8, 1.26.1

Fix

The export has no generic command for this ecosystem.

Fix commands are the export's own generic commands. Ojuju never runs them. Check them against your setup first.

Check your own computer: guard packages check

View this record on OSV.dev

Source

Source: Go Vulnerability Database · CC BY 4.0

Sources & licences