• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

go-pkgz / auth / 43744940267
87%

Build:
DEFAULT BRANCH: master
Ran 15 Nov 2026 06:09PM UTC
Jobs 1
Files 25
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

15 Nov 2026 06:07PM UTC coverage: 87.046% (-0.05%) from 87.098%
43744940267

push

github

web-flow
Document linking an anonymous user after login (#328)

* Document linking an anonymous user after login

Apps that let users start anonymously want to move that data to the
account the user logs in with later. The library keeps no users, so this
is app code, and the obvious version, merging right after login, hands
the data to an attacker whose confirmation link the user opened. The
README now describes a flow with an explicit confirmation step, and an
example test runs it against the real handlers.

* Bind the linking destination to the provider chosen at start

A link started without an email address accepted any later login as the
destination, so an attacker's email confirmation link could receive the
data of a user who meant to link a Telegram or oauth account. The pending
record now keeps the provider, confirm refuses users of other providers,
and an email link requires the address. The README says that only email
binds a known identity and names the configurable JWT query and header.

* Take the nonce cookie Secure flag from Opts.SecureCookies

Behind a TLS-terminating proxy r.TLS is nil, so the nonce cookie went
out without Secure even when Opts.SecureCookies secured the JWT cookie,
and for a link without an address the nonce alone is enough to move the
data. The example now takes Secure from Opts.SecureCookies, like the
JWT cookie, and the attributes test checks it for both settings. The
README says the example tells the provider by the id prefix, which the
dev provider and custom providers may not set.

* Keep a linking record alive as long as the login it waits for

The pending record and the nonce cookie lived 10 minutes while the email
confirmation token is valid for 30, so a user who opened the letter
later could no longer reach the data under the anonymous id. A link with an address now lives 45
minutes, a link without one keeps 10, and the record and the cookie
take the lifetime from one value.

The provider names are constants shared w... (continued)

3407 of 3914 relevant lines covered (87.05%)

11.38 hits per line

Coverage Regressions

Lines Coverage ∆ File
2
88.36
-0.42% v2/provider/telegram.go
Jobs
ID Job ID Ran Files Coverage
1 43744940267.1 15 Nov 2026 06:09PM UTC 25
87.05
GitHub Action Run
Source Files on build 43744940267
  • Tree
  • List 25
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • 5a81102e on github
  • Prev Build on master (#43067092707)
  • Next Build on master (#43744940318)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc