components/python/django_openstack_auth/patches/01-set-test-cookie.patch
author Misaki Miyashita <Misaki.Miyashita@Oracle.COM>
Tue, 08 Dec 2015 14:36:41 -0800
changeset 5171 4e8b3c0ea78c
parent 4517 61dba4b40cd4
child 6781 0692a9a0923c
permissions -rw-r--r--
22307393 Upgrade OpenSSL version to 1.0.2e 22307570 problem in LIBRARY/OPENSSL 22307591 problem in LIBRARY/OPENSSL 22307596 problem in LIBRARY/OPENSSL 22307601 problem in LIBRARY/OPENSSL 22317607 problem in LIBRARY/OPENSSL

In-house patch to fix authenticaton 'failing' because of lack of cookie
support simply because the cookie was never set. This patch is unlikely
to be unsuitable for upstream, and should be removed when Django is
updated to 1.6.11 or greater, as the problem disappears with that
version.

--- django_openstack_auth-1.1.9/openstack_auth/forms.py.orig	2015-06-19 15:03:16.425066412 -0700
+++ django_openstack_auth-1.1.9/openstack_auth/forms.py	2015-06-19 15:05:16.267455199 -0700
@@ -71,6 +71,7 @@
         elif len(self.fields['region'].choices) > 1:
             self.fields['region'].initial = self.request.COOKIES.get(
                 'login_region')
+        self.request.session.set_test_cookie()

     @staticmethod
     def get_region_choices():