John
John

Reputation: 13720

Content Security Policy: The page’s settings blocked the loading of a resource at blob

Blob images aren't showing via JavaScript because of the Content Security Policy in Waterfox 56:

Content Security Policy: The page’s settings blocked the loading of a resource at blob:http://localhost/1e511fde-fb52-41fc-b7db-6b8b6cf64171 (“img-src http://localhost data:”).

My image CSP:

img-src \'self\' data:;

Self-answered, see below.

Upvotes: 1

Views: 2331

Answers (1)

John
John

Reputation: 13720

Adding blob: resolves the issue, only use a space for the array delimiter (and semi-colons for the key/value pair delimiters):

Before:

img-src \'self\' data:;

After:

img-src \'self\' blob: data:;

Upvotes: 2

Related Questions