Développer ma barre des réalisations de la Communauté.

Submissions are now open for the 2026 Adobe Experience Maker Awards.

Mark Solution

Cette conversation a été verrouillée en raison de son inactivité. Veuillez créer une nouvelle publication.

RÉSOLU

Adobe AccessTokenProvider error

Avatar

Level 2

Hello experts,

 

I am getting the following error when trying to get the access token using the AccessTokenProvider.getAccessToken() method. I am passing the proper parameters, resourceResolver generated from User, user id and claims as null. Below is the screenshot of the error.

 

b9b8c322-bd4f-483a-a368-5dcb224bd2d7.jpeg

1 solution acceptée

Avatar

Réponse correcte par
Employee Advisor

It looks that you have some problem with your keyStore. 

 

KeyStoreService.getKeyStoreKeyPair (resourceResolver, ID, keyPairAlias) returns null. The KeyPairAlias is the value configured at the OSGI service "Adobe Granite Access Token Provider"  with the property name "auth.token.provider.keypair.alias" (default value is "access-token-key-pair").

 

Voir la solution dans l'envoi d'origine

4 Replies

Avatar

Réponse correcte par
Employee Advisor

It looks that you have some problem with your keyStore. 

 

KeyStoreService.getKeyStoreKeyPair (resourceResolver, ID, keyPairAlias) returns null. The KeyPairAlias is the value configured at the OSGI service "Adobe Granite Access Token Provider"  with the property name "auth.token.provider.keypair.alias" (default value is "access-token-key-pair").

 

Avatar

Level 2
Thanks Jorg. It worked. What should be the value of "auth.token.provider.client.id", If I provider "TestClient" as value I am getting the invalid client id parameter as error. If I provide actual value I am getting null pointer exception.

Avatar

Level 2
Thanks Jorg. It worked. What should be the value of "auth.token.provider.client.id", If I provider "TestClient" as value I am getting the invalid client id parameter as error. If I provide actual value I am getting null pointer exception in method buildJwt line no. 501

Avatar

Employee Advisor
tbh, I don't know the API, so I cannot give you proper advice.