Question 870
An API returns HTTP403 for a valid-looking token while HTTP401 occurs when no token is supplied. The incident evidence is: The client repeatedly reauthenticates but still cannot invoke a privileged API. Which targeted configuration or design change best addresses the failure?
Explanation
Correct Answer
The required correction is: Differentiate authentication failure (401) from an authenticated-but-forbidden permission decision (403). The underlying failure mechanism is: The identity is authenticated but lacks required authorization, rather than merely needing a new token. Verify success by carrying out this direct test: test the same endpoint with missing and underprivileged credentials and compare statuses.
Incorrect Answers
Treat HTTP204 No Content as a successful bodyless response when the API documents it would not address the need for differentiate authentication failure (401) from an authenticated-but-forbidden permission decision (403).
Interpreting HTTP201 Created and verifying the returned location/id identifies the created resource would not address the need for differentiate authentication failure (401) from an authenticated-but-forbidden permission decision (403).
Implementing the supported API token lifecycle including expiry detection and authorized token refresh would not address the need for differentiate authentication failure (401) from an authenticated-but-forbidden permission decision (403).






Implementing Cisco Enterprise Network Core Technologies (ENCOR) (350-401) Practice Tests