Added basic functionality for an HTML sandbox for relative safely rendering HTML attachments

Fixed #1150
This commit is contained in:
Jan Böhmer 2026-02-24 22:27:33 +01:00
parent a7a1026f9b
commit 63dd344c02
4 changed files with 161 additions and 26 deletions

View file

@ -58,4 +58,11 @@ class AttachmentsSettings
envVar: "bool:ATTACHMENT_DOWNLOAD_BY_DEFAULT", envVarMode: EnvVarMode::OVERWRITE
)]
public bool $downloadByDefault = false;
}
#[SettingsParameter(
label: new TM("settings.system.attachments.showHTMLAttachments"),
description: new TM("settings.system.attachments.showHTMLAttachments.help"),
envVar: "bool:ATTACHMENT_SHOW_HTML", envVarMode: EnvVarMode::OVERWRITE
)]
public bool $showHTMLAttachments = false;
}