GHSA-77fj-vx54-gvh7 is a high-severity (CVSS 7.5) Out-of-bounds Read vulnerability in github.com/gomarkdown/markdown. O3 Security confirms whether GHSA-77fj-vx54-gvh7 is actually reachable in your code before you act, and blocks exploitation at runtime until you patch.
Go Markdown has an Out-of-bounds Read in SmartypantsRenderer
Real-World Exposure
github.com/gomarkdown/markdownReal-time download stats are indexed for npm and PyPI packages. This vulnerability affects Go packages — download data is not available via public APIs for these ecosystems.
Description
Summary
Processing a malformed input containing a < character that is not followed by a > character anywhere in the remaining text with a SmartypantsRenderer will lead to Out of Bounds read or a panic.
Details
The smartLeftAngle() function in html/smartypants.go:367-376 performs an out-of-bounds slice operation when processing a < character that is not followed by a > character anywhere in the remaining text.
https://github.com/gomarkdown/markdown/blob/37c66b85d6ab025ba67a73ba03b7f3ef55859cca/html/smartypants.go#L367-L376
If the length of the slice is lower than its capacity, this leads to an extra byte of data read. If the length equals the capacity, this leads to a panic.
PoC
package main
import (
"bytes"
"fmt"
"github.com/gomarkdown/markdown/html"
)
func main() {
src := []byte("<a")
fmt.Printf("Input: %q (len=%d, cap=%d)\n", src, len(src), cap(src))
var buf bytes.Buffer
sp := html.NewSmartypantsRenderer(html.Smartypants)
sp.Process(&buf, src) // panics: slice bounds out of range
fmt.Printf("Output: %q\n", buf.String())
}
Impact
This vulnerability will lead to a Denial of Service / panic on the processing service.
-- The Datadog Security Team
Affected Packages
| Ecosystem | Package | Vulnerable range | Fix |
|---|---|---|---|
| 🐹Go | github.com/gomarkdown/markdown | all versions | 0.0.0-20260411013819-759bbc3e3207 |
Detection & mitigation playbook
Open-source dependencyDetect
Scan your dependency tree (package-lock.json, pnpm-lock.yaml, requirements.txt, go.sum, etc.) for github.com/gomarkdown/markdown. O3's reachability analysis confirms whether the vulnerable code path is actually invoked in your application, so you act on real exposure instead of every transitive match.
Fix
Update github.com/gomarkdown/markdown to 0.0.0-20260411013819-759bbc3e3207 or later, then make sure no transitive (indirect) dependency still pins the vulnerable range — O3 confirms GHSA-77fj-vx54-gvh7 is resolved across your whole dependency graph.
Workarounds
If you can't upgrade right away: gate or disable the affected feature, validate untrusted input at the boundary, and avoid passing attacker-controlled data into the vulnerable path. O3's runtime protection blocks exploitation in production as an interim safeguard until the upgrade lands.
How O3 protects you
O3 pinpoints whether GHSA-77fj-vx54-gvh7 is reachable in your code and exactly where to fix it, then blocks exploitation in production at runtime until the patched version is deployed.
Tailored to GHSA-77fj-vx54-gvh7. Runtime protection reduces exposure until a permanent patch is applied and verified — it complements patching, it doesn't replace it.
Frequently Asked Questions
Is GHSA-77fj-vx54-gvh7 in your dependencies?
O3 detects GHSA-77fj-vx54-gvh7 across Go dependencies and uses function-level reachability to confirm whether the vulnerable code path is actually reachable — not just present. No false positives.