warehost-web unsafe
This commit is contained in:
parent
bca651eece
commit
10c51a2189
|
@ -6,7 +6,7 @@ import (
|
||||||
"os"
|
"os"
|
||||||
"text/template"
|
"text/template"
|
||||||
|
|
||||||
"github.com/microcosm-cc/bluemonday"
|
//"github.com/microcosm-cc/bluemonday"
|
||||||
"github.com/russross/blackfriday"
|
"github.com/russross/blackfriday"
|
||||||
|
|
||||||
liblog "dev.sum7.eu/sum7/warehost/lib/log"
|
liblog "dev.sum7.eu/sum7/warehost/lib/log"
|
||||||
|
@ -80,7 +80,8 @@ func handlerfunc(w http.ResponseWriter, r *http.Request) {
|
||||||
page.Menu = menu
|
page.Menu = menu
|
||||||
|
|
||||||
unsafe := blackfriday.MarkdownCommon([]byte(page.Content))
|
unsafe := blackfriday.MarkdownCommon([]byte(page.Content))
|
||||||
page.Content = string(bluemonday.UGCPolicy().SanitizeBytes(unsafe))
|
//page.Content = string(bluemonday.UGCPolicy().SanitizeBytes(unsafe))
|
||||||
|
page.Content = string(unsafe)
|
||||||
i := TemplateInfo{
|
i := TemplateInfo{
|
||||||
Website: website,
|
Website: website,
|
||||||
Host: host,
|
Host: host,
|
||||||
|
|
Reference in New Issue