Courseiva

CEH Network and Web Application Attacks Practice Question

A penetration tester is assigned to test a web application that uses a JSON Web Token (JWT) for session management. The tester captures the token and notices it is signed with the HS256 algorithm. After several attempts to crack the signing key offline, the tester modifies the token's payload to elevate privileges and changes the 'alg' header value to 'none'. When the modified token is sent to the server, the application accepts it and grants administrative access. Which vulnerability has the tester exploited?

⚠ Common exam trap

The trap here is assuming that any JWT manipulation is an algorithm confusion attack, but the specific use of 'none' is a distinct flaw.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

✓

JWT 'none' algorithm vulnerability

The scenario describes modifying the JWT header to set the algorithm to 'none' and removing the signature, which the server accepts. This is a classic 'none' algorithm vulnerability where the server does not enforce a secure signing algorithm. The other options describe different JWT issues that do not match the observed behavior of accepting an unsigned token.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • ✓

    JWT 'none' algorithm vulnerability

    Why this is correct

    The tester changed the 'alg' header to 'none' and the server accepted the token without a signature. This exploits a misconfiguration where the server trusts the 'alg' header and does not enforce a secure algorithm, allowing unsigned tokens. This is a specific JWT vulnerability often called the 'none' algorithm attack, which directly matches the scenario.

  • ✗

    JWT algorithm confusion attack

    Why it's wrong here

    Algorithm confusion typically involves switching from an asymmetric algorithm like RS256 to a symmetric one like HS256, using the public key as the HMAC secret. In this scenario, the tester changed the algorithm to 'none', which is a different flaw where the server fails to enforce signature verification. This is not a confusion between RS256 and HS256, so this option does not match the observed behavior.

  • ✗

    JWT weak signing key

    Why it's wrong here

    A weak signing key would allow the tester to crack the secret and forge a valid token, but here the tester did not successfully crack the key; instead, the token was modified to remove the signature. The acceptance of an unsigned token indicates a failure to validate the algorithm, not a weak key. Thus, this option does not explain the successful privilege escalation.

  • ✗

    JWT token replay attack

    Why it's wrong here

    A replay attack involves capturing a valid token and reusing it later, but the tester here modified the token's payload and header. The server accepted the altered token, which is not a replay of a legitimate token. Therefore, this option is incorrect because the attack involved tampering, not replaying an unchanged token.

About these practice questions

This CEH question is part of Courseiva's 913-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written and reviewed by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

Last reviewed September 2026 · checked against the official EC-Council exam blueprint

This CEH practice question is part of Courseiva's free EC-Council certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the CEH exam.