windows authentication and iOS7 - ios7

We are developing a web application in asp.net and HTML5 (+ offline feature) and we are using “Add to desktop” button to create the desktop application.
Before access main screen, we have a windows authentication screen, so people can connect using their domain credentials.
In safari, we have almost no problem. It's the expected behavior when we are online. For the offline mode, safari needs to keep an active tab with the website loaded to allow offline access to it, otherwise safari does not find website – even if it’s cached with cache manifest...
In the desktop application (using “Add to desktop” button), the authentication popup on the main page does not appears. When I trace the HTTP requests, I can see 2 requests with a return status of 401. When I look into the logs, safari sandbox throw an exception (twice tries then abort operation)... The screen remains blank.
any ideas anyone or any fix is planned to correct this problem ?
Thanks in advance for any advices.

It's a problem with iOS 7. Windows Authentication only works in "Private Mode" or in another browser such as Chrome or Puffin. However, there isn't a workaround currently available to save an app to the home screen. Here's a thread on the Apple forums about this same issue:
https://discussions.apple.com/thread/5327078?start=60&tstart=0

The new iOS 7.03 fixes this issue.

Related

Instant App link in SMS does not work

I have created an Instant App that works perfectly when I click its link in an email. When I send the same link in an SMS and click it, the default-url is displayed. I am using AS3.2 Canary 9. Has anyone seen the same thing?
This depends of the message app of your phone. Sometimes the message app have an internal web view to manage the urls. In this case the link is directly open in web browser.
If the link is open in the default browser, you should go in this browser app settings and check the links already set as manage by this browser. Or clear the cache of the browser. if it s still not working, go in :
Settings -> Google -> Instant app, then disable an enable it again.
if it s still not working, make it sure by rebooting the device.

Javascript Facebook sdk - captive portal on mobile devices

We are setting up a web app which serves as a wi-fi hotspot using coova chilli and the Javascript Facebook SDK.
The app has a "login with facebook" button that, once clicked, calls the FB.login() function, which opens a pop-up window where the user can insert his credentials and log in.
This solution is working correctly in desktop browsers but it's not working in mobile devices.
These are the problems I encountered:
Android device - When I connect to the wifi network, the system prompts a notification who says "Sign in to wifi network". Once clicked, the captive page opens up correctly. But when I click the fb login button, I am redirected to the url "http://m.facebook.com/v2.8/auth ..." which is correct, but then the windows freezes and I can see only a wsod.
IOS device - same as before, the cna triggers, the redirect to the fb login page works, but once I insert my credentials, the only thing I can see is a wsod.
Both issues can be bypassed by including apple.com, google.com and other domains used for auth in the hotspot walled garden, and then the user can log in to the network by using the device's browser - Safari or Chrome, it works - as pointed out in this discussion Facebook login on Apple CNA.
The thing is, we want to make it work on the "normal" workflow, that is, to make the app work correctly within the IOS captive network assistant and the Android "sign in to wi fi" functionality.
Do you have any idea how can we solve this? We searched far and wide without any success. Thank you.
EDIT
Solved by using PHP SDK instead of javascript. By generating a login link as explained here. This works also on mobile captive portal assistants such as ios and android ones because the fb login page is opened in the same window and not in popup/iframe. I hope this helps others that may encounter the same problem.

FirebaseSimpleLogin not working in Windows 8 app

I asked a question earlier about if it was possible to use Firebase in a Windows 8/WinJS app. #MichaelLehenbauer told me that I just needed to add the following line to my code in order to fix a bug in firebase.js:
Firebase.INTERNAL.forceWebSockets()
This worked great and allowed me to read and write to my Firebase. However, now I am trying to get auth working in Windows 8 and running into many issues. I am trying to use the Facebook login but when I call auth.login("facebook"), my app loses focus and a new tab in the modern Internet Explorer app (not the desktop app) is opened with the typical Facebook login prompt. If I put in my credentials and hit login, nothing happens. I need to go back to my app but then it fires up a new IE tab and the process starts again. Instead of opening a new IE tab, Firebase should internally be opening an in-app dialog like seen in the top image here.
So, since I couldn't get the Firebase Facebook login working in WinJS, I tried doing the Facebook login myself and then create Firebase users using the email/password auth. However, when I run:
auth.login("password", {
email: "me#example.com",
password: "password"
});
I get the following warning (which is the same warning I received from firebase.js befoore Michael suggested to me to force web sockets):
APPHOST9601: Can’t load <https://auth.firebase.com/auth/firebase?&firebase=[my_firebase]&transport=jsonp&email=me%40example.com&password=password&callback=FirebaseSimpleLogin._callbacks._firebaseXDR13889674277557>. An app can’t load remote web content in the local context.
I'm not sure if this is another web sockets issue or not, but it looks like FirebaseSimpleLogin is just not working very well in Windows 8 apps. Are there any workarounds to these problems? Even better, is there any plan to provide full support out of the box with Windows 8?
Windows 8 is now supported out of the box with Firebase Simple Login.

Facebook Login Button Behaving Strangely

I am developing an application which on login page also supports facebook login with
<fb:login-button>.
I have set up two Apps on facebook:
one for localhost (Web site url http://localhost/, no App Domain)
one for testing server (Web site url http://dev.domain.com/, no App
Domain)
When I am developing on my own computer click on login button operates as expected and I am logged into my application.
When I put my application to the server (change appid and secret to use 2nd App) and click login button the facebook login dialog opens and when I enter email and password it closes but my applciation does not log me in.
Whats more if I check on server I see that process which is handling this web request is constantly increasing memory size (3MB per second) and its taking 50% or more CPU time. If this process is not stopped soon the server becomes unresponsive becouse memory used by it is maximum possible and CPU time is 100%.
This happens as soon as facebook login dialog closes.
In my application I am using library facebook C# SDK from codeplex.
If anyone has any information on what I might be doing wrong O would greatly appreciate the answer.
Found the problem...it was not about facebook but .Net Framework. It appears that some versions of framework support parameter passing from dynamic objects and others don't.
So when i changed code from
dynamic fbuser = GetUserData();
DoSomethingWithID(fbuser.id);
to
dynamic fbuser = GetUserData();
object fbid = fbuser.id;
DoSomethingWithID(fbid);
it started to work...dont really understand why sometimes even on the server it would work (after remote debugging it always worked until dll's were replaced but ...dont really care :) )
Thanks for all replies.
Sounds like an infinite redirect loop.
Check to see what your browser is doing using Firefox's Firebug or a built-in developer tool for Chrome, IE or Safari. I think there might be a setting wrong in your app settings, and by looking at the traffic it might help lead us to the culprit.

Facebook Connect button not showing up in Safari/Chrome

My implementation of Facebook Connect (just a simple login button, fb:login-button) works perfectly on Firefox and IE.
But the same button is not showing up in Safari/Chrome (Webkit).
Here's what's ironic. In my debugging effort, I saved the page (that contains fb:login-button) up as a static page and then load it in Safari. And the button shows up, everything works!
The exact same page (with the exact same HTML source) rendered by my PHP has no way for bringing up the button.
I'm trying hard to support Webkit here but I'm close to giving up. Can anybody help?
I found one more way this can occur (the blame-myself-for-being-stupid way); it's probably not common, but in the event is saves anyone else the hassle, here it is:
This symptom can also be caused by various security tools blocking facebook resources.
In my case, I'd installed Facebook Disconnect ages ago in Chrome as a plugin and forgotten all about it being installed. I also had a second installation of Chrome that was seemingly identical (but did not have Facebook Disconnect). The first would properly load the fb:login-button, and the other would not; took me ages before I looked at the plugins, because Facebook Disconnect didn't have an icon and so its presence was pretty easy for me to miss.
Here's what you'll see if some sort of security plugin is preventing facebook resources from loading. Just look at the html that renders in the browser using developer tools.
In a normal chrome session you'll end up with something like this:
<fb:login-button><a class="fb_button fb_button_medium"><span class="fb_button_text">Your text here</span></a></fb:login-button>
But in the version with facebook's resources disabled you'll end up with this:
<fb:login-button>Your text here</fb:login-button>
Like I said, pretty obvious in retrospect.
Had the same problem but it was not related to anything like a plugin or malformed content. It seems if you enable country filtering on your facebook page it has an issue with the like button, this should be fairly obvious. Facebook gets your location from your profile and not your IP address.
Make sure to disable country locking if you plan on using the social plugins.
This can be due to having ClickToFlash installed. Either disable it, or check "Automatically load invisible Flash views" in the ClickToFlash settings.
What we found out is that Safari (and maybe some older versions of Chrome or other WebKIT browsers) have a problem with Facebook's code using the innerHTML JS function if your page arrives with an XHTML response header (application/xhtml+xml).
Using text/html solves the issue.
In case of JSF2, which we use, the implementing the fix was as simple as wrapping the FB button like this:
<ui:composition xmlns="http://www.w3.org/1999/xhtml"
xmlns:fb="http://www.facebook.com/2008/fbml"
xmlns:f="http://java.sun.com/jsf/core">
...
<f:view contentType="text/html">
<fb:login-button>Login using Facebook</fb:login-button>
</f:view>
Facebook bug report here:
http://bugs.developers.facebook.net/show_bug.cgi?id=5545
I had this problem with the Facebook button not showing at all and it took me forever to figure out what it was. Luckily after days of hair pulling I will now share the answer with everyone. In my situation I simply didn't have xfbml enabled. In my FB.init I had it set to false:
FB.init({
appId : 'app_id', // App ID
status : true, // check login status
cookie : true, // enable cookies to allow the server to access the session
xfbml : false, // parse XFBML
oauth : true // enable OAuth 2.0
});
I changed this to "true" (xfbml) and the login buttons works great now! :P Good luck!
This happened when I had the wrong domain in callback_url in config/facebooker.yml. Apparently it uses that to load the js files.
I had the same problem but I resolved it by making sure the URL in my app settings was exactly the same as the one for my site (i.e. it didn't work when I accessed my site without the www.).
I have tried every suggested solution here and it didn't work for me. But now I finally found the solution.
Facebook requires now a secured (https) for Canvas (Secure Canvas URL). The unsecured one will be deprecated soon.
Here is the main difference, Chrome doesn't like https connections with invalid certifications. On a localhost, it is very likely you have stunnel installed to allow https connection for the localhost. Firefox is ok with the self created SSL certificate and allows you to add an exception when trying to access that site. Chrome doesn't allow it out of the box.
When I load my app in Chrome the page is blank and I dont see any login button.
Click F12 and click the Netwrok tab in Chrome:
You see that the post request to your localhost is cancelled. DOUBLE Click on it.
Now you would see that chrome is blocking the localhost because of the certificate:
click on proceed anyway.
Now to back to your other tab and reload the page:
Chrome works now like Firefox and shows the login button.