-
Notifications
You must be signed in to change notification settings - Fork 52
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
Blocked a frame with origin ... from accessing a cross-origin frame. #10
Comments
Hi, This should be working. Also in example folder you can find an example with Node.js/Express.js application and React application. Both are hosted on You shouldn't have any issues. |
I currently manage a project in which everyone has work with their own server (backend and frontend), the part of the backend worked excellent for me, but when using the react component, I see that a |
Sorry for late response, but you should not have any other configuration for |
Hello, I get the same issue, and my cors in the backend are correctly set... however the problem seems to come from the frontend that can not be able to get data from a popup without the same origine (like twitter.com). Did you found a workaround ? |
Hi @Veldars, I haven't manage to reproduce this issue. Do you use latest version of library? What is the value for I just need more information about the issue. |
Ok, thanks for your quick answer. Yes I download the last version of the library.
I have removed the credential parameter because you do not use it in your examples. Thanks |
I modified the component to use the callback offered by tweet, since it was impossible to obtain the token directly to authenticate |
Thanks, I did it too, but I'd like to understand how it could work without modification... |
I think it's because of some change that twitter made in its way of authenticating |
One question how do you end on different domain? Because, popup should go back to application. So I am creating popup from http://localhost:3000 and after authentication in popup will be opened http://localhost:3000/#callback? This is same host. What is your configuration for callback URL on Twitter application? |
@josejaguirre, I'm experiencing the same issue, could you please elaborate a little bit on a workaround for it? |
@sherlaimov hi! sure. I used the process where the application redirects to a twitter login and then returns to the application using the callback I hope it serves you. I was using node for that, i used https://github.com/drudge/passport-twitter-token library. The steps you took were the following: 1.- Node Backend Use the library and create custom url for get request token from twitter link (https://api.twitter.com/oauth/request_token) |
@josejaguirre thank you for you response, I also use NodeJS, in fact I tried following through @ivanvs's tutorial on implementing Twitter Authorization with React, however, I'm using KoaJS and had to use the oAuth module to authorize my 'node-fetch' requests - all seem to be working just fine, except for the frontend/react part. Can you please explain what kind of customized link should be used in My react app is running on port 3000, could the port difference be the reason causing the CORS issue? |
@ivanvs you are right, it is working now, thank you. It's clearly my gap in knowledge of what CORS really is. |
Hey Guys i write a react componet to login to OPENID but have a error : Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource. Origin 'null' is therefore not allowed access. If an opaque response serves your needs, set the request's mode to 'no-cors' to fetch the resource with CORS disabled. i try set header : const customHeader = {}; |
same issue +1 |
Hello, I think the library is great for managing twitter login, but I have a problem, when I want to use the component to make the login, I get the following error
Error: Blocked a frame with origin" http: // localhost: 3000 " from accessing to cross-origin frame. In my specific case I am using my
localhost` to be able to use proof of concept, and I enabled the cors, but I can not make it work. Is there any indication on this? or I'm doing something wrong when using the libraryThe text was updated successfully, but these errors were encountered: