CSP CSP CSP

This commit is contained in:
Julien Palard 2023-04-07 22:56:27 +02:00
parent a90a2b7d43
commit b5aff22409
Signed by: mdk
GPG Key ID: 0EFC1AC1006886F8
2 changed files with 5 additions and 3 deletions

View File

@ -66,8 +66,7 @@
index index.html;
add_header Reporting-Endpoints xmpp="https://http-to-xmpp.afpy.org";
add_header Report-To '{"group": "xmpp", "max_age": 86400, "endpoints": [{"url": "https://http-to-xmpp.afpy.org"}]}';
add_header Content-Security-Policy-Report-Only "default-src 'none'; img-src 'self'; style-src 'self'; script-src 'self'; frame-ancestors 'self'; report-uri https://http-to-xmpp.afpy.org; report-to xmpp";
# add_header Content-Security-Policy-Report-Only "default-src 'none'; img-src 'self'; style-src 'self'; script-src 'self'; frame-ancestors 'self'; frame-src https://www.helloasso.com https://web.libera.chat report-uri https://http-to-xmpp.afpy.org; report-to xmpp";
add_header Content-Security-Policy "default-src 'none'; img-src 'self'; style-src 'self'; script-src 'self'; frame-ancestors 'self'; frame-src https://www.helloasso.com https://web.libera.chat; report-uri https://http-to-xmpp.afpy.org; report-to xmpp";
add_header X-Content-Type-Options "nosniff";
location /discord

View File

@ -26,10 +26,13 @@
changed_when: False
- name: Install http-to-xmpp
notify: restart gate
become: true
become_user: "{{ user }}"
pip:
name: [http-to-xmpp, pytz]
name:
- "http-to-xmpp>=0.2"
- pytz
virtualenv_command: /usr/bin/python3 -m venv
virtualenv: "{{ home }}/venv/"