[control] Share and token fixes: settle the epoch before minting, mint in its own task so a dropped client frees its key, token checks off the async threads, CLI refuses to run as another user than the state dir's owner

This commit is contained in:
2026-11-07 19:20:05 +01:00
parent 43918943da
commit 7d3af00720
6 changed files with 102 additions and 13 deletions
+3
View File
@@ -248,6 +248,9 @@ impl Shares {
};
old.stopped_at.get_or_insert(now());
}
// Settle the epoch first (lost records, an overflowing deny list): a link minted
// below the epoch that is about to be published would be dead on arrival.
let _ = self.reconcile(&mut f);
let id = ShareId(random::<16>().map_err(|e| MintError::Store(e.to_string()))?);
let t = now();
let spec = LinkSpec {