From 6045e7a85406c527f15ef5c78982c7f44cbf4b73 Mon Sep 17 00:00:00 2001 From: Ian Jackson Date: Sat, 15 May 2021 17:20:09 +0100 Subject: [PATCH] bundles: Reset the access key on clear This invalidates the old urls for the old bundles. Signed-off-by: Ian Jackson --- src/bundles.rs | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/bundles.rs b/src/bundles.rs index fcb39f76..5aa3362e 100644 --- a/src/bundles.rs +++ b/src/bundles.rs @@ -967,9 +967,14 @@ impl InstanceBundles { } } + let new_asset_key = AssetUrlKey::new_random()?; + // Right, everything is at most NEARLY-ASENT, make them ABSENT self.bundles.clear(); + // Prevent old, removed, players from accessing any new bundles. + ig.asset_url_key = new_asset_key; + Ok::<_,IE>(()) })()?; } -- 2.30.2