target navigation · lesson 6 of 8 · sources checked 2026-11-20
authentication flows and the account boundary
This lesson shows how a login works, why a site puts its most expensive checks at the login, and what a device-bound web session changes.
status of this lesson: from a public sourcepurpose
A login is a strong decision point: the site links the visit to one account with a history. After the login, each request belongs to that account, and the site can compare each request with that history.
objectives
- Describe the steps of a login with a password and with single sign-on.
- Explain why a site puts its most expensive checks at the login.
- Identify the input of a risk-based login that a fingerprint replay cannot match.
- Select the mechanism that keeps a copied cookie from working on a different device.
new terms
- decision point
- The place where a detection product makes its verdict: edge, page script, widget, SDK, or server.
- identity
- The set of exit, transport, fingerprint, stored state, history, and account data that a site links to one visitor.
- fraud scorer
- A product that scores an identity and an action, and returns its verdict to the backend of the site.
- risk-based authentication
- A login decision that asks for a second factor when cookie, fingerprint, or IP history does not match.
- step-up
- A request for a second factor when a session input does not match the binding.
- fingerprint
- A set of values that a site collects from a client to identify or classify it.
- fingerprint replay
- The use of a copied browser fingerprint on a second device to look like a known device.
- Device Bound Session Credentials (DBSC)
- A browser mechanism that binds a web session to a private key in secure hardware of the device, for example a TPM.
how it works
Before a login, a site sees a visitor. After a login, it sees an account with a history. Thus the login links the identity of the visitor to the account, and the site puts its most expensive checks there. A fraud scorer can decide at this step.
the steps of a login
A login with a password has these steps:
- The client gets the login page and its form token.
- The client posts the credentials.
- The server sets a web session cookie and sends a redirect.
- Each later request carries the cookie.
A login with single sign-on adds an identity provider and more redirects. OAuth 2.0 lets a third-party application get limited access to an HTTP service RFC Editor, source 1.
OpenID Connect adds a sign-in on top of OAuth 2.0: the app learns which user signed in. With an authorization code, the code comes back as a query parameter of the redirect_uri. The tokens come from the token endpoint OpenID Foundation, source 2.
example A sign-in through an identity provider sends the browser to the provider, and then back to the redirect_uri with a code parameter. Each redirect is one more request that the site can score.
the risk-based login decision
A site can apply risk-based authentication. The decision reads inputs of the visit and compares them with the history of the account. When an input does not agree, the site asks for a second factor. This request is a step-up.
The decision can read these inputs:
- The IP history of the account. The decision can read it first.
- Browser features, for example the user agent and the fingerprint.
- A cookie that the site set on an earlier login.
estimate, not measured The weight of the earlier cookie as an input is an estimate, not a measured value.
A fingerprint replay can match the fingerprint input. But the replayed fingerprint does not change the IP history. Thus a login from an address that the account never used can still get a step-up.
In 2024, the authors of Browser Polygraph described a tool at a large financial company. It used coarse-grained fingerprints to assess if a browser was authentic, and it flagged suspicious web sessions IMC 2024 (author copy), source 3.
one-time links
A site can send a link with a one-time token, for example in a sign-in mail. The site accepts the token only one time.
A client can fetch each URL in a message before the user reads it. Then the client uses up the token, and the click of the human fails. A site can put the token in the body of a POST request. Then a fetch of the link alone does not use the token.
device-bound web sessions
A copied web session cookie works on a different device, unless the site binds the cookie to the device.
claim of a company Google documents Device Bound Session Credentials (DBSC) for Chrome. Chrome makes a key pair for the device at the login. When the device has secure hardware, for example a Trusted Platform Module (TPM), Chrome keeps the private key there. When a short-lived cookie expires, Chrome proves that it has the private key before it gets a new cookie Google (Chrome for Developers), source 4.
WebAuthn binds a login credential to an authenticator. Web Authentication Level 3 states that only pages of the relying party, the site that registered the credential, can use the credential W3C, source 5. For example, a page on a different site cannot use the credential of a bank site.
the account boundary
For a collector, an account adds cost and legal risk. It also gives the site a strong identity link. Each request after the login belongs to the account. A long signed-in web session also collects behavior data. One change of the exit IP inside it is a signal.
Thus a signed-in run keeps one sticky session from the login to the last request.
example A signed-in web session sends 40 requests from one address, and then one request from a new address. The site sees the change on the account, not only on the visit.
the two sides
| automation side | detection side |
|---|---|
| An account adds cost, legal risk, and a strong identity link. A long signed-in web session collects behavior data and the risk of an IP change. | The login is where a site spends its most expensive checks. A replayed fingerprint can match the fingerprint input, but the IP history input can still ask for a second factor. |
design decisions
| option | gain | cost | when it is correct |
|---|---|---|---|
| Collect only the public pages, with no account | No account, no identity link, and no login checks | The data behind the login stays out of scope. | When the data that you must have is on public pages |
| Use an account in your own lab | You can see each step of the login and its signals. | The lab is not the real site. | Tests of the login steps and of their detection |
| The site reads the IP history first | A replayed fingerprint does not pass. | Real users on a new network get a step-up. | Sites with account takeover risk |
| The site binds the web session to the device | A copied cookie stops working on a different device. | The browser and the device must have the mechanism. | Accounts of high value |
diagram
a risk-based login decision with three inputs, and the input that a fingerprint replay passes
failure modes
| problem | cause | correction |
|---|---|---|
| A sign-in link fails when the user clicks it. | A client fetched the link first and used up the one-time token. | Site side: put the token in the body of a POST request, not in the link alone. |
| A login with a known fingerprint gets a second factor. | The IP address is not in the history of the account. | Read the result as a decision of the site, not as a fault of the client. |
| A copied cookie works on a different device. | The site does not bind the web session to the device. | Site side: bind the web session to a device key, where the browser has the mechanism. |
| A signed-in run loses the account in the middle. | The exit IP changed inside the run. | Keep one sticky session for each signed-in run. |
| The login works in the lab and not on the real site. | The real site adds checks of the history of the account. | Test the mechanism in the lab only. Do not test a login on a real site. |
check questions
Describe the steps of a login with a password, and the part that single sign-on adds.
sample answer
The client gets the login page and its form token, and posts the credentials. The server sets a web session cookie and sends a redirect, and each later request carries the cookie. Single sign-on adds an identity provider and more redirects. The code comes back to the redirect URI, and the tokens come from the token endpoint.
Explain why a site puts its most expensive checks at the login.
sample answer
The login links the identity of the visitor to one account with a history. Each later request belongs to that account. Thus the site puts its most expensive checks at this step, and a fraud scorer can decide there.
A client replays a known fingerprint of an account from a new address. Which input of the login decision does it not match?
- The fingerprint
- The user agent
- The IP history of the account
answer
c. The IP history of the account
A fingerprint replay can match the fingerprint input. It does not change the IP history, thus the site still asks for a second factor.
Which mechanism keeps a copied web session cookie from working on a different device?
- Device Bound Session Credentials
- A one-time token in a sign-in link
- A sticky session
answer
a. Device Bound Session Credentials
The browser keeps a private key in secure hardware of the device. It must prove that it has the key before it gets a new short-lived cookie.
exercise
exercise Do this task on paper or in your own lab, with a synthetic sign-in page only. Do not send a request to a real site, and do not create an account on a real site.
- Write the requests of a sign-in mail link on your lab site: the mail, the link fetch, and the page.
- Add a client that fetches each link in the mail before the user.
- Write the result of the click of the user when the token is in the link.
- Change the design: the link opens a page with a button, and the button posts the token.
- Write the result of the click of the user after the change.
sample answer
The answer uses the synthetic lab site.
When the token is in the link, the fetch of the client uses up the token. The click of the user then fails, because the site accepts the token only one time. After the change, the fetch of the client only gets the page with the button. The token goes to the server only when the user presses the button. Thus the click of the user works.
sources
- RFC 6749: The OAuth 2.0 Authorization Framework, RFC Editor, standard, read 2026-11-20
- OpenID Connect Core 1.0, OpenID Foundation, standard, read 2026-11-20
- Browser Polygraph (IMC 2024, author copy), IMC 2024 (author copy), paper, read 2026-11-20
- Device Bound Session Credentials, Google (Chrome for Developers), documentation, read 2026-11-20
- Web Authentication Level 3 (Recommendation, 2026-08-25), W3C, standard, read 2026-11-20
- My model of a risk-based login decision, of its inputs, and of one-time links, 2026-11 (not public).