summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorOwen Jacobson <owen@grimoire.ca>2025-12-09 23:07:52 -0500
committerOwen Jacobson <owen@grimoire.ca>2025-12-17 15:29:30 -0500
commitd85a28ecb408a05e9efae41e7ce4f5a707417875 (patch)
treeecc2858a583fea5766072cad12f8e0f71b604f56
parent65155df8b56cd16d88dd4288bcdcf7cc9ae09eef (diff)
Small naming change to make the steps of key rotation easier to follow.
-rw-r--r--src/cli.rs2
-rw-r--r--src/push/handlers/subscribe/test.rs2
-rw-r--r--src/vapid/app.rs2
3 files changed, 3 insertions, 3 deletions
diff --git a/src/cli.rs b/src/cli.rs
index 5199e4c..36f3d31 100644
--- a/src/cli.rs
+++ b/src/cli.rs
@@ -108,7 +108,7 @@ impl Args {
None => self.serve(app).await?,
Some(Command::RotateVapidKey) => app
.vapid()
- .rotate_key()
+ .revoke_key()
.await
.fail("Failed to rotate VAPID key")?,
}
diff --git a/src/push/handlers/subscribe/test.rs b/src/push/handlers/subscribe/test.rs
index b72624d..1bc37a4 100644
--- a/src/push/handlers/subscribe/test.rs
+++ b/src/push/handlers/subscribe/test.rs
@@ -192,7 +192,7 @@ async fn rejects_stale_vapid_key() {
// Change the VAPID key.
app.vapid()
- .rotate_key()
+ .revoke_key()
.await
.expect("key rotation always succeeds");
app.vapid()
diff --git a/src/vapid/app.rs b/src/vapid/app.rs
index 9949aa5..e696c18 100644
--- a/src/vapid/app.rs
+++ b/src/vapid/app.rs
@@ -19,7 +19,7 @@ impl Vapid {
Self { db, events }
}
- pub async fn rotate_key(&self) -> Result<(), sqlx::Error> {
+ pub async fn revoke_key(&self) -> Result<(), sqlx::Error> {
let mut tx = self.db.begin().await?;
// This is called from a separate CLI utility (see `cli.rs`), and we _can't_ deliver events
// to active clients from another process, so don't do anything that would require us to