-
Notifications
You must be signed in to change notification settings - Fork 60
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(repo): add stricter headers to network requests Refs BFE-449 #300
base: v2
Are you sure you want to change the base?
Conversation
The latest updates on your projects. Learn more about Vercel for Git ↗︎
6 Skipped Deployments
|
c778007
to
dcd5729
Compare
Nextjs injected scripts with nonce: https://nextjs.org/docs/pages/building-your-application/configuring/content-security-policy Next-Themes script: pacocoursey/next-themes#36 Decided to keep inline-styles just because then we would need stylesheets or tailwind exclusive for all styles we use |
9c0917d
to
da54ca5
Compare
da54ca5
to
830d9ea
Compare
830d9ea
to
c6da0cc
Compare
c6da0cc
to
efb6fc1
Compare
a03f776
to
92c7831
Compare
1a668a1
to
09abc02
Compare
apps/honey/src/middleware.ts
Outdated
}; | ||
font-src 'self' https://cdn.jsdelivr.net/npm/@fontsource/; | ||
style-src 'self' 'unsafe-inline'; | ||
img-src 'self' data: https://res.cloudinary.com/duv0g402y/ https://raw.githubusercontent.com/berachain/default-lists/ https://assets.coingecko.com/coins/images/ https://iconic.dynamic-static-assets.com/; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@bearpong they recommended adding specific connections so i've done that here.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGMT, let's slightly refactor some parts:
- read env variables to whitelist script-src and other csp headers
- create a shared file for any repeated code (image patterns and middlewares)
09abc02
to
c101fa3
Compare
So I've added headers in three different places.