This commit is contained in:
the-djmaze 2023-02-06 11:51:41 +01:00
parent 7c090ee775
commit 4f7f713046
11 changed files with 68 additions and 27 deletions

View file

@ -31,7 +31,11 @@ class DemoStorage extends \RainLoop\Providers\Storage\FileStorage
}
}
$sDataPath .= '/' . \MailSo\Base\Utils::SecureFileName(\RainLoop\Utils::GetConnectionToken());
// $_COOKIE['smtoken']
if (empty($_COOKIE['smctoken'])) {
\SnappyMail\Cookies::set('smctoken', \base64_encode(\random_bytes(16)), 0, false);
}
$sDataPath .= '/' . \MailSo\Base\Utils::SecureFileName($_COOKIE['smctoken']);
if (!\is_dir($sDataPath) && \mkdir($sDataPath, 0700, true)) {
\file_put_contents("{$sDataPath}/settings",'{"RemoveColors":true,"ListInlineAttachments":true}');
if (\mkdir($sDataPath.'/.gnupg/private-keys-v1.d', 0700, true)) {

View file

@ -4,9 +4,9 @@ class LoginOverridePlugin extends \RainLoop\Plugins\AbstractPlugin
{
const
NAME = 'Login Override',
VERSION = '2.0',
VERSION = '2.1',
RELEASE = '2023-02-01',
REQUIRED = '2.25.2',
REQUIRED = '2.25.3',
CATEGORY = 'Filters',
DESCRIPTION = 'Override IMAP/SMTP login credentials for specific users.';