horizon/horizon
CristianFiorentino 1b0106e280 Introduces escaping in Horizon/Orchestration
1) Escape help_text a second time to avoid bootstrap tooltip XSS issue

The "Description" parameter in a Heat template is used to populate
a help_text tooltip in the dynamically generated Heat form. Bootstrap
inserts this tooltip into the DOM using .html() which undoes any
escaping we do in Django (it should be using .text()).

This was fixed by forcing the help_text content to be escaped a second
time. The issue itself is mitigated in bootstrap.js release 2.0.3
(ours is currently 2.0.1).

2) Properly escape untrusted Heat template 'outputs'

The 'outputs' parameter in a Heat template was included in a Django
template with HTML autoescaping turned off. Malicious HTML content
could be included in a Heat template and would be rendered by Horizon
when details about a created stack were displayed.

This was fixed by not disabling autoescaping and explicitly escaping
untrusted values in any strings that are later marked "safe" to render
without further escaping.

Change-Id: Icd9f9d9ca77068b12227d77469773a325c840001
Closes-Bug: #1289033
Co-Authored-By: Kieran Spear <kispear@gmail.com>
2014-04-09 00:04:39 +09:00
..
browsers Replace asserts in __init__ files with __all__ 2014-01-10 10:28:02 +01:00
conf Remove leftovers of "# noqa" 2014-01-28 15:51:04 +04:00
forms Replace asserts in __init__ files with __all__ 2014-01-10 10:28:02 +01:00
locale Import translations from Transifex for Icehouse 2014-04-07 16:32:34 +09:00
management Gate on H102 Apache 2.0 license header not found for pep8 2013-11-19 13:55:04 -05:00
static Cardinal interpolation error 2014-04-07 13:41:14 +09:00
tables Merge "Selected instances are not deleted with pagination" 2014-03-21 14:43:10 +00:00
tabs Raise an error when no slug on tab group 2014-03-07 07:30:17 -05:00
templates Introduces escaping in Horizon/Orchestration 2014-04-09 00:04:39 +09:00
templatetags Implementing accordion navigation 2014-02-26 14:03:36 -07:00
test Merge "Handle "null" time values for Stacks" 2014-03-31 14:59:46 +00:00
utils Handle "null" time values for Stacks 2014-03-26 12:00:53 +00:00
workflows Allow redisplay of the workflow from its handle() 2014-02-25 09:51:45 +01:00
__init__.py Remove asserts for optional imports 2013-11-15 10:09:44 +01:00
base.py Plugin-based panel group configuration 2014-03-29 01:05:03 +09:00
context_processors.py Gate on H4xx docstrings for pep8 2013-11-23 12:51:07 -05:00
decorators.py Remove #noqa from most common imports and add them to import_exceptions 2014-01-07 12:26:35 +01:00
exceptions.py Fix Exceptions doc page generation 2014-03-28 12:32:31 +07:00
loaders.py Remove #noqa from most common imports and add them to import_exceptions 2014-01-07 12:26:35 +01:00
messages.py Remove leftovers of "# noqa" 2014-01-28 15:51:04 +04:00
middleware.py Fix middleware to not access session fields without user auth 2014-03-06 08:24:34 -07:00
models.py Unifies the project packaging into one set of modules. 2012-02-29 00:20:13 -08:00
site_urls.py Add jasmine testing and helpers 2014-02-17 15:05:23 +01:00
version.py Replace OpenStack LLC with OpenStack Foundation 2013-09-20 04:19:42 +08:00
views.py Gate on H4xx docstrings for pep8 2013-11-23 12:51:07 -05:00