forgejo/modules/markup
Lunny Xiao b01dce2a6e
Allow render HTML with css/js external links (#19017)
* Allow render HTML with css/js external links

* Fix bug because of filename escape chars

* Fix lint

* Update docs about new configuration item

* Fix bug of render HTML in sub directory

* Add CSP head for displaying iframe in rendering file

* Fix test

* Apply suggestions from code review

Co-authored-by: delvh <dev.lh@web.de>

* Some improvements

* some improvement

* revert change in SanitizerDisabled of external renderer

* Add sandbox for iframe and support allow-scripts and allow-same-origin

* refactor

* fix

* fix lint

* fine tune

* use single option RENDER_CONTENT_MODE, use sandbox=allow-scripts

* fine tune CSP

* Apply suggestions from code review

Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>

Co-authored-by: delvh <dev.lh@web.de>
Co-authored-by: wxiaoguang <wxiaoguang@gmail.com>
2022-06-16 11:33:23 +08:00
..
common
console Allow render HTML with css/js external links (#19017) 2022-06-16 11:33:23 +08:00
csv Allow render HTML with css/js external links (#19017) 2022-06-16 11:33:23 +08:00
external Allow render HTML with css/js external links (#19017) 2022-06-16 11:33:23 +08:00
markdown Allow render HTML with css/js external links (#19017) 2022-06-16 11:33:23 +08:00
mdstripper
orgmode Allow render HTML with css/js external links (#19017) 2022-06-16 11:33:23 +08:00
camo.go Provide configuration to allow camo-media proxying (#12802) 2022-03-29 10:27:37 +02:00
camo_test.go Provide configuration to allow camo-media proxying (#12802) 2022-03-29 10:27:37 +02:00
html.go Custom regexp external issues (#17624) 2022-06-10 13:39:53 +08:00
html_internal_test.go Custom regexp external issues (#17624) 2022-06-10 13:39:53 +08:00
html_test.go Allow render HTML with css/js external links (#19017) 2022-06-16 11:33:23 +08:00
renderer.go Allow render HTML with css/js external links (#19017) 2022-06-16 11:33:23 +08:00
renderer_test.go
sanitizer.go
sanitizer_test.go