bak
This commit is contained in:
1 parent
5aa3abc860
commit
5f9db690a4
24 files changed
+1447
-597
No files matched your search
@@ -18,6 +18,9 @@ class CalDavSync
|
||||
|
||||
private function getEncKey(): string
|
||||
{
|
||||
$vaultKey = $this->db->query("SELECT value FROM settings WHERE key = 'vault_key'")->fetchColumn();
|
||||
if ($vaultKey) return substr(hash('sha256', $vaultKey), 0, 32);
|
||||
// Fallback: old method (password hash) for migration
|
||||
$hash = $this->db->query("SELECT value FROM settings WHERE key = 'password_hash'")->fetchColumn();
|
||||
return substr(hash('sha256', $hash ?: 'hyprcrd-default-key'), 0, 32);
|
||||
}
|
||||
|
||||
Reference in new issue
Block a user