]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commit
Added CORS support to Neutron
authorMichael Krotscheck <krotscheck@gmail.com>
Mon, 19 Oct 2015 13:52:04 +0000 (06:52 -0700)
committerMichael Krotscheck <krotscheck@gmail.com>
Wed, 9 Dec 2015 13:53:59 +0000 (05:53 -0800)
commit7f65b06033afca20399305f285ff5e6d43c5131c
tree9d0699133180609374f36984e32fdd889f2e56c6
parentad26d26987c8a659dff34c2b60779e61d28f293f
Added CORS support to Neutron

This adds the CORS support middleware to Neutron, allowing a deployer
to optionally configure rules under which a javascript client may
break the single-origin policy and access the API directly.

For neutron, both the paste.ini and the direct-wrap method of
deploying the middleware were chosen, since neutron is in a state of
migration to pecan. Note that if someone deploys pecan-neutron behind
other middleware, any responses provided by that middleware will not
be CORS-enabled, as these responses would be returned before the
headers could be annotated. This results in a response not readable
by the user agent.

OpenStack CrossProject Spec:
   http://specs.openstack.org/openstack/openstack-specs/specs/cors-support.html
Oslo_Middleware Docs:
   http://docs.openstack.org/developer/oslo.middleware/cors.html
OpenStack Cloud Admin Guide:
   http://docs.openstack.org/admin-guide-cloud/cross_project_cors.html
DocImpact: Add link to CORS configuration in admin cloud guide.

Change-Id: I02acea6124d28370d92e7c94ca2d1d6c5c8937ac
etc/api-paste.ini
etc/oslo-config-generator/neutron.conf
neutron/pecan_wsgi/app.py