From b68f2cc6e42bfe54bd346f8f4ab04751cf51263e Mon Sep 17 00:00:00 2001 From: Nick Gerakines Date: Sun, 13 Jul 2025 09:30:32 -0400 Subject: [PATCH] chore: Updating references to preview site. Signed-off-by: Nick Gerakines --- src/bin/smokesignal.rs | 4 +- src/http/handle_oauth_metadata.rs | 67 ------------------------------- static/manifest.webmanifest | 2 +- 3 files changed, 3 insertions(+), 70 deletions(-) delete mode 100644 src/http/handle_oauth_metadata.rs diff --git a/src/bin/smokesignal.rs b/src/bin/smokesignal.rs index ecb8c81..1217893 100644 --- a/src/bin/smokesignal.rs +++ b/src/bin/smokesignal.rs @@ -140,8 +140,8 @@ async fn main() -> Result<()> { "https://{}/logo-160x160x.png", config.external_base )), - tos_uri: Some("https://preview.smokesignal.events/terms-of-service".to_string()), - policy_uri: Some("https://preview.smokesignal.events/privacy-policy".to_string()), + tos_uri: Some("https://smokesignal.events/terms-of-service".to_string()), + policy_uri: Some("https://smokesignal.events/privacy-policy".to_string()), scope: Some("atproto transition:generic transition:email".to_string()), }; diff --git a/src/http/handle_oauth_metadata.rs b/src/http/handle_oauth_metadata.rs deleted file mode 100644 index 282a925..0000000 --- a/src/http/handle_oauth_metadata.rs +++ /dev/null @@ -1,67 +0,0 @@ -use anyhow::Result; -use axum::{extract::State, response::IntoResponse, Json}; -use serde::Serialize; - -use super::{context::WebContext, errors::WebError}; - -#[derive(Serialize)] -struct AuthMetadata { - client_id: String, - dpop_bound_access_tokens: bool, - application_type: &'static str, - redirect_uris: Vec, - client_uri: String, - grant_types: Vec<&'static str>, - response_types: Vec<&'static str>, - scope: &'static str, - client_name: &'static str, - token_endpoint_auth_method: &'static str, - jwks_uri: String, - logo_uri: String, - tos_uri: &'static str, - policy_uri: &'static str, - subject_type: &'static str, - token_endpoint_auth_signing_alg: &'static str, -} - -pub async fn handle_oauth_metadata( - State(web_context): State, -) -> Result { - tracing::warn!("handle_oauth_metadata"); - - let client_id = format!( - "https://{}/oauth/client-metadata.json", - web_context.config.external_base - ); - let redirect_uris = vec![format!( - "https://{}/oauth/callback", - web_context.config.external_base - )]; - let jwks_uri = format!( - "https://{}/.well-known/jwks.json", - web_context.config.external_base - ); - - let resp = AuthMetadata { - application_type: "web", - client_id, - client_name: "Smoke Signal", - client_uri: format!("https://{}", web_context.config.external_base), - dpop_bound_access_tokens: true, - grant_types: vec!["authorization_code", "refresh_token"], - jwks_uri, - logo_uri: format!( - "https://{}/logo-160x160x.png", - web_context.config.external_base - ), - policy_uri: "https://preview.smokesignal.events/privacy-policy", - redirect_uris, - response_types: vec!["code"], - scope: "atproto transition:generic transition:email", - token_endpoint_auth_method: "private_key_jwt", - token_endpoint_auth_signing_alg: "ES256", - subject_type: "public", - tos_uri: "https://preview.smokesignal.events/terms-of-service", - }; - Ok(Json(resp)) -} diff --git a/static/manifest.webmanifest b/static/manifest.webmanifest index c529364..e4319c9 100644 --- a/static/manifest.webmanifest +++ b/static/manifest.webmanifest @@ -1,7 +1,7 @@ { "name": "Smoke Signal", "short_name": "SmokeSignal", - "start_url": "https://preview.smokesignal.events/", + "start_url": "https://smokesignal.events/", "display": "browser", "description": "An event and RSVP management and discovery application.", "categories": [ -- 2.51.2