Generate SHAs for assets
ealmloff opened this issue · 0 comments
ealmloff commented
Specific Demand
Manganis should support generating SHAs for assets to support Subresource Integrity and prevent XSS attacks
Implement Suggestion
- Initially, we should expose an option to generate a SHA for an asset in the manifest so that CLIs can retrieve the SHA
- In the future we might be able to expose this as an option in the macro. We don't want to optimize assets in the macro because it runs in debug mode and the SHA should be generated from the optimized asset. We could cache a SHA or modify the SHA in the linked binary
Related to DioxusLabs/dioxus#1484