Skip to content
Sharp

Authentication · interview question

How can a developer mitigate the risk of JWT replay attacks?

Multiple choiceHardchapter-17-curatedpremiumauthenticationjwt-signatures
Choose one answer
Answer and explanation

Correct answer

C. Implement token expiration and nonce.

Why

To mitigate replay attacks, developers can use a combination of short token expiration times and nonces (unique values for each request). This ensures that any intercepted tokens cannot be reused by an attacker.

Test yourself on Authentication

A free test with instant, explained results. No account needed.

Start free test
All Authentication questions →