sveetch / cookiecutter-bireli

A Cookiecutter template to produce a modern Django site project
https://cookiecutter-bireli.readthedocs.io/
MIT License
1 stars 0 forks source link

Improve default security configuration for production environment #54

Open sveetch opened 3 months ago

sveetch commented 3 months ago

Is your feature request related to a problem? Please describe.

We currently don't configure anything special related to security, we just let the default Django configuration and assume it is to the project maintainer to decide and implement about security

Describe the solution you'd like

We should enable the Django security middleware in the production settings.

It just needs some test for CMS edition interface and CKEditor because frontend can sometime rely on some request/response behaviors that may be blocked by some security settings (like iframe forbidding).

There is also some concerns about the settings not managed by the security middleware:

Describe alternatives you've considered

Just notify about the Security middleware in documentation so project maintainer is aware of it.

sveetch commented 1 month ago

Middleware documentation needs to be readed comprehensively by a sysadmin before so we are sure it works well on our infrastructure and so we can advise for some settings and provide some possible documentation.