Skip to content

Conversation

@octalmage
Copy link

I'm working on static site hosting using Swarm and I noticed not having these headers listed as allowed is causing CORS errors when using bee.js:

Access to XMLHttpRequest at 'https://swarm.o8.is/bzz' from origin 'http://localhost:3000' has been blocked by CORS policy: Request header field swarm-error-document is not allowed by Access-Control-Allow-Headers in preflight response.

I understand why some of the other headers might not be allowed, but I think these would make a lot of sense and would enable some cool workflows.

Thanks for your time!

@octalmage
Copy link
Author

So I ended up adding two additional headers. I think we should encourage users to use their own postage but to do that gateways need to allow the swarm-postage-stamp (for uploading signed chunks).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant