السكربتات في المشاركات؟

ربما شيء على هذا المنوال للسماح بتشغيل نص برمجي في Discourse @merefield @supermathie؟

App.yml:
DISCOURSE_ALLOW_UNSAFE_HTML: true

  • volume:
    host: /var/discourse/shared/standalone/nginx_custom.conf
    guest: /etc/nginx/conf.d/custom.conf

تكوين Nginx لـ CSP:
add_header Content-Security-Policy “script-src ‘self’ ‘https://webadress.com’ ‘unsafe-inline’ ‘unsafe-eval’;”

أحاول إضافة تكوين Nginx ولكن كلاً من ‘unsafe-inline’ و https لن يظهرا في CSP عند التحقق باستخدام curl. يتم إضافة ‘unsafe-eval’ من خلال المسؤول.

تعديل: غير آمن