Skip to content
Misconfiguration Disclosed report Beginner

CSP "script-src" includes "unsafe-inline" in https://gratipay.com

The Content-Security-Policy header for gratipay.com includes 'unsafe-inline' in the script-src directive, which permits inline scripts and event handlers. This weakens the CSP's protection against cross-site scripting, though the report notes it does not result in an immediate threat.

d4rk_g1rl Follow

Originally disclosed on HackerOne

  • Disclosed after 48 days

#SUMMARY:

Related Report: #225833

Gratipay is using unsafe-inline in script-src csp headers which allows the use of inline resources, such as inline <script> elements, javascript: URLs, inline event handlers, and inline <style> elements. Proof Of Concept

#By Using cURL:

  curl -I https://gratipay.com

The results See my attached photo.

Above CSP headers containing "script-src: header which have "unsafe-src" attribute in it.

This does not result in an immediate threat, but should be excluded, if possible, as a best practice. For further information, see https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/script-src

Regards,

Attachments

grati.png
grati.png From the original on HackerOne

The original report as published on HackerOne, by d4rk_g1rl. Images and videos are our own copies; raw HTML is shown as text. View it on HackerOne.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

How it worked

Root cause

The CSP script-src directive was configured with 'unsafe-inline', which permits inline scripts and event handlers.

Impact

The weakened CSP could make cross-site scripting easier to exploit, but the report states this does not result in an immediate threat.

What the attacker needed

None

Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.

Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.

A Content-Security-Policy (CSP) is a browser rule that tells the page which sources of scripts are allowed. When 'unsafe-inline' is included, the browser also allows scripts written directly inside the page, which makes it easier for an attacker who can inject HTML to run their own code. This report only points out that the rule is weaker than it could be; it does not show an actual attack.

What is Misconfiguration?

Settings left unsafe: exposed panels, open storage buckets, debug modes, default credentials.

More by d4rk_g1rl

View all

5 more disclosed reports, best first.

More from Gratipay

View all

The newest disclosed reports for this program.

Similar reports

View all

Same bug class and techniques, clearest first.

Security misconfiguration

The lesson behind this report.

Settings left unsafe: exposed panels, open storage buckets, debug modes, default credentials.