On 29 May 2018 at 13:57, Gregor Tudan <Gregor.Tudan(a)cofinpro.de> wrote:
Hey Stian,
Thanks, I took a good look at most of the libraries out there - but I
still would love to continue using Keycloak.js.
Great, would love to see this added to keycloak.js. Was primarily pointing
to AppAuth as a source of inspiration rather than suggesting you use that
instead.
I got quiet far pretty fast by implementing a second Cordova adapter
("Cordova-native“) and falling back to the old one it the required plugin
is missing. Or would you prefer extending the existing Cordova adapter?
That would make the code a little messy, since we would need a huge if in
every method.
Adding a second adapter is a nice and clean way to do it.
Figuring out the callback wasn’t to hard either - now the last missing
piece is parsing the callback. Here we have the option of registering a
universal link inside the Keycloak adapter which opens the app, or leaving
this to the developer and provide a public method for it (like
processCallback).
I’m not quiet sure on these options, what are your thoughts on this?
Could you elaborate a bit on this please?
- Gregor
Am 29.05.2018 um 09:33 schrieb Stian Thorgersen <sthorger(a)redhat.com>:
Sounds reasonable. I recommend looking at the following first though
before you start implementation AppAuth [1] and OAuth 2.0 for Native Apps
[2]
[1]
https://appauth.io/
[2]
https://tools.ietf.org/html/rfc8252
On 28 May 2018 at 16:34, Gregor Tudan <Gregor.Tudan(a)cofinpro.de> wrote:
> Hi there,
>
> I would like to pick up an old issue: KEYCLOAK-2606<https://issues.j
>
boss.org/browse/KEYCLOAK-2606>
> Our current app uses Keycloak with the Cordova In-App-Browser.
> Technically this works fine, but the user experience is … uhmm … awful. The
> page renders quiet slow and has focus issues.
>
> I’d love to help getting some support for the browser-tab. I started
> porting the ionic sample app to browertabs, but would like to check back
> with you before doing something stupid.
>
> The idea is:
> 1. In Keycloak.js Cordova Adapter check if browertab is supported, else
> fall back to in-app-browser
> 2. Open the login-page with the In-App-Browser (leaving the app)
> 3. Register a custom-url-scheme and configure it as redirect url (i.e.
> keycloakapp://). We’ll need another Cordova plugin for this (i.e. deep
> links). The Cordova-Adapter needs to get extended for this, since
> „localost“ seems to be hardcoded as redirect-url)
> 4. The Keycloak-server will redirect to the app after login succeeded.
> The App will need to reinitialize the Keycloak-Adapter with the code given
> in the url - I’m not sure if this will work out of the box.
>
> Does this sound reasonable?
>
> Thanks,
> Gregor!
> _______________________________________________
> keycloak-dev mailing list
> keycloak-dev(a)lists.jboss.org
>
https://lists.jboss.org/mailman/listinfo/keycloak-dev