[Openid-specs-ab] Single Sign-On is dead on iOS 11
rich.levinson at oracle.com
Thu Jun 15 17:55:51 UTC 2017
I admit I do not know every detail and nuance associated w OAuth/OIDC.
Therefore, I will try to clearly state my assumptions, and will be more than
happy to be corrected if they are wrong.
1. I assume each application on a mobile device has a unique client-id
associated w a specific az-svr. (based on 2 below)
2. I assume each application on a mobile device has a unique redirect-uri,
which enables it to receive authorization responses from the az-svr.
If this was not the case then how else could the app rcv the responses.
3. Therefore, when a client app is registered on the az-svr, dynamically,
or otherwise, the az-svr has a unique pair: [client-id, redirect-uri]
associated w each client app that can access the az-svr from a specifi
Now, if multiple apps from a single device are registered w the az-svr,
then, initially, at least, this set of apps are neither associated w the same
device, nor associated w any end-user. They are simply a set of unique
client-id,redirect-uri pairs among a huge set of all other pairs from all
other apps on all other devices registered w the az-svr.
So, when an az-req is made from a client app on the device to the az-svr,
this is the first time the app becomes associated w an end-user, which
happens when the end-user logs in and the az-svr authorizes the end-user
to use the client-app, as well as authorizing the client-app to perform
operations on behalf of the end-user, as specified in the scope of the
At this point, the az-svr can record a triple: [user-id,client-id-1,redirect-uri-1]
which associates the end-user w the client-app.
Similarly, if a 2nd app from the same device is used for the first time w
the same az-svr, then a 2nd triple can be established:
which can now be relate the end-user to both client-id-1 and client-id-2.
What is still unknown @ the az-svr is whether client-id-1 and client-id-2
are associated w the same device.
I have not found any obvious way to do this using the existing protocol
messages, but it seems to me that if it is in the end-user's interest to tie
these apps together for the purposes of SSO, then it should be fairly
straight-forward matter to enable the user to establish these ties
during the consent phase, whereby the user might enter some kind
of personal device-id to associate w the app that the user is giving consent to.
This would enable all the knowledge necessary to establish SSO on the
az-svr, w/o having to rely on cooperation from the device OS, which
apparently is being designed to prevent this from easily happening w/o
the user's knowledge.
This scheme, however, could be implemented w the user's knowledge and
consent, and should be able to enable other features as well if desired.
On 6/14/2017 2:35 PM, John Bradley wrote:
> No you are just pushing the problem around. How would the AS know that all the apps are from the same device when doing dynamic client registration.
> Any app learning the redirect_uri for a device could then move that to a different device and use it to login as the user.
> I don’t think this would work.
> John B.
>> On Jun 14, 2017, at 4:27 AM, rich levinson via Openid-specs-ab <openid-specs-ab at lists.openid.net <mailto:openid-specs-ab at lists.openid.net>> wrote:
>> Hi Iain, Justin, and Phil,
>> Thanks for the replies.
>> It seems that the issue boils down to the fact that under ordinary circumstances,
>> the user device would send the session cookie from the first login, which would
>> enable the OP to determine that the same user who is already logged in is making
>> a request from another app on the same device.
>> However, ios-11, w its app silo does not send this cookie, so the OP has no context,
>> for knowing the user is already logged in.
>> Based on looking @ the native app proposal:
>> it appears possible that when a client app registers w the op, that the "redirect-uri"
>> could possibly designed such that all apps registered from a single device could
>> conceivably use a redirect-uri prefix that would identify those apps as sharing
>> a common device.
>> If the registration also included info that the common device was a "single-user device",
>> such as a cell phone, then when the client-app sends the authorization request,
>> the op could check if there was already a session set up for that device, inferring
>> that that a 2nd req from a 2nd app from the same single-user device could be associated
>> w the same user that had established a session from the 1st req from the 1st app of
>> the same "single-user device".
>> This would effectively be a scheme for replacing dependence on the cookie,
>> w dependence on the integrity of the redirect-uri's registered w the op,
>> which could also be double-checked w the client-id that the op assigned to the app.
>> Does that seem like a reasonable way to address the issue?
>> On 6/13/2017 5:57 PM, Iain McGinniss wrote:
>>> Each SFSafariViewController (SFSVC) instance is essentially a new browser, with the following consequences:
>>> 1. If the user signs in to the OP in Safari, this signed in state is not visible from any SFSVC instance.
>>> 2. If the user signs in via an SFSVC, this signed in state also cannot be synchronized to Safari.
>>> As a result, there's no shared OP session between any apps; the user must re-authenticate with the OP within every app that uses it.
>>> Furthermore, the Intelligent Tracking Prevention <https://webkit.org/blog/7675/intelligent-tracking-prevention/> /may/ flag the OP domain as a capable of tracking the user, at which point any cookie / local storage state associated with that domain is "redacted" if the user has not interacted with the OP domain in the last 24 hours. "Interaction" here specifically means loading a top-level page on that domain and clicking on something. It seems highly likely that *.google.com <http://google.com/> is going to be marked as a tracking domain in Safari.
>>> So, if you do anything in iframes with your OP domains (we do at Google), your cookies are going to appear and disappear in a very unpredictable way. Session state is going to become very unreliable.
>>> I plan to give an impromptu short talk on these changes at CIS.
>>> On Tue, Jun 13, 2017 at 2:40 PM, rich levinson via Openid-specs-ab <openid-specs-ab at lists.openid.net <mailto:openid-specs-ab at lists.openid.net>> wrote:
>>> Hi Nat, et al,
>>> I am not sure I understand why this situation should cause anything to "break".
>>> Let me explain my view of this situation, in the context of general session mgmt,
>>> which is the following:
>>> In the "OpenID Connect Session Management 1.0" spec:
>>> http://openid.net/specs/openid-connect-session-1_0.html <http://openid.net/specs/openid-connect-session-1_0.html>
>>> it says:
>>> "In OpenID Connect, the session at the RP typically starts
>>> when the RP validates the End-User's ID Token.
>>> When the OP supports session management, it MUST also return the Session State
>>> as an additional session_state parameter in the Authentication Response.
>>> This parameter is:
>>> Session State.
>>> JSON [RFC7159] string that represents the End-User's login state at the OP.
>>> It MUST NOT contain the space (" ") character.
>>> This value is opaque to the RP.
>>> This is REQUIRED if session management is supported.
>>> The Session State value is initially calculated on the server."
>>> This indicates that the OP has knowledge of the End-User's login state at the OP.
>>> However, this login state is independent of the "session at the RP", which is
>>> created when the client app (RP) rcv's the identity token which, in the protocol,
>>> is well after the End-User logged in at the OP.
>>> Later in the spec, section 5, it is also stated that:
>>> "5. RP-Initiated Logout
>>> An RP can notify the OP that the End-User has logged out of the site and
>>> might want to log out of the OP as well.
>>> In this case, the RP, after having logged the End-User out of the RP,
>>> redirects the End-User's User Agent to the OP's logout endpoint URL.
>>> This URL is normally obtained via the end_session_endpoint element
>>> of the OP's Discovery response or may be learned via other mechanisms."
>>> This basically confirms the supposition above that the OP login and the RP session are
>>> effectively independent entities.
>>> Now, let's consider the case where a 2nd RP decides to start a session w the same End-User,
>>> presumably, a 2nd RP on the same device where the 1st RP established a session.
>>> When the 2nd RP sends the Authentication Request to the OP's /authorize endpoint,
>>> it seems obvious to me that the OP knows the End-User is logged in and would have
>>> no problem issuing a 2nd id-token to the 2nd RP, w/o re-logging in the End-User.
>>> Assuming this is the case, then I do not understand why ios-11, by "siloing" the apps
>>> prevents the OP from issuing new id-tokens to each app, all under the original
>>> OP-login by the End-User.
>>> Am I missing something?
>>> On 6/12/2017 8:04 PM, Nat Sakimura via Openid-specs-ab wrote:
>>>> Maybe we can call upon the privacy community as well raising the voice that this is very bad for privacy.
>>>> I wonder what is the privacy enhancement they have in mind.
>>>> On Fri, Jun 9, 2017 at 2:34 AM 'Iain McGinniss' via OIDF Account Chooser list <oidf-account-chooser-list at googlegroups.com <mailto:oidf-account-chooser-list at googlegroups.com>> wrote:
>>>> Hello all,
>>>> Just to bring this to your attention: Apple has essentially killed single sign-on for native apps in iOS 11. Changes made to SFSafariViewController (used by AppAuth, and the recommended mechanism for federated login by Apple) now mean that browser state is partitioned per app, so there is no way for an existing authentication in the browser to be reused by an app.
>>>> This fundamentally breaks an important part of OpenID Connect - users will now need to re-authenticate with their IDP in every app that they use. There is still time to provide feedback to Apple on this change, though they have been discussing this change in terms of "enhancing privacy" and I'd be very surprised if they change tack now.
>>>> You received this message because you are subscribed to the Google Groups "OIDF Account Chooser list" group.
>>>> To unsubscribe from this group and stop receiving emails from it, send an email to oidf-account-chooser-list+unsubscribe at googlegroups.com <mailto:oidf-account-chooser-list+unsubscribe at googlegroups.com>.
>>>> For more options, visit https://groups.google.com/d/optout <https://urldefense.proofpoint.com/v2/url?u=https-3A__groups.google.com_d_optout&d=DwMFaQ&c=RoP1YumCXCgaWHvlZYR8PQcxBKCX5YTpkKY057SbK10&r=nNxUKneeZofWTyt9qclOUTeEg29NkEkknFyDupoNiiA&m=z6H6MqLIToKnju5TQdKnYOa6pGD9lyMxhwLO-mdMgac&s=XtvXRyjw8QvajPlQD8M0d6xQJnp_3jK9zv_hDOXEOXY&e=>.
>>>> Nat Sakimura
>>>> Chairman of the Board, OpenID Foundation
>>>> Openid-specs-ab mailing list
>>>> Openid-specs-ab at lists.openid.net <mailto:Openid-specs-ab at lists.openid.net>
>>>> https://urldefense.proofpoint.com/v2/url?u=http-3A__lists.openid.net_mailman_listinfo_openid-2Dspecs-2Dab&d=DwICAg&c=RoP1YumCXCgaWHvlZYR8PQcxBKCX5YTpkKY057SbK10&r=nNxUKneeZofWTyt9qclOUTeEg29NkEkknFyDupoNiiA&m=z6H6MqLIToKnju5TQdKnYOa6pGD9lyMxhwLO-mdMgac&s=tYftjD7QNKeiH9oZIyspoUu_QX44iHnFoAzyiuQapmg&e= <https://urldefense.proofpoint.com/v2/url?u=http-3A__lists.openid.net_mailman_listinfo_openid-2Dspecs-2Dab&d=DwICAg&c=RoP1YumCXCgaWHvlZYR8PQcxBKCX5YTpkKY057SbK10&r=nNxUKneeZofWTyt9qclOUTeEg29NkEkknFyDupoNiiA&m=z6H6MqLIToKnju5TQdKnYOa6pGD9lyMxhwLO-mdMgac&s=tYftjD7QNKeiH9oZIyspoUu_QX44iHnFoAzyiuQapmg&e=>
>>> Openid-specs-ab mailing list
>>> Openid-specs-ab at lists.openid.net <mailto:Openid-specs-ab at lists.openid.net>
>>> http://lists.openid.net/mailman/listinfo/openid-specs-ab <http://lists.openid.net/mailman/listinfo/openid-specs-ab>
>> Openid-specs-ab mailing list
>> Openid-specs-ab at lists.openid.net <mailto:Openid-specs-ab at lists.openid.net>
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Openid-specs-ab