Can a client use a refresh token that was issued to another client?
Refresh token redeemed only by the client it was issued toRFC 6749 §6MUSTRoles: authorization_server
Requirement as recorded in the ProtocolSoup registry
authenticate the client if client authentication is included and ensure that the refresh token was issued to the authenticated client, and
Read §6 in RFC 6749Self-test verdict
PassCommit 00bac3fEvaluated
This is ProtocolSoup's result against its own implementation at the commit shown. It is not a certification of ProtocolSoup or of any other product.
Captured from production
Captured Commit 00bac3f
Captured from the deployed ProtocolSoup at the commit shown. Every request and response is shown exactly as sent and received.
Passing exchange
Accepted, as requiredConformance client
The conformance client obtains tokens as demo-app and refreshes them authenticated as demo-app, the client the refresh token was issued to.
Requests from ProtocolSoup’s conformance client, which sends malformed messages on purpose. The hosted wallet never sends these.
1.POST https://protocolsoup.com/oauth2/token200 OK
TLS: TLS 1.3 · TLS_AES_128_GCM_SHA256 · h2
Request
POST /oauth2/token HTTP/2.0 Authorization: Basic ZGVtby1hcHA6OXh2TTdNYXZPSXYyc0xoODFBUnBLNHRabUJKV2ZVSnA= Content-Length: 689 Content-Type: application/x-www-form-urlencoded Host: protocolsoup.com User-Agent: ProtocolSoup-Conformance-Client/1 grant_type=refresh_token&refresh_token=eyJhbGciOiJSUzI1NiIsImtpZCI6InJzYS05YTJlNThlYzVjNjk3NGJmIiwidHlwIjoiSldUIn0.eyJjbGllbnRfaWQiOiJkZW1vLWFwcCIsImV4cCI6MTc5NzE2ODk1MiwiaWF0IjoxNzk2NTY0MTUyLCJpc3MiOiJodHRwczovL3Byb3RvY29sc291cC5jb20iLCJqdGkiOiJyZWZyZXNoLTdkNmFmM2ZlZWM3Zjc2YWQiLCJzY29wZSI6InByb2ZpbGUiLCJzdWIiOiJhbGljZSIsInR5cGUiOiJyZWZyZXNoIn0.YRrwH5tjeU2T8u_vJnwTgioh9WtFAzpsk0sGZFdZ8R-GRODLIjTls3Yh6vNierqZ_DoDGBjymPqb2iGO_imBwg6rh0y2ah42-AvgJ82Bb6AzSAR1wpwB11kB30oQnA9icVWZyHvYk5vsWYFje2UTMfWUlJ_skkou15rD3Wa6oEwTrZToCh8_7kz9zMle6SOH52Vw9RteL8viA3QIQK61O4Ox7aP1x9l68-a7cmtKY_B-NHuOoAIoyAHeECL3oCoYHDNq9h91Lu7nt1UuYqHA944CxqJMVHl_3ic3gmCyTHOEuBLdglsxm6_VsW2E9GEbHAZkui32aR2iDx_1r6vEww
Response
HTTP/2.0 200 OK Cache-Control: no-store Cf-Cache-Status: DYNAMIC Cf-Ray: a65bad25daf83cdb-MSP Content-Type: application/json Date: Sun, 06 Dec 2026 13:35:53 GMT Fly-Request-Id: 01M95S2WXKMHF4PX89J5XCCWVN-ord Nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800} Pragma: no-cache Referrer-Policy: strict-origin-when-cross-origin Report-To: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=9oLaZuf%2FKCrql8ul4o0KgBl4CfgdILNpNHRAd5eADDvah851W%2BFsCqCStxetyjVlyv9qLDyuikYNqOqduWT0hPfGqxQAQtgHZK6542p%2FohSV%2FcHHqppbUq48fkrNGUvtu6o%3D"}]} Server: cloudflare Server-Timing: cfCacheStatus;desc="DYNAMIC" Server-Timing: cfEdge;dur=3,cfOrigin;dur=200 Vary: Origin Vary: accept-encoding Via: 1.1 fly.io, 1.1 fly.io X-Content-Type-Options: nosniff X-Frame-Options: DENY X-Xss-Protection: 1; mode=block {"access_token":"eyJhbGciOiJSUzI1NiIsImtpZCI6InJzYS05YTJlNThlYzVjNjk3NGJmIiwidHlwIjoiYXQrand0In0.eyJhdWQiOiJodHRwczovL3Byb3RvY29sc291cC5jb20vb2F1dGgyL3Jlc291cmNlIiwiYmlydGhkYXRlIjoiMTk5MC0wMy0xMiIsImNsaWVudF9pZCI6ImRlbW8tYXBwIiwiZXhwIjoxNzk2NTY3NzUzLCJmYW1pbHlfbmFtZSI6IkpvaG5zb24iLCJnZW5kZXIiOiJmZW1hbGUiLCJnaXZlbl9uYW1lIjoiQWx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I6MTc5NzE2ODk1MywiaWF0IjoxNzk2NTY0MTUzLCJpc3MiOiJodHRwczovL3Byb3RvY29sc291cC5jb20iLCJqdGkiOiJyZWZyZXNoLTQ2NjAwNDA3YWUxZTg3YTkiLCJzY29wZSI6InByb2ZpbGUiLCJzdWIiOiJhbGljZSIsInR5cGUiOiJyZWZyZXNoIn0.nZTE3I_7PvGK-Vjn_ZCQx6KVyN7E3dVtC6zw8Rb2jtf9RgmeBOVYM9OHETFDDZE9zbDPAygmGPSgHM85_mb9SLchvpU-eBQ3tvSP8Y1pBF6ySqzwQk-AXaFuNlitQB_SiMMp0vTMA2Tv-ZibF_Umr-DOMFLV6IY_Njv9YLDSHNnqcfE5mUcqykLyJ_VexrJQhM1tGDQVJLvNwbzKkmLvbZ0RTpE5IzHJIIbITM4VAKz6VjU08yej8LRePle-hf8d9QUl2F8zCpNG85qJIP19u2eTIo0ShHKmkCCVG5CnfgsVrR2YGEGTJr7aNQtb45Vg8izG7Mjb96V6KZSwlxDiAg","scope":"profile"}
Failing exchange
Rejected, as requiredConformance client
The conformance client obtains tokens as public-app, then presents the refresh token as demo-app, authenticated over HTTP Basic with demo-app's real client password. The refresh token was not issued to the authenticated client, and it stays valid for the client it was issued to.
Requests from ProtocolSoup’s conformance client, which sends malformed messages on purpose. The hosted wallet never sends these.
1.POST https://protocolsoup.com/oauth2/token400 Bad Request
TLS: TLS 1.3 · TLS_AES_128_GCM_SHA256 · h2
Request
POST /oauth2/token HTTP/2.0 Authorization: Basic ZGVtby1hcHA6OXh2TTdNYXZPSXYyc0xoODFBUnBLNHRabUJKV2ZVSnA= Content-Length: 692 Content-Type: application/x-www-form-urlencoded Host: protocolsoup.com User-Agent: ProtocolSoup-Conformance-Client/1 grant_type=refresh_token&refresh_token=eyJhbGciOiJSUzI1NiIsImtpZCI6InJzYS05YTJlNThlYzVjNjk3NGJmIiwidHlwIjoiSldUIn0.eyJjbGllbnRfaWQiOiJwdWJsaWMtYXBwIiwiZXhwIjoxNzk3MTY4OTU4LCJpYXQiOjE3OTY1NjQxNTgsImlzcyI6Imh0dHBzOi8vcHJvdG9jb2xzb3VwLmNvbSIsImp0aSI6InJlZnJlc2gtNDVjZDRhMjQ5OGU0YjU4NSIsInNjb3BlIjoicHJvZmlsZSIsInN1YiI6ImFsaWNlIiwidHlwZSI6InJlZnJlc2gifQ.o1Ki6j-B7x37o7HcGvov5fa_cIVuDSZeqMN942iywqS4w_D2ajk5V47BDn9zARL-nZguoyGNutpgPQqDefGBT7wrBn3CcB0bWJ_hc3PYCi8AcDY6euD3LAnIq4eBqQ1iimFerzLM9LUNosQZwtWw4M4s-yvzNAE9en-o_fFNYzOcZmJUr7fTzV5voaMOxdnwfuJll0PHL0iPLLo3_q41rO8JZ7-UY-LqEFtLN1UIiaHVGpdtcdPgAvuwC4o4P_uBI7du3QETiV72RkFGiC7mxHKP3VzlAXt5aakEiCcyOgaht4qP59IrAmzILzoSMl0JfoGOUwmN39YRZ5TxFvexmA
Response
HTTP/2.0 400 Bad Request Cache-Control: no-store Cf-Cache-Status: DYNAMIC Cf-Ray: a65bad519fcc3cdb-MSP Content-Type: application/json Date: Sun, 06 Dec 2026 13:36:00 GMT Fly-Request-Id: 01M95S33S5D928W5ZTHZRTTS8W-ord Nel: {"report_to":"cf-nel","success_fraction":0.0,"max_age":604800} Pragma: no-cache Referrer-Policy: strict-origin-when-cross-origin Report-To: {"group":"cf-nel","max_age":604800,"endpoints":[{"url":"https://a.nel.cloudflare.com/report/v4?s=nph4RJijfCQ%2FISte0LMuU8UDu5KWCeufDIWPFlnIXNupqQPYHJdosaLFNy3ZbGKf2uO740txb8u8JTpWcyXfHsZdCcNd%2BuvoTFXpegtdGDYzz5aI0Gadf0GWF3AUW4iNijE%3D"}]} Server: cloudflare Server-Timing: cfCacheStatus;desc="DYNAMIC" Server-Timing: cfEdge;dur=3,cfOrigin;dur=223 Vary: Origin Vary: accept-encoding Via: 1.1 fly.io, 1.1 fly.io X-Content-Type-Options: nosniff X-Frame-Options: DENY X-Xss-Protection: 1; mode=block {"error":"invalid_grant","error_description":"client ID mismatch","error_uri":"https://datatracker.ietf.org/doc/html/rfc6749#section-5.2"}
Tests
- TestRefreshTokenIsBoundToTheClientItWasIssuedTo
./internal/protocols/oauth2
Pass
Implementation
Explainer
What this requires
No: a client cannot use a refresh token that was issued to another client. The token endpoint authenticates the client when authentication is included and then confirms that the refresh token in the request was issued to that client. The two parts belong together. Authentication establishes who is asking, and the binding check compares that with who the token belongs to.
For a public client there is no authentication to perform, and the comparison is made against the client_id in the request.
Why it exists
Many clients share one authorization server. Without the check, any registered client could redeem any refresh token it came across, and the access tokens it received would carry the scope a user granted to a different application. RFC 6749 Section 5.2 anticipates the case in its definition of invalid_grant, which covers a refresh token that "is invalid, expired, revoked, does not match the redirection URI used in the authorization request, or was issued to another client."
What non-compliance looks like
A refresh handler that validates the token and the client separately but never compares them. Both checks pass for client B presenting client A's token, and B gets tokens for A's grant.
At /oauth2/token the response is 400 with error invalid_grant and error_description client ID mismatch. The refresh token is left as it was. Another client's failed attempt does not rotate or revoke it, so the client it belongs to is unaffected.
How ProtocolSoup tests it
TestRefreshTokenIsBoundToTheClientItWasIssuedTo issues a refresh token to one confidential client and presents it as a second confidential client with that client's correct credentials, then as public-app. Both are invalid_grant. It also checks that a public client which includes a client_secret is invalid_client, since included authentication is always checked. The owning client then redeems the token, the test reads the new refresh token's record to confirm it is bound to the same client, and the second client is refused again with the rotated token.
The captured passing exchange is client-refreshes-its-own-token. The failing one, refresh-token-issued-to-another-client, has demo-app authenticate with its real password and present a refresh token issued to public-app.