I have searched about this but could not find any workable solution.
I have a website like www.example.com and subdomains a.example.com and b.example.com. When I try to post a request from a.example.com to b.example.com I get the error of Referer checking failed.
I have following settings in a.example.com and b.example.com:
CSRF_COOKIE_DOMAIN = ".example.com"
But I am not able to make use of CSRF_COOKIE_DOMAIN
correctly.
Django 1.8 has strict referer checking for HTTPS. You cannot post from a.example.com to b.example.com with CSRF protection enabled in Django 1.8.
With Django 1.9 they added CSRF trusted origins.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With