Hi,
Let's assume that allowAuthorized is 0, is configured to cache *.html, the dispatcher cache is initially empty, Permission Sensitive Caching is *not* enabled.
User requests Page A (/pagea.html). They are anonymous. The dispatcher looks and sees that the page is not cached so it goes and makes a request to AEM. AEM responds with a 200 status code. The dispatcher thus caches the page and returns it to the user.
User requests to Page B (/pageb.html). They are *still* anonymous. The dispatcher looks and sees that the page is not cached so it goes and makes a request to AEM. AEM responds with a 302 status code redirecting the user to the login page. The dispatcher doesn't cache redirects, so it just returns the 302 to the user.
User logs in by sending a POST request. The login works and they are redirected to Page B. The dispatcher will never cache responses to POST requests, so it just is a pass through here.
User now requests Page B. Their request contains a login-token cookie. The dispatcher sees this cookie and sends the request to AEM. AEM responds with a 200 status code (because the user can now see the page). Because the request had a login-token cookie, the dispatcher does not cache this response.
User (still logged in) now requests Page A. Because the request contains authorization, even though the page is in the dispatcher's cache, the cached page is not served directly and instead a request is made to AEM. AEM responds with a 200 status code. The dispatcher returns this response to the user; the cache is not touched (because the request has the login-token cookie).
IIOW - only responses to anonymous users are cached and authenticated users never get cached content.
HTH,
Justin