It is possible to trigger a POST-Request to any address via Horizon
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Dashboard (Horizon) |
New
|
Undecided
|
Unassigned | ||
OpenStack Security Advisory |
Incomplete
|
Undecided
|
Unassigned |
Bug Description
# Description of the bug
We use horizon in the following version: `git+https:/
In Horizon there is the following code in Xena:
openstack_
```
def websso(request):
"""Logs a user in using a token from Keystone's POST."""
referer = request.
auth_url = utils.clean_
token = request.
try:
...
```
This call is usually called during SAML-Auth, but you can call it on the command line like this:
``
curl -v 'http://
``
So an attacker can control the content of the HTTP_REFERER and then an auth POST request will be sent to this address.
I have changed the referer to a web server https:/
```
access.log: <ip-address-
```
# Impact
* An attacker can hide his ip and do a brute force attack to any other ip via all public available horizon dashboards.
* An attacker can setup a machine, set the referer to this machine and then send some ugly results (e.g. very long, never ending, wrong json code, ssl protocol issues) to the horizon service.
* An attacker can analyze which services are available on the horizon host (if it is behind a firewall, use DNS Servers with private zones). Note that you are able to change the port number to any number. I have not tested, but perhaps it is also possible to change the protocol to another value, let's say: imap://
# Is this only relevant for xena
The code has changed on master branch, but the bug is still there:
```
# TODO(stephenfin): Migrate to CBV
@sensitive_
@csrf_exempt
@never_cache
def websso(request):
"""Logs a user in using a token from Keystone's POST."""
if settings.
referer = request.
auth_url = utils.clean_
else:
auth_url = settings.
token = request.
try:
except exceptions.
if settings.
res = django_
else:
msg = 'Login failed: %s' % exc
res = django_
return res
```
only changing the WEBSSO_
Since this report concerns a possible security risk, an incomplete
security advisory task has been added while the core security
reviewers for the affected project or projects confirm the bug and
discuss the scope of any vulnerability along with potential
solutions.