Empresas
Empregos
  • Sobre nós
  • Soluções
    • Publicação de vagas
      Publique sua vaga e receba candidatos qualificados em 48h.
    • Avaliações de candidatos
      Mais de 500 testes técnicos e psicológicos, mais anti-fraude.
    • Headhunting
      Busca executiva personalizada do início ao fim.
    • Folha de Pagamento + EOR
      Dispersão de folha e EOR em mais de 15 países da LATAM.
  • Preços
  • Empregos

0

375
Visualizações
node js verify JWT error apple-signin-auth package: Invalid id token public key id

I am using apple-signin-auth in my node js app.

I try to verify the IdToken as you can see here:

result = await appleSignin.verifyIdToken(token, {
  audience: config.CLIENT_ID_APPLE,
  ignoreExpiration: true, // ignore token expiry (never expires)
});

I want to ignoreExpiration of the token and CLIENT_ID_APPLE is correct. But I can see the following error in my logs.

JsonWebTokenError: error in secret or public key callback: input error: Invalid id token public key id at /app/node_modules/jsonwebtoken/verify.js:96:19 at _getIdTokenApplePublicKey (/app/node_modules/apple-signin-auth/lib/index.js:1:5730) at runMicrotasks () at processTicksAndRejections (internal/process/task_queues.js:95:5)

A list for valid options for the appleSignin.verifyIdToken function is stated here.

When I test is locally it works to verify the idToken. But I only tested with a not expired token. Is it possible that the error message is misleading and it has something to do with the expiration of the token?

about 4 years ago · Juan Pablo Isaza
Responde à pergunta
Encontrar trabalhos remotos

Descubra a nova forma de encontrar um emprego!

melhores empregos
Principais categorias de trabalho
Empresas
Postar vaga Preços Comercial
Jurídico
Termos e Condições Política de privacidade
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Recomende algumas ofertas para mim
Preciso de ajuda