You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Authenticate to Django with JSON Web Tokens (JWTs) signed by Cloudflare Access. A Django reimplementation of https://developers.cloudflare.com/cloudflare-one/identity/authorization-cookie/validating-json/#python-example
2
+
3
+
To run the demo, export these environment variables
Configure Cloudflare Tunnel public hostname demodj.your-domain.tld to http://localhost:8001 or equivalent.
14
+
15
+
### TODO
16
+
* Better login page
17
+
* Django REST Framework (DRF) support
18
+
* Grant users view permission to all models
19
+
* (Re-) authenticating proxy for different-domain front-ends, like https://developers.cloudflare.com/cloudflare-one/identity/authorization-cookie/cors/#send-authentication-token-with-cloudflare-worker but
20
+
- Setting username so it can be logged by gunicorn
21
+
- Rewriting origin redirects
22
+
- Setting the XmlHttpRequest(?) header to avoid redirects to the sign-in page
23
+
- Will the original CF_Authorization cookie need to be copied, similar to X-Forwarded-For?
0 commit comments