v0.2.2 — 2 Nov 2026
A security release for SSO auto-login, plus custom message headers for e-mail sent from stored code.
Security — an SSO handoff token is good for one deployment only
Who is affected: Supabase deployments that sign users in from the BuildPad platform (SSO auto-login). Upgrade recommended. This release changes the Supabase backend only.
On BuildPad Cloud every Supabase project holds the same BUILDPAD_SSO_SECRET,
and the handoff token did not say which project it was for. A token minted for
one project was therefore also accepted by another project’s Studio, until the
token expired.
The platform now names the project in the token’s aud claim: the origin of the
project’s Supabase address. POST /api/auth/sso accepts a token only when its
aud is the origin of the deployment’s own NEXT_PUBLIC_SUPABASE_URL:
- A token addressed to another deployment answers
401. - A token with no
audanswers401. - With
NEXT_PUBLIC_SUPABASE_URLunset, the endpoint answers500.
The other checks are unchanged: 10 requests per minute for each IP address, a token older than 5 minutes is refused, a token is single use, and the handoff is refused for a user with a verified MFA factor.
The platform already sends aud, and a Studio older than v0.2.2 ignores it, so
the two sides can update in either order. After the update, SSO works only when
NEXT_PUBLIC_SUPABASE_URL holds the same address the platform has for the
project. If SSO answers 401 after the update, compare the two. Password
sign-in is not affected. See
Environment Variables.
Added — custom message headers on e-mail from stored code
Who is affected: Extensions, cron jobs and custom services that send e-mail.
services.mail() accepts headers, which go to the mail transport as given:
await context.services.mail({
to: 'user@example.com',
subject: 'Weekly digest',
html: '<p>…</p>',
headers: {
'List-Unsubscribe': '<https://example.com/unsubscribe?t=abc>',
'List-Unsubscribe-Post': 'List-Unsubscribe=One-Click',
},
});Before this release the headers were dropped without an error.