JWT failing on Node call

I am starting to tie in node to my Vue app. I have the JWT being sent and it’s erroring. Here is the error.

UnauthorizedError: jwt audience invalid. expected: 192.168.1.12:97/auth

Looking at the JWT I get this:

{
  "iss": "https://real-crypto.auth0.com/",
  "sub": "auth0|5c7190ffed12163eb4571a05",
  "aud": [
    "192.168.1.12:97",
    "https://real-crypto.auth0.com/userinfo"
  ],
  "iat": 1551042011,
  "exp": 1551049211,
  "azp": "dlYb6WWwVjCqklCaPecEZLTy0Zd4tuxh",
  "scope": "openid profile email"
}

In the Auth0 Dashboard in API I have the Identity field as 192.168.1.12:97

How is my app wanting the aut field to show 192.168.1.12:97/autht? that is the node route that I am calling but how does it expect that to be the field? Or am I mis-reading the error?

So what is going on here, how is it having 2 fields in aut? How can I get this to work.

Ok I figured it out, Im not sure if it is not in the docs or what, but for me what worked was using a New API token with the identifier the same as the URL I was calling on my serer. So in my case I changed the Identifier to
192.168.1.12:97/auth
it seems common sense now and in reality I thought about that, and I should have tried it, but the instructions do not implicitly say this is the way you do this.

Glad you were finally able to make it! Really appreciate your feedback regarding docs, I’ll make sure to relay it to our docs team!

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.