Re:Firefox and IE's "View source" can be spoofed to show any...
by JoachimSchipper on Thursday September 08, 2011 @04:57PM
(#2975635)
Note that re-downloading the source prevents this attack, but does not mean that the source you are looking at is what the page is actually running - just make the web server leave out the reference to evil.js the second time an IP address requests the page...
Re:Firefox and IE's "View source" can be spoofed to show any...
by cmelbye on Thursday September 08, 2011 @04:10PM
(#2975472)
I think that's correct about Chrome. If you want to see the "current" source, the Web Inspector is the way to go.
Re:Firefox and IE's "View source" can be spoofed to show any...
by knotty66 on Thursday September 08, 2011 @08:48PM
(#2976301)
I wondered if there is anything different about the second (view source) request that could be detected and a different response provided - but I don't think so after a quick look with WireShark.
Re:Firefox and IE's "View source" can be spoofed to show any...
by sesqu on Friday September 09, 2011 @01:11AM
(#2976922)
Well, you could set up a temporary client blacklist based on cookies or IP addresses.
Firefox and IE show the "current" source, which is liable to be replaced as shown by dave1010uk.
Type the following into the Chrome Dev Tools console, then the Firebug console:
Chrome shows boolean, firefox shows undefined.