retrospring/config/initializers/sanitize.rb

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

9 lines
227 B
Ruby
Raw Normal View History

2014-12-28 19:06:04 +01:00
EVIL_TAGS = {
2014-12-28 19:12:28 +01:00
elements: %w(blockquote a p i strong em del pre code table tr td th br ul ol li hr),
2014-12-28 19:06:04 +01:00
attributes: {
2021-12-31 22:23:45 +01:00
'a' => %w(href target rel)
2014-12-28 19:06:04 +01:00
},
protocols: {
'a' => { 'href' => ['http', 'https', :relative] }
}
}