What problem does it solve? Refresh tokens are vulnerable to interception and replay attacks. DPoP (Demonstrating Proof-of-Possession, RFC 9449) cryptographically binds refresh tokens to a client's private key, preventing attackers from reusing stolen tokens without access to that key. ## Core Features & Use Cases - Non-extractable Key Pair Generation: Create P-256 ECDSA key pairs with private keys locked in the cryptographic boundary (Secure Enclave, Android KeyStore, or sandbox memory). - DPoP Proof JWT Creation: Generate signed JWTs with claims binding the proof to HTTP method, target URI, authorization code, or access token. - Token Endpoint Integration: Handle Google OAuth 2.0 token refresh with automatic nonce challenge retry logic for RFC 9449 compliance. - Use Case: A single-page application proxies OAuth through a Backend-for-Frontend server. The BFF generates DPoP proofs for each token refresh request to Google's token endpoint, ensuring stolen refresh tokens cannot be reused even if a database is compromised. ## Quick Start Generate a DPoP key pair, create a DPoP Proof JWT bound to your authorization code and token endpoint URI, and attach it to your POST request to oauth2.googleapis.com/token in the DPoP header.