LWN.net Logo

LCA: CSP for cross-site scripting protection

LCA: CSP for cross-site scripting protection

Posted Feb 11, 2013 19:45 UTC (Mon) by GregMartyn (subscriber, #52300)
Parent article: LCA: CSP for cross-site scripting protection

I think I have a correction to the article:

From my testing on Chrome v25, turning on reporting doesn't necessarily disable enforcement of CSP.

There are two possible http headers you can use (in addition to the vendor-prefixed versions): "Content-Security-Policy", and "Content-Security-Policy-Report-Only". Those are pretty self-explanatory. However there is also a "report-uri" Content-Security-Policy directive, which notifies the administrator of errors while still enforcing the CSP.


(Log in to post comments)

Copyright © 2013, Eklektix, Inc.
Comments and public postings are copyrighted by their creators.
Linux is a registered trademark of Linus Torvalds