File skip_internal_large_mails.diff of Package roundcubemail-plugin-authres_status
--- a/authres_status.php 2025-03-11 15:14:42.064683177 +0100
+++ b/authres_status.php 2025-03-11 15:14:48.328113600 +0100
@@ -479,7 +479,12 @@
}
try {
- $dkimVerify = new DKIM_Verify($rcmail->storage->get_raw_body($uid));
+ $body = $rcmail->storage->get_raw_body($uid);
+ if (strlen($body) > 10*1024*1024) {
+ throw new Exception("Large body, skip tests");
+ } else {
+ $dkimVerify = new DKIM_Verify($body);
+ }
$results = $dkimVerify->validate();
} catch(Exception $e) {
$results = array();