diff --git a/setup.py b/setup.py index df71d5621..393af3b5b 100644 --- a/setup.py +++ b/setup.py @@ -80,6 +80,7 @@ setup( 'thrift>=0.9.3', 'thrift-sasl>=0.2.1', 'unidecode>=0.04.21', + 'bleach==2.1.2', ], extras_require={ 'cors': ['Flask-Cors>=2.0.0'], diff --git a/superset/assets/javascripts/dashboard/components/GridCell.jsx b/superset/assets/javascripts/dashboard/components/GridCell.jsx index 4f7213d3b..2748fccd9 100644 --- a/superset/assets/javascripts/dashboard/components/GridCell.jsx +++ b/superset/assets/javascripts/dashboard/components/GridCell.jsx @@ -108,6 +108,12 @@ class GridCell extends React.PureComponent { annotationQuery={annotationQuery} /> + { + /* This usage of dangerouslySetInnerHTML is safe since it is being used to render + markdown that is sanitized with bleach. See: + https://github.com/apache/incubator-superset/pull/4390 + and + https://github.com/apache/incubator-superset/commit/b6fcc22d5a2cb7a5e92599ed5795a0169385a825 */}