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

Resolve issue #118 CORS issues in IE and Edge #119

Closed

Conversation

Firesphere
Copy link

@Firesphere Firesphere commented Sep 14, 2017

This pull involves a work-around for IE and Edge browsers not being able to send CORS headers when the root domain is the same, despite CORS headers being required.

It's falling back to referer. This is a security risk, but less of a security risk than simply allowing all when there is a CORS requirement.

This resolves issue #118 which contains more information on how and what this PR resolves.

Copy link
Author

@Firesphere Firesphere left a comment

Choose a reason for hiding this comment

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

I can't request changes on my own, so comment it is.


/**
* IE and Edge are a bit weird, so we check CORS headers differently on the same domain
* despite CORS being enabled. This checks if our IE exception plays nice
Copy link
Author

Choose a reason for hiding this comment

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

It's the Edge exception, not IE

@@ -1634,6 +1634,21 @@ Once you have enabled CORS you can then control four new headers in the HTTP Res
Max-Age: 600
```

5. **CORS exception for Internet Explorer and Edge**

IE 11 and Edge fix. When CORS is enabled but we are on the same domain,
Copy link
Author

Choose a reason for hiding this comment

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

Needs an update as this is a copy-paste from the inline comment

@flamerohr
Copy link
Contributor

Closing, as this #132 fixes the same issue

Please re-open if I'm mistaken :)

@flamerohr flamerohr closed this Jan 25, 2018
unclecheese pushed a commit to unclecheese/silverstripe-graphql that referenced this pull request Jan 27, 2021
Fix remove JS env check, so debugging is possible without watching admin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants