Closed f-trivino closed 11 months ago
This would have to be double-checked, is anything really missing?
The form already contains {% csrf_token %}
:
https://github.com/freeipa/ipa-tuura/blob/8efb132b69b25c1f89f99028244310176426b5fb/src/ipa-tuura/creds/templates/creds/simple_pwd.html#L13C9-L13C25
and in settings.py we have MIDDLEWARE = [ ... , 'django.middleware.csrf.CsrfViewMiddleware', ...]
:
https://github.com/freeipa/ipa-tuura/blob/main/src/ipa-tuura/root/settings.py#L55
thanks @flo-renaud !!!, looks like changes are only needed in the keycloak plugin. @justin-stephenson will test and close this ticket if no issues.
Fix here https://github.com/justin-stephenson/scim-keycloak-user-storage-spi/pull/15 is working in my limited testing.
thank you @justin-stephenson , I'm closing this ticket.
Enable CSRF protection for the creds app, based on:
https://docs.djangoproject.com/en/1.8/ref/csrf/#how-it-works
Example from keycloak plugin: https://github.com/justin-stephenson/scim-keycloak-user-storage-spi/commit/5e201e59be9630ac0551b9d06509401d24740242