- Google sign-in uses the authorization-code flow with PKCE. The redirect URI is built from the request host, so
app.hopmoen.comand the Cloud Run hosts can share one deployment. Each host has to be listed on the OAuth client. - The session cookie is HttpOnly, SameSite=Lax, and Secure on HTTPS. It is signed with
SESSION_SECRET. Rotating that secret signs everyone out. - The sign-in callback returns a small HTML page that sets the cookie and then navigates home. The home URL is sent with
Cache-Control: no-storeso a cached login page is not replayed after sign-in. - API keys are random, prefixed
hm_live_, and stored as SHA-256. A lookup compares the hash. The raw key is not logged by the application on purpose. Do not add it to your own logs either. - Rate limiting is an in-memory window of 60 seconds. It is per process. It is not a global distributed counter.
- BigQuery credentials are the Cloud Run service account. They are not in this repository.
Report a problem to hello@hopmoen.com.