RequestPolicy/requestpolicy — Issue #176: redirect notification is not shown sometimes
Author: jsamuel
Created: 2011-12-22 05:57:20+00:00
State: open
Labels: extension

Sometimes the redirect notification is not shown. My hunch is that this is because the URL whose response includes a Location header was cached and the later visit to the URL causes the cached page to be shown. As the cached page is shown and the URL is not re-requested, the Location header isn't seen again. Without the Location header causing a blocked redirect, !RequestPolicy doesn't show the notification.

Assuming this is the problem, here are a few ideas that may not work (just brainstorming):
* Find out if a page displayed from cache has header information stored with it which might include the Location header.
* If a page had a blocked header redirect and the content of the page that gets shown look like generic html content that webservers send along with a header redirect (in case a browser didn't follow the redirect, but generally users never see this content), then prevent this page from being cached if Firefox would not normally cache the page. That is, maybe that content doesn't normally get cached if the redirect is successful but RP is causing Fx to cache it by not following the redirect.
* Add additional information to the cache entries of pages whose redirects were blocked that includes the redirect location, and have RP always check content displayed from cache to see if RP had previously stored redirect information in there. (I'd be concerned about unintentional security or privacy issues with storing additional information in the cache.)