Account takeover - improper validation of jwt signature (with regards to experiation date claim)
Some backend services did not properly validate JWT signatures, and the expiration date claim was mishandled. An attacker could bypass validation by setting the expiration date to a past Unix timestamp, enabling account takeover.
- Triaged in 6 days
- Fixed in 46 days
- Paid in 6 days
- Disclosed after 53 days
Summary by the program
Some backend services did not properly validate JWTs. As a result JWT validation could be bypassed by setting the expiration date claim to a unix timestamp in the past, and abusing this for account takeover.
Summary by the researcher
The expiration date claim of the JWT token was not properly handled. I was able to bypass validation by changing the expiration date to a date in the past.
What the report shows
The target is Linktree's admin surface, listed in the report as https://linktr.ee/admin*. The weakness is classified as improper authorisation, with a high severity and a CVSS score of 8.8. The report was disclosed on 26 December 2022.
The researcher's summary is short and direct: the expiration date claim of the JWT token was not properly handled, and validation could be bypassed by changing the expiration date to a date in the past.
The program's summary adds the scope of the problem. Some backend services did not properly validate JWTs. Because of that, JWT validation could be bypassed by setting the expiration date claim to a Unix timestamp in the past, and this could be abused for account takeover.
So the finding has two layers. The first is a validation flaw: a token whose exp claim points to a moment that has already passed should be rejected, but some services accepted it. The second is the consequence: with that bypass in place, the researcher could reach an account takeover. The report does not describe the individual requests, the token format, the endpoints involved, the accounts used, or the exact steps between the bypass and the takeover. It also does not state whether a bounty was paid or what the fix was.
Root cause
The root cause is that the affected backend services did not properly validate the expiration claim when checking JWTs. A JWT carries its claims inside the token, and exp is the standard claim for the expiry time, expressed as a Unix timestamp. A service that verifies the signature but skips or mishandles the exp check will accept a token long after it should have expired. The report frames this as improper validation of the JWT signature with regard to the expiration date claim.
Impact
The program states the outcome plainly: the bypass could be abused for account takeover. The program states the bypass could be abused for account takeover. The report does not detail which accounts were affected or what actions the takeover allowed, so the practical reach beyond that statement is not described.
How this kind of bug works
A JWT is a signed container of claims. The signature protects the claims from tampering, but the claims themselves still have to be interpreted correctly by the verifier. Expiry is one of those interpretations. The exp claim holds a NumericDate, a Unix timestamp, and the verifier is expected to compare it against the current time and reject the token once that moment has passed.
Bugs appear when a service checks the signature but not the claims, or checks them inconsistently. Common variants include a verifier that ignores exp entirely, one that compares it incorrectly (for example, treating seconds as milliseconds), one that only enforces expiry on some code paths, and one that trusts a claim from the token body without re-checking it server side. When several backend services share a token format, it is common for one of them to implement validation differently from the rest, which is exactly the kind of gap the program summary describes.
The defences are straightforward in principle: verify the signature with the expected algorithm and key, then enforce every claim that matters, including exp, and do so in every service that accepts the token. Short token lifetimes and server-side session state reduce the window in which a stale token is useful.
How to test for it
- Identify where the application issues and accepts JWTs: login responses, cookies, authorisation headers, and any API that consumes the token.
- Decode a token you legitimately hold and note its claims, especially
exp,iatand any role or identity claims. - Replay the token against each backend service you can reach, not just the main application, since validation may differ between them.
- Modify the
expclaim to a timestamp in the past, re-encode the token, and send it again. If the signature is checked, an unsigned or re-signed token will normally be rejected; the interesting case is a token the server still accepts despite the expired claim. - Compare behaviour across services: a token rejected by one endpoint but accepted by another is a strong signal of inconsistent validation.
- If an expired token is accepted, check what it still grants: read access to the account, state-changing actions, or administrative functions.
A positive result looks like a request that succeeds with a token whose exp is clearly in the past, where the same request with no token or a tampered signature fails. Common false positives include endpoints that do not require authentication at all, caches or gateways that serve a response before validation runs, and tokens that are rejected later in the request lifecycle after some work has already been done. Confirm the effect on a state-changing action, not just a read.
How it is fixed
Hunting notes
This class of bug tends to hide in services behind the main application: internal APIs, mobile backends, admin panels and microservices that share an authentication scheme but were built or maintained separately. Recon signals include multiple hosts or paths that accept the same token format, older API versions, and endpoints that respond differently to the same credentials. When you find a candidate, demonstrate impact with a concrete action, such as reading account data or performing a state change that the expired token should not permit, and document the exact request and response.
What happened, in plain words
Behind the public pages there is an admin area, and the report lists it as https://linktr.ee/admin*. The report was disclosed on 26 December 2022, is rated high severity with a CVSS score of 8.8, and is classified as improper authorisation.
To understand the bug you need one idea: the token. When you log in to a website, the server needs a way to recognise you on every later request. Instead of asking for your password each time, it hands your browser a small piece of text called a token, and the browser sends it back with each request. A JWT (JSON Web Token) is one common kind of token. It is like a stamped wristband at an event: the door staff do not ring the office to check who you are, they just look at the wristband and let you in. The stamp is a cryptographic signature, which is a value only the server can produce, so nobody can alter the wristband without the stamp breaking.
A JWT also carries small pieces of information called claims. One claim is the expiry time, written exp, stored as a Unix timestamp: a number counting seconds since 1 January 1970. Think of a day pass on a train: it says the date it stops being valid. The guard is supposed to read that date and refuse the pass afterwards.
The researcher's summary is short: the expiration date claim of the JWT token was not properly handled, and validation could be bypassed by changing the expiration date to a date in the past.
The program's summary widens the picture. Some backend services did not properly validate JWTs. As a result JWT validation could be bypassed by setting the expiration date claim to a unix timestamp in the past, and abusing this for account takeover.
So there are two layers. First, a validation flaw: a token whose exp points to a moment that has already passed should be refused, but some services accepted it. Second, the consequence: with that bypass, the researcher could reach an account takeover, meaning taking control of someone else's account.
The report does not describe the individual requests, the token format, the endpoints involved, the accounts used, or the exact steps between the bypass and the takeover. It also does not say whether a bounty was paid or what the fix was.
In general, how this kind of bug works
A JWT is a signed container of claims. The signature protects the claims from tampering, but the claims still have to be read correctly by whoever checks the token. Expiry is one of those readings. The exp claim holds a Unix timestamp, and the checker is expected to compare it with the current time and reject the token once that moment has passed.
Bugs appear when a service checks the signature but not the claims, or checks them inconsistently. Common variants include a checker that ignores exp entirely, one that compares it incorrectly (for example, treating seconds as milliseconds), one that only enforces expiry on some code paths, and one that trusts a claim from the token body without re-checking it on the server. When several backend services share a token format, it is common for one of them to implement validation differently from the rest, which is the kind of gap the program summary describes.
The defences are simple in principle: verify the signature with the expected algorithm and key, then enforce every claim that matters, including exp, in every service that accepts the token. Short token lifetimes and server-side session state reduce the window in which a stale token is useful.
How to test for it
- Identify where the application issues and accepts JWTs: login responses, cookies, authorisation headers, and any API that consumes the token.
- Decode a token you legitimately hold and note its claims, especially
exp,iatand any role or identity claims. - Replay the token against each backend service you can reach, not just the main application, since validation may differ between them.
- Modify the
expclaim to a timestamp in the past, re-encode the token, and send it again. If the signature is checked, an unsigned or re-signed token will normally be rejected; the interesting case is a token the server still accepts despite the expired claim. - Compare behaviour across services: a token rejected by one endpoint but accepted by another is a strong signal of inconsistent validation.
- If an expired token is accepted, check what it still grants: read access to the account, state-changing actions, or administrative functions.
A positive result looks like a request that succeeds with a token whose exp is clearly in the past, where the same request with no token or a tampered signature fails. Common false positives include endpoints that do not require authentication at all, caches or gateways that serve a response before validation runs, and tokens that are rejected later in the request lifecycle after some work has already been done. Confirm the effect on a state-changing action, not just a read.
How it is fixed
Hunting notes
This class of bug tends to hide in services behind the main application: internal APIs, mobile backends, admin panels and microservices that share an authentication scheme but were built or maintained separately. Recon signals include multiple hosts or paths that accept the same token format, older API versions, and endpoints that respond differently to the same credentials. When you find a candidate, demonstrate impact with a concrete action, such as reading account data or performing a state change that the expired token should not permit, and document the exact request and response.
Glossary
- Account takeover: gaining control of another person's account, for example by acting as its owner.
- Admin panel: the restricted part of a site used to manage it.
- API: an interface through which software talks to a server.
- Authorisation: the decision about what a logged-in user is allowed to do.
- Backend service: a program on the server side that handles part of the application's work.
- Claim: a piece of information carried inside a token, such as an identity or an expiry time.
- Cookie: a small piece of data a browser stores for a site and sends back with requests.
- CVSS: a standard scoring system for the severity of a vulnerability.
- Endpoint: a specific address on a server that accepts requests.
exp: the standard JWT claim holding the expiry time as a Unix timestamp.- False positive: a result that looks like a bug but is not one.
iat: the standard JWT claim holding the time the token was issued.- Improper authorisation: a flaw where the server does not correctly decide or enforce what a user may do.
- JWT (JSON Web Token): a signed token carrying claims, used to identify a user on later requests.
- Microservice: a small, separately built service that forms part of a larger application.
- NumericDate: the JWT format for a time, a Unix timestamp.
- Recon: the early stage of looking for a target's weak points.
- Request: a message a browser or tool sends to a server.
- Response: the message a server sends back.
- Signature: a cryptographic value that proves a token was produced by the server and not altered.
- State-changing action: an action that changes data, such as editing a profile, as opposed to just reading it.
- Token: a piece of text a server gives a client and expects back on later requests.
- Unix timestamp: the number of seconds since 1 January 1970, used to represent a moment in time.
- Validation: the server's check that a token is genuine and still usable.
- Vulnerability: a weakness in software that can be abused.