From 1fa398e99e4561d0191ac125cb7cb1281a80ecca Mon Sep 17 00:00:00 2001 From: atlas Date: Thu, 4 Jun 2026 16:43:53 +0200 Subject: [PATCH] fix: use correct tuwunel admin room command prefix for reset-password --- hive-c0re/src/matrix.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/hive-c0re/src/matrix.rs b/hive-c0re/src/matrix.rs index 2b99fa4d..0673f353 100644 --- a/hive-c0re/src/matrix.rs +++ b/hive-c0re/src/matrix.rs @@ -532,7 +532,7 @@ async fn admin_room_send_and_poll( } /// Reset a user's password via the Matrix admin room (`#admins:`). -/// Sends `reset-password @:` as @hive, polls for the bot's +/// Sends `!admin users reset-password @:` as @hive, polls for the bot's /// response containing the new password. /// /// Returns the new password; caller is responsible for persisting it. @@ -544,14 +544,14 @@ async fn admin_room_reset_password( ) -> Result { let room_id = discover_admin_room_id(client, admin_token, server_name).await?; let room_url = encode_room_id_for_url(&room_id); - let command = format!("reset-password @{localpart}:{server_name}"); + let command = format!("!admin users reset-password @{localpart}:{server_name}"); admin_room_send_and_poll(client, admin_token, server_name, &room_url, &command, extract_new_password) .await .with_context(|| { format!( "matrix: admin room reset-password for @{localpart}:{server_name}: \ no password response received within 15 seconds. \ - Verify the admin room accepts 'reset-password @user:server' commands." + Verify the admin room accepts '!admin users reset-password @user:server' commands." ) }) } @@ -841,7 +841,7 @@ pub async fn promote_user_to_admin( /// Reset a user's password via the Matrix admin room (`#admins:`). /// -/// Sends `reset-password @:` to the admin room as @hive, +/// Sends `!admin users reset-password @:` to the admin room as @hive, /// polls for the bot's response containing the new password, and persists /// it to the non-purgeable creds path so [`ensure_user_for`] can re-login /// on the next provisioning sweep.