Re:GitHub's post-CSP journey
by laurent123456 on Friday January 20, 2017 @06:36AM
(#13443079)
What I don't understand is how the image URL ends up in a non-closed img src attribute. They might be getting the URL from a third party:
But GitHub is the one opening and closing the tag, probably in some kind of template:
Which should result in this:
and not this:
Any idea why they are getting the latter?
[ Parent
| on HN ]
Yes, the attack assumes a content injection bug in GitHub.com. The attack is not using our own gravatar URL generation against us; it is the attacker crafting an arbitrary URL and using that URL inside of an arbitrary image tag. The reason for the attacker being "forced" to use a gravatar URL is that it was one of the very few third-party hosts we previously allowed by our CSP policy. So, the attack demonstrates how this previously allowed host could be used to exfiltrate sensitive content if/when an attacker found a way to inject arbitrary HTML into a page on GitHub.com.
Re:GitHub's post-CSP journey
by scrollaway on Friday January 20, 2017 @07:39AM
(#13443356)
They weren't getting the latter, they specifically went in there looking to mitigate what a theoretical content injection attack could do.
> In a relatively unique project, we asked Cure53 to assess what an attacker could do, assuming a content injection bug in GitHub.com