The flaw is in the user verification path of app/Controller/AppController.php, which enforces TOTP enrollment for instances with Security.otp_required enabled. The original logic applied the redirect to the TOTP setup page only to ordinary browser requests; REST, AJAX, automation, and other machine-readable requests could not follow that redirect and therefore continued past the guard. Exploitation requires an authenticated user who has not enrolled in TOTP, is not covered by a role allowed to skip OTP, and is not using an API-key-authenticated identity. The initial fix added a ForbiddenException for AJAX requests; the follow-up fix removed the AJAX-only condition and applied the guard to every request that cannot follow the browser redirect while preserving the logged_by_authkey exemption. The available evidence does not define every custom request shape produced by individual deployments, but it explicitly identifies AJAX/XHR, REST API, .json, restSearch, and automation paths.