diff --git a/html5lib/filters/sanitizer.py b/html5lib/filters/sanitizer.py index 47da50fe..b5ddcb93 100644 --- a/html5lib/filters/sanitizer.py +++ b/html5lib/filters/sanitizer.py @@ -11,7 +11,7 @@ __all__ = ["Filter"] -acceptable_elements = frozenset(( +allowed_elements = frozenset(( (namespaces['html'], 'a'), (namespaces['html'], 'abbr'), (namespaces['html'], 'acronym'), @@ -175,7 +175,7 @@ (namespaces['svg'], 'use'), )) -acceptable_attributes = frozenset(( +allowed_attributes = frozenset(( # HTML attributes (None, 'abbr'), (None, 'accept'), @@ -552,7 +552,7 @@ (None, 'use') )) -acceptable_css_properties = frozenset(( +allowed_css_properties = frozenset(( 'azimuth', 'background-color', 'border-bottom-color', @@ -601,7 +601,7 @@ 'width', )) -acceptable_css_keywords = frozenset(( +allowed_css_keywords = frozenset(( 'auto', 'aqua', 'black', @@ -643,7 +643,7 @@ 'yellow', )) -acceptable_svg_properties = frozenset(( +allowed_svg_properties = frozenset(( 'fill', 'fill-opacity', 'fill-rule', @@ -654,7 +654,7 @@ 'stroke-opacity', )) -acceptable_protocols = frozenset(( +allowed_protocols = frozenset(( 'ed2k', 'ftp', 'http', @@ -680,7 +680,7 @@ 'data', )) -acceptable_content_types = frozenset(( +allowed_content_types = frozenset(( 'image/png', 'image/jpeg', 'image/gif', @@ -689,14 +689,6 @@ 'text/plain', )) -allowed_elements = acceptable_elements -allowed_attributes = acceptable_attributes -allowed_css_properties = acceptable_css_properties -allowed_css_keywords = acceptable_css_keywords -allowed_svg_properties = acceptable_svg_properties -allowed_protocols = acceptable_protocols -allowed_content_types = acceptable_content_types - data_content_type = re.compile(r''' ^