Skip to Content
UpdatesReleasesRelease v2.3.372

Release v2.3.372

Prepared: November 2, 2026 (draft, django-cfg backend and @djangocfg/api / @djangocfg/nextjs)

Subdomains are accepted automatically

For the registrable domain of each declared URL (site_url, extra_origins, API hosts, api_url) the package now adds .root to ALLOWED_HOSTS, a scheme-pinned CORS regex and https://*.root to CSRF_TRUSTED_ORIGINS. my., studio., preview hosts need no entry. IPs, localhost, single labels and shared-host suffixes (vercel.app) are never opened wide. Opt out with accept_subdomains = False. See Security.

Who acts: nobody. A project that listed subdomains in security_domains may delete them (W020 does not flag this yet). A project that hosts an untrusted subdomain on its own registrable domain sets accept_subdomains = False.

Single sign-on across subdomains

The generated @djangocfg/api client now stores the token pair in cookies on the registrable domain instead of localStorage. Signed in on my.example.com means signed in on example.com. Next.js server code reads the same session through @djangocfg/nextjs/auth. Details: Single sign-on across subdomains.

BeforeNow
tokens in localStorage (per origin)tokens in cookies, Domain= registrable domain
auth.setStorageMode('cookie') wrote host-only cookiescookie is the default and shared; setStorageMode('localStorage') opts out
SSR could not see the sessionserverAuthHeaders(), getServerAccessToken()
API key shared with the token backendAPI key always localStorage

An existing session is moved from localStorage to the cookies on first load, so nobody is signed out.

Who acts: every consumer regenerates the client (make generate / make gen-api) and bumps @djangocfg/api. Check one site on two subdomains (sign in on one, open the other). Apps that read cfg.auth.access_token from localStorage directly must switch to auth.getToken().

Last updated on