yearn / yearn-finance

🏦 yearn v2 web interface
https://yearn.finance
MIT License
167 stars 111 forks source link

feature: configure CORS/allow loading website as an iframe for gnosis safe apps #410

Closed mmv08 closed 3 years ago

mmv08 commented 3 years ago

Is your feature request related to a problem? Please describe. A follow up on: https://github.com/yearn/yearn-finance/pull/400 The Safe wallet needs to be able to access https://yearn.finance/manifest.json but it's currently not possible because CORS is not configured. The Wallet also loads the apps as an iframe but currently, the server doesn't allow to do that

Describe the solution you'd like

Additional context Screenshot 2021-08-09 at 09 37 04 Screenshot 2021-08-09 at 09 39 27

ghost commented 3 years ago

@mikheevm I've added the header you suggested to yearn.dev. Currently x-frame-options is in-tact. Does that need to change as well? If I remove x-frame-options does that mean anyone can load yearn.finance in an iframe? If so that is undesirable. I've reached out to you in discord, please @ me or ping me there so we can debug together when you get a moment. Thanks!

image

ghost commented 3 years ago

Marking this as resolved as @mikheevm has confirmed that this is working as expected now.