-
Notifications
You must be signed in to change notification settings - Fork 28
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
Updated CORS Headers (#7985) #8043
base: develop
Are you sure you want to change the base?
Conversation
Signed-off-by: ClementBouvierN <[email protected]>
📝 WalkthroughWalkthroughThe changes involve modifying the Suggested reviewers
Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media? 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
Documentation and Community
|
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.
Actionable comments posted: 0
🧹 Nitpick comments (2)
config/docker/nginx-cors-permissive.conf (2)
35-35
: Security improvement: Specified allowed CORS headers.Replacing the wildcard
'*'
with a specific list of allowed headers is a good security practice that aligns with the principle of least privilege. This restricts which headers can be included in cross-origin requests, reducing the attack surface.Consider also adding the
Content-Length
header to the allowed list, as it may be needed for certain API operations. While it's included in OPTIONS responses (line 46), clients might need to send it in actual requests.
45-45
: Consistent CORS header configuration throughout the file.The restricted header list has been consistently applied across all endpoints and request types. This ensures uniform security behavior throughout the application.
As a future enhancement, consider also restricting the other CORS headers that still use wildcards (
Access-Control-Allow-Methods
andAccess-Control-Allow-Origin
). Using specific values instead of wildcards would further improve security posture.Also applies to: 55-55, 91-91, 120-120, 138-138, 161-161, 198-198, 219-219, 237-237, 255-255
📜 Review details
Configuration used: .coderabbit.yaml
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (1)
config/docker/nginx-cors-permissive.conf
(11 hunks)
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: build
- GitHub Check: build
|
Nothing in release note