Enable OAuth sign-in: register Google + Microsoft apps, set env (manual) #22
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Code is live (#21, deployed). The buttons appear on enter.html automatically once the server has credentials — nothing else to deploy. Two registrations + one env edit:
1. Google (free, ~5 min)
console.cloud.google.com → new project (e.g.
cairn-site) →Cairn; support email; authorized domainswisscairn.ch. Publish the app (stays in "production" — only openid/email scopes, no verification review needed).https://license.swisscairn.ch/v1/oauth/google/callback2. Microsoft (free, ~5 min)
entra.microsoft.com → App registrations → New registration:
/common).https://license.swisscairn.ch/v1/oauth/microsoft/callbackxms_edov(andemailif offered). Withoutxms_edov, work/school accounts are treated as unverified (nOAuth guard) and can't auto-create/link — personal Microsoft accounts work either way.3. VPS env
Append to
/etc/cairn-license/env:then
sudo systemctl restart cairn-license-server.4. Verify
curl -s https://license.swisscairn.ch/v1/oauth/providers→{"providers":["google","microsoft"]}oauth sign-in enabled providers=...at boot andoauth sign-in provider=... account=created|linked|existingper login.Notes: defaults
OAUTH_PUBLIC_ORIGIN=https://license.swisscairn.chandOAUTH_SITE_ORIGIN=https://www.swisscairn.chneed no env unless those move. OAuth-created accounts have no password; the normal reset-email flow sets one. Secrets live only in/etc/cairn-license/env— never in git.Parked 2026-08-24 at the Google consent screen — prerequisite missing.
The "Get started" wizard requires a user support email (shown publicly for consent concerns), and the dropdown only offers the signed-in Google account's own address or Google Groups that account owns/manages — free-text entry is not allowed. Neither exists yet:
swisscairn.chsupport address (e.g.support@swisscairn.ch, or reusesales@swisscairn.ch) on the mail side.Then resume at §1 of this issue (consent wizard → client → publish). Microsoft (§2) has no such prerequisite and could be done independently — its registration only wants redirect URI + secret.