Skip to content

Commit

Permalink
another clusterfuzz spotted issue (go-gitea#15032)
Browse files Browse the repository at this point in the history
Signed-off-by: Andrew Thornton <art27@cantab.net>
  • Loading branch information
zeripath authored and 6543 committed Mar 18, 2021
1 parent 8c461eb commit 4a24e85
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion modules/markup/html.go
Original file line number Diff line number Diff line change
Expand Up @@ -298,7 +298,7 @@ func RenderEmoji(
return ctx.postProcess(rawHTML)
}

var tagCleaner = regexp.MustCompile(`<((?:/?\w+/\w+)|(?:/[\w ]+/)|(/?[hH][tT][mM][lL][ />]))`)
var tagCleaner = regexp.MustCompile(`<((?:/?\w+/\w+)|(?:/[\w ]+/)|(/?[hH][tT][mM][lL][ />])|(/?[hH][eE][aA][dD][ />]))`)
var nulCleaner = strings.NewReplacer("\000", "")

func (ctx *postProcessCtx) postProcess(rawHTML []byte) ([]byte, error) {
Expand Down

0 comments on commit 4a24e85

Please sign in to comment.