Skip to content

Version 1.30.0

Choose a tag to compare

@umputun umputun released this 27 Nov 23:53
· 6 commits to master since this release
baaf770

New Features

  • provider.CustomHandlerOpt.AvatarSaver sets the avatar saver for one custom provider, for example to fetch a user-set picture URL without the access token #346 @paskal
  • Opts.AuthRoutePath: when set, the handler answers only its routes right under the mount as seen by the handler, and extra prefixes or escaped provider or action segments get 404 #346 @paskal
  • Verify message template fields {{.LinkToken}}, a separately signed token for a sign-in link, and {{.URL}} #339 @paskal

Behavior Changes

  • A configured Validator can reject a block that ClaimsUpd adds during refresh. Refreshed claims without a user are refused #345 @paskal
  • With a Validator configured, Validate runs twice on a successful refresh, and a custom TokenService.Set can no longer write a status or body #345 @paskal
  • The verify provider hashes a 40-hex address like any other. Such users get a new id. Existing sessions can keep renewing under the old id, and retiring their signing secret invalidates them #345 @paskal
  • A login without a user id is refused, and a custom MapUserFn should return an empty id when there is none #332 #335 #338 @paskal
  • /auth/user and /auth/status run the same checks as Auth and can refresh an expired cookie token #340 @paskal
  • A verify user name ending with : maps to the id of the actual address #340 @paskal

Bug Fixes

  • Opts.RefreshCache gives each request its own copy of the claims and refreshes expired entries; a shared attributes map could crash the process under concurrent writes #348
  • User.SliceAttr returns string lists read back from a token #347
  • The confirmation store keys verify links on their signed content, so a re-encoded signature cannot replay a used link. Keys in a shared VerifConfirmationStore change on upgrade #342
  • The replay marker of a used confirmation token is kept through its expiry second aeabc78
  • Custom confirmation tokens with other than three segments are hashed in full, so distinct tokens no longer collide b9378ee
  • Trace keeps the handler's Content-Type on a failed refresh #343
  • The oauth1 and oauth2 callbacks log the real parse error for user info that is not JSON #334
  • Provider fixes for Apple, Telegram, dev, Patreon and Discord, and aud and noava for oauth1 and Apple logins #340 @paskal
  • klauspost/compress v1.20.5 for GO-2026-6865 #340 @paskal

Improvements

  • Valid HTML5 for the dev login form and the custom server page #333 @paskal
  • README, doc comments and example corrected against the code #336 #341 @paskal #344
  • README notes that v1 depends on golang-jwt/jwt v3, which has GO-2025-3553 with no fixed v3 release, and that v1 users should move to v2 #341 @paskal