You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The parser will crash only when using the goldmark-highlighting extension. But as it seems like the crash is generated within the parser itself, I decided to report the issue in this repo instead.
Extracted a runnable test:
package main
import (
"bytes"
"fmt"
"github.com/yuin/goldmark" // Version v1.3.5
highlighting "github.com/yuin/goldmark-highlighting" // Version v0.0.0-20210428103930-3a9678dbb86c
)
var gm = goldmark.New(
goldmark.WithExtensions(
highlighting.NewHighlighting(),
),
)
// This input will crash the parser
var input string = "```0{class=0#."
func main() {
var buf bytes.Buffer
err := gm.Convert([]byte(input), &buf)
fmt.Println("Error:", err)
}
The text was updated successfully, but these errors were encountered:
lmas
changed the title
Fuzz crash on ``0{class=0#. when using goldmark-highlighting` extension
Fuzz crash on ```0{class=0#. when using goldmark-highlighting extension
May 4, 2021
Please answer the following before submitting your issue:
v1.3.5
go1.16
linux/amd64
ran go-fuzz on my own project that uses the goldmark parser
no crashes by goldmark
The parser will crash only when using the
goldmark-highlighting
extension. But as it seems like the crash is generated within the parser itself, I decided to report the issue in this repo instead.Extracted a runnable test:
The text was updated successfully, but these errors were encountered: