*WHAT* Currently there is a -bug in the Keycloak JS adapter in that it will always return localhost as the redirect uri.- method in the Keycloak JS adapter which will always return localhost for the adapter redirectUri when cordova is used. See here: https://github.com/keycloak/keycloak-js-bower/blob/master/dist/keycloak.js#L1289 See https://github.com/keycloak/keycloak/pull/5272#issuecomment-397070692 for a proposed fix and why it will not be implemented.
We currently work around this by allowing redirect from localhost on the keycloak server. However this is a hacky workaround and we should instead allow the developer to set the redirect they wish to use. This will involve changes to the auth sdk to allow this object be passed in and also to override the function by making use of the custom adapter here: https://github.com/keycloak/keycloak-js-bower/blob/master/dist/keycloak.js#L54
The problem here is that when using a local openshift cluster we cannot use localhost/* as a redirectUri as the device and openshift will be on different networks. |
|