Many Occurence of "Cannot convert byte data com.adobe.forms.foundation.oauth.model.OAuthConfigSlingModel Error" in error.log | Community
Skip to main content
Level 5
September 19, 2023
Solved

Many Occurence of "Cannot convert byte data com.adobe.forms.foundation.oauth.model.OAuthConfigSlingModel Error" in error.log

  • September 19, 2023
  • 2 replies
  • 2396 views

Hi Team,

 

When we do some log analysis we counter many occurrence related "CryptoException" , Kindly let me what is configuration missing at system/console  to to fix  below error in log .

"

*ERROR* [sling-default-2-AdobeSignRefreshTokenScheduleJob]com.adobe.granite.crypto.CryptoException: Cannot convert byte data com.adobe.forms.foundation.oauth.model.OAuthConfigSlingModel Error while decrypting the Refresh Token "

 

Regards

Vara

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by sherinregi-1

@varaande 

One questions here .Are you seeing this error in all environments like dev/preprod/ prod or on specific environments. ?

 

In your case the token will be encrypted using one set of key and system trying to decrypt the same config in another instance which has different keys causing the issue. You can synchronize the keys by copying the same set to all instances which means decryption will happen without throwing any issue. So in one of the instance where you don't see this error use the same keys in other instances and restart .Follow the below guide 

https://exadel.com/news/aem-tip-cryptosupport-key-sharing-and-troubleshooting/

 

 

 

2 replies

sherinregi-1
Community Advisor
Community Advisor
September 20, 2023

Hi @varaande 

Crypto exception(com.adobe.granite.crypto.CryptoException) is usually encountered, when the config was generated in one environment different hmac/master and used in a different environment.

 

You can copy the same key and use it in you env and do a vmstat(http://localhost:4502/system/console/vmstat). That should help in here.In case you are looking for articles that talks about the key sharing PFB some useful links

https://www.nextrow.com/blog/adobe-experience-manager/crypto-support-in-aem-part-2

https://exadel.com/news/aem-tip-cryptosupport-key-sharing-and-troubleshooting/

 

 

 

 

varaandeAuthor
Level 5
September 21, 2023

Hi sherinregi

 

How fix this error . Client team ask us fix most of errors in log other we have provide justification for each error saying its not impacting any thing.

 

Regards

Vara

sherinregi-1
Community Advisor
sherinregi-1Community AdvisorAccepted solution
Community Advisor
September 21, 2023

@varaande 

One questions here .Are you seeing this error in all environments like dev/preprod/ prod or on specific environments. ?

 

In your case the token will be encrypted using one set of key and system trying to decrypt the same config in another instance which has different keys causing the issue. You can synchronize the keys by copying the same set to all instances which means decryption will happen without throwing any issue. So in one of the instance where you don't see this error use the same keys in other instances and restart .Follow the below guide 

https://exadel.com/news/aem-tip-cryptosupport-key-sharing-and-troubleshooting/

 

 

 

kautuk_sahni
Community Manager
Community Manager
September 21, 2023

@varaande Did you find the suggestion from @sherinregi-1 helpful? Please let us know if more information is required. Otherwise, please mark the answer as correct for posterity. If you have found out solution yourself, please share it with the community.

Kautuk Sahni