django-security icon indicating copy to clipboard operation
django-security copied to clipboard

Support for nonce-<base64-value>

Open daniel5gh opened this issue 4 years ago • 1 comments

Hi, I've created a subclass of ContentSecurityPolicyMiddleware and an accompanying template context processor so I can do:

<script type="text/javascript" nonce="{{ csp_nonce }}">
</script>

Is there any interest in this? If so I can make a PR.

Thanks!

daniel5gh avatar May 19 '20 22:05 daniel5gh

@daniel5gh Yes it would be useful. Also see the django-csp library by mozilla for any more ideas you might want to implement.

9mido avatar Nov 06 '20 02:11 9mido