Skip to content
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

Propose check to detect misconfiguration for CORS credentials requested. #207

Merged
merged 1 commit into from
May 13, 2024

Conversation

righettod
Copy link
Contributor

Description

This PR propose a bcheck to detect invalid CORS configuration for credentialed requests.

Indeed, the server must not specify the * wildcard for the Access-Control-Allow-Origin response-header value, but must instead specify an explicit origin.

Source: https://developer.mozilla.org/en-US/docs/Web/HTTP/CORS#requests_with_credentials

File was validated with the latest version of the checker:

image

BCheck Contributions

  • BCheck compiles and executes as expected
  • BCheck contains appropriate metadata (name, version, author, description and appropriate tags)
  • Only .bcheck files have been added or modified
  • BCheck is in the appropriate folder
  • PR contains single or limited number of BChecks (Multiple PRs are preferred)
  • BCheck attempts to minimize false positives

Thanks in advance 😃

@Hannah-PortSwigger
Copy link
Contributor

Thank you for your submission! We're in the process of reviewing your BCheck, and should either merge this or provide you with some feedback soon.

If there's anything else we can help with in the meantime, please let us know.

@righettod
Copy link
Contributor Author

Hi @Hannah-PortSwigger

Thanks a lot for the feedback 😃

Have a nice day.

Copy link
Collaborator

@PortSwiggerWiener PortSwiggerWiener left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Many thanks for your submission.

Looks good 👍

@righettod
Copy link
Contributor Author

You are welcome 😃

Thanks a lot for the review and for this feature ❤️

Copy link
Contributor

@Hannah-PortSwigger Hannah-PortSwigger left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks good! 👍

@Hannah-PortSwigger Hannah-PortSwigger merged commit e32801d into PortSwigger:main May 13, 2024
2 checks passed
@righettod righettod deleted the add_cors branch May 13, 2024 08:48
@righettod
Copy link
Contributor Author

Thanks a lot ❤️

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

Successfully merging this pull request may close these issues.

3 participants