Rename unsafe file extensions of attachments to prevent XSS and server side code injection.

This commit is contained in:
Jan Böhmer 2022-12-18 18:11:44 +01:00
parent 5ffd44466e
commit 14bbe3d6d6
2 changed files with 47 additions and 1 deletions

View file

@ -144,6 +144,7 @@
<i class="fas fa-fw fa-shield-alt"></i> {% trans %}attachment.secure{% endtrans %}
</span>
</h6>
{% endif %}
{% if attach.secure and not is_granted('show_private', attach) %}
{# Leave blank #}
@ -161,7 +162,7 @@
<i class="fas fa-exclamation-circle fa-fw"></i> {% trans %}attachment.file_not_found{% endtrans %}
</span>
</h6>
{% endif %}
{% endif %}
{% endif %}