Auth0 Home Blog Docs

Missing parameters in idToken

login

#1

I register users in Auth0 with Android app ( with Andorid SDK 1.3.0 ). When I login with that new user and I decode the idToken I dont see parameters like sub, iat, aud, iss. That parameters are present in users that are registered the weeks after. Why that is happens?

PD: Even with the email is verified the parameters are missing :frowning:


#2

:wave: @jperez what parameters do you see in the token and which were you expecting? Is this a brand new application you are creating or a previous application that was receiving the token with the parameters you expected?


#3

Hi Kim :slight_smile: I see in the other users (previously registered in auth0) the next parameters: iss, sub and aud. If I register a new one that parameters doesn’t appear in idToken. The app was created in March 2018


#4

Gotcha! Thank you. And what scopes are you including in your authentication request? I believe with the Android SDK it looks something like:

Auth0 auth0 = new Auth0(this);
auth0.setOIDCConformant(true);
WebAuthProvider.init(auth0)
    .withScheme("demo")
    .withScope("openid profile email")
    ... 

and do you have any Rules setup ?


#5

Im login using this:
Auth0 account = new Auth0(context.getString(R.string.com_auth0_client_id),context.getString(R.string.com_auth0_domain));
account.setOIDCConformant(true);
AuthenticationAPIClient client =AuthenticationAPIClient(account);
client.login(…)

And my rules setup are this:

Email domain whitelist - off
addCentreToIdToken - on
getUserMetadata - on

Btw that is happening too login in iOS :frowning:


#6

@jperez I am guessing the addCentreToIdToken is where you are adding the parameters to the id_token, but you say they are missing? Could you maybe share the code for that Rule? The problem may be due to the Rules you have setup.