OpenFB
OpenFB copied to clipboard
SECURITY WARNING: Please treat the URL above as you would your password.
I am getting blank page with following text and window is not closing in my phonegap app SECURITY WARNING: Please treat the URL above as you would your password. I already added inappbrowser plugin. Any help would be must appreciated :)
I am seeing this as well. Has facebook's URL for logging in changed?
My window does close and I am getting back the access token also. Login to facebook works but I was concerned about this warning. @upender-devulapally are you on iOS or Android?
In both OS I am getting the same
Seeing this in iOS as well. it only happens when I login then logout and then login again. The in app browser displays an all white page with success and then a second later the warning appears. I do not have any issues while testing in a browser. I'm clearing all the tokens on logout so I'm not sure why the behavior of 2nd login is different.
I am having the same issue
For Cordova, install the InAppBrowser! Works fine now..
I still got the problem even the inappbrowser already installed. anyone have already solve this?
- Make sure you added the inAppBrowser Plugin https://github.com/apache/cordova-plugin-inappbrowser/blob/master/doc/index.md
- Make sure you have the oaughtcallback.html file in your www/ directory and check the openfb.js file to see if the correct path to this html is correct.
I have tried all solutions on this thread and many others, none seem to help me. I am getting the Success Security Warning message on my android device. It works very well on my browser (I am using Visual Studio 2013 update 4).
I do have the following:
- InAppBowerser version 1.0.0, installed as a plugin
- On my FB Dev. Setting -> Basic I have: http://localhost:4437/
- My oauthcallback.html is in my root directory
- Om my FB Dev. Setting -> Advance I have: https://www.facebook.com/connect/login_success.html
Side Notes:
Initially I was getting "the redirect_uri is not supported", I fixed this by placing:
runningInCordova = true; right after this
document.addEventListener("deviceready", function () { runningInCordova = true; alert("runningInCordova"); }, false);
in the OpenFB.js file, since on my adroid device the above listener was not executing. This now gives me access to the FB login screen.
But after login in I get the Success Security Warning message. I have spent 3 days trying to resolved this issue. I have tried many, many things but nothing seems to works. I am sure there is a solution out there.
Is there a way to fix this?
Please help, Thank you in advance.
Louis
Compare your openfb.js file from mine... see if you find something https://github.com/eugenemaning/openfb.js/blob/master/openfb.js
What I found out on mine is that I have to do this to get it working:
rm plugins/ios.json ionic plugins add org.apache.cordova.inappbrowser
But then somehow another plugin stops working. Just happens for iOS.
Peter
On Mon, May 11, 2015 at 10:54 PM, Eugene Maning [email protected] wrote:
Compare your openfb.js file from mine... see if you find something https://github.com/eugenemaning/openfb.js/blob/master/openfb.js
— Reply to this email directly or view it on GitHub https://github.com/ccoenraets/OpenFB/issues/30#issuecomment-101140919.
@eugenemaning I have pasted your code to my openfb.js and I got the exact same result.
What I am thinking is that I got the wrong InAppBrowser, I have tried with the one that installs through the config.xml core plugin which is version 0.5.2 the I tried one that has version 1.0.0
Where did you get your InAppBrowser?
I don't know what else to try.
All I need is to verify the user's login and get her/his email address. It is allowing them to login, Successfully, but then I get that annoying Security Warning message.
Any other ideas?
I really appreciate any type of help, I've been at it too long.
Thank you, Louis
Hi Peter,
Thanks for answering, I am not using Ionic, I am using Angularjs, I don't know if that makes a difference. I am also only using Android for now.
Any other ideas would be greatly appreciated.
I am sorry for being a pest, but I can't find any solution for my issue. It seems to be a very easy solution, but I can't find it. I've spend many days on this already.
Please help me.
This is the https://github.com/apache/cordova-plugin-inappbrowser that I am using.
Hi Eugene,
I finally fixed my problem. The solution was very simple but hard to spot.
In my index.html page I had this:
instead of this:
Although cordova.js is int the /scripts/ folder, having script/ before cordova was causing the problem. Everything else in my app worked fine, even openFB worked in the browser, except that openFB was not working in my android device. After removing /script from the path everything works fine.
I hope this might help someone.
That was funny! What a headache that was. Glad you finally solved your issue. On Thu, May 14, 2015 at 2:06 AM Louis777 [email protected] wrote:
Hi Eugene,
I finally fixed my problem. The solution was very simple but hard to spot.
In my index.html page I had this:
instead of this:
Although cordova.js is int the /scripts/ folder, having script/ before cordova was causing the problem. Everything else in my app worked fine, even openFB worked in the browser, except that openFB was not working in my android device. After removing /script from the path everything works fine.
I hope this might help someone.
— Reply to this email directly or view it on GitHub https://github.com/ccoenraets/OpenFB/issues/30#issuecomment-101761595.
Yes, thank you.
Now I am running in to the following problem in the browser, when I go to login it's telling me:
//////////////////////////////////////////////// InAppBrowser Emulation It is like a browser, only it is all up in your app
URL:
https://www.facebook.com/dialog/oauth?client_id=123456789&redirect_uri=https://www.facebook.com/connect/login_success.html&response_type=token&scope=email
TARGET:
_blank OPTIONS:
"location=no" ///////////////////////////////////////////
Do you have any idea why this might be happening?
Android device is still working fine.
Thanks,
Anyone have an answer for this, i am seeing the exact same screen :(
Hi, can you check your facebook app to ensure you have added the "website" platform?
In Facebook Developers Console, go to your app then go to "Basic" section and under the section with App ID, click "Add Platform" and choose "website". You do not have to add any of the URLs since you're using cordova.
Also make sure that you have turned on OAuth Login in the "Advanced" section
This worked for me. Let me know if it works for you
hi.. i got the SECURITY WARNING: Please treat the URL above as you would your password. only on the ios device while in android in works like charm.. anybody face the same issue? i develop the app using ionic and run the app from ionic view.. do you guys know why this happens? your feedback much appreciate.. Thanks
Got the same issue on Android (Samsung Galaxy Tab 3 - on Android 4.2.2 JellyBean). Had to install and configure a whitelist for facebook;
#install the plugin cordova plugin add https://github.com/apache/cordova-plugin-whitelist.git
#Add whitelist(s) to the bottom of config.xml (before closing tag!). NOTE: Only use these values for testing;
<allow-navigation href="*" />
<access origin="*" />
<allow-intent href="*" />
#Test if it works with the above settings. If it does, you should lock this down a little.. I haven't tested this out yet, but I think all you'll need is;
<allow-navigation href="*://*.facebook.com/*" />
<allow-intent href="*://*.facebook.com/*" />
I'm having the same security issue, can anyone show the steps what you did in Facebook App as well as opneFB.js.
I've even set static: runningInCordova = true;
in openfb.js and also installed plugin name="cordova-plugin-inappbrowser"
in config.xml.
How to solve all of those issues, you need to include a link to cordova.js in your index, without a link cordovaisrunning will always be false and this cause the first problem "URL not supported", also the security warning caused for the same reason.
Hi guys,
Anyone finally found a solution to this issue ? I have spent all my day on it and I am still facing with this error ... I tried all your suggestions like change my version of cordova-plugin-inappbrowser, set runningInCordova variable to true, include cordova.js in my index.html ... But not successfully.
In more details, my cordova/ionic app works like a charm on my android device, on ionic serve too but I have this error on iOS simulator with iOS 9 and 8.4. I didn't try with older version of iOS but I don't think it will be better.
Any suggestions or solutions will be welcome !
Any solution for this issue? I didn't find the solution for "secure warning ....", @Louis777 can you explain your solution? I cant see the code in your comment.
Also needing a solution, doesn't work on Android at all, so far.
I have the same problem, android not working at all. I'm stuck at the Success Security Warning and the page does not return to the app.
Got the same problem on my virtual android device...
I fixed this issue to change this line :
loginWindow.addEventListener('loadstart', loginWindow_loadStartHandler);
by :
loginWindow.addEventListener('loadstop', loginWindow_loadStartHandler);
The callback of the listener was never called, maybe because the window was already loaded with the url before to create the listener to know if the window is loading.
So now, the listener check if the window is loaded and not loading.