Some checks failed
Periodic Merges (6h) / master → staging-nixos (push) Failing after 12m50s
Periodic Merges (6h) / master → staging-next (push) Failing after 12m54s
Periodic Merges (24h) / merge-base(master,staging) → haskell-updates (push) Failing after 11m54s
Periodic Merges (6h) / staging-next → staging (push) Failing after 12m13s
Periodic Merges (24h) / staging-next-25.05 → staging-25.05 (push) Failing after 13m24s
Periodic Merges (24h) / release-25.05 → staging-next-25.05 (push) Failing after 14m28s
30 lines
1.3 KiB
Diff
30 lines
1.3 KiB
Diff
From a3bc718a8a0325a53e0857668b8a0134d371794d Mon Sep 17 00:00:00 2001
|
|
From: Firstyear <william@blackhats.net.au>
|
|
Date: Sat, 16 Aug 2025 13:46:23 +1000
|
|
Subject: [PATCH] Fix account recover-disable edge case (#3796)
|
|
|
|
---
|
|
server/lib/src/idm/server.rs | 2 ++
|
|
1 file changed, 2 insertions(+)
|
|
|
|
diff --git a/server/lib/src/idm/server.rs b/server/lib/src/idm/server.rs
|
|
index 0fc6d78787..51bfbf6705 100644
|
|
--- a/server/lib/src/idm/server.rs
|
|
+++ b/server/lib/src/idm/server.rs
|
|
@@ -1900,6 +1900,7 @@ impl IdmServerProxyWriteTransaction<'_> {
|
|
let modlist = ModifyList::new_list(vec![
|
|
// Ensure the account is valid from *now*, and that the expiry is unset.
|
|
m_purge(Attribute::AccountExpire),
|
|
+ m_purge(Attribute::AccountValidFrom),
|
|
Modify::Present(Attribute::AccountValidFrom, v_valid_from),
|
|
// We need to remove other credentials too.
|
|
m_purge(Attribute::PassKeys),
|
|
@@ -1934,6 +1935,7 @@ impl IdmServerProxyWriteTransaction<'_> {
|
|
let modlist = ModifyList::new_list(vec![
|
|
// Ensure that the account has no validity, and the expiry is now.
|
|
m_purge(Attribute::AccountValidFrom),
|
|
+ m_purge(Attribute::AccountExpire),
|
|
Modify::Present(Attribute::AccountExpire, v_expire),
|
|
]);
|
|
|