Expand my Community achievements bar.

Issue with CQ Mail service

Avatar

Community Advisor

Hello

   We are getting issue with SMTP configuration. We tried debugging it and found these logs

DEBUG SMTP: protocolConnect returning false, host=[HOST], user=crx, password=<null>

 

We are passing username n password on cq mail service n it seems it not picking those username/pwd

 

Any idea what can be the issue?

 

Thanks

Dipti

6 Replies

Avatar

Community Advisor

Hi @Dipti_Chauhan 

 

I believe you are using com.day.cq.mailer.DefaultMailService service and providing the configurations.

If you see it's not picking the correct value, can you please check if there is a default config available under /apps/system/config

 

Please ensure the correct run mode is picked while providing these configurations.

 

Apart from these I don't see any other reason these values will not be picked.

 

Thanks!

Avatar

Community Advisor

Hi @Asutosh_Jena_ 

     Its only username n pwd , all others configs are getting picked.

 

Thanks

Dipti

Avatar

Community Advisor

It should be. If not can you encrypt using AEM Crypto service and then add it?

 

Thanks!

Avatar

Employee Advisor

Hi @Dipti_Chauhan ,

 

You need to encrypt the values. You can do that using Crypto Support.

Please check the below link

https://bimmisoi.blogspot.com/2020/08/crypto-support-in-aem.html

 

Hope this helps!!
Thanks

Avatar

Community Advisor

Hi @Dipti_Chauhan,

Per the config property description, smtp.password can be either plain text or encrypted using crypto support. 

 

If you can try in any lower environments/in local, amend the config by being in Felix console and see if all the values are picked this way.

Example :  you can enable "Debug Email",  disable if you have already or try changing the From address (just for testing)

 

If this didn't work, try to restart the OSGi component - com.day.cq.mailer.DefaultMailService and/or bundle - Day Communique 5 Mailer(com.day.cq.cq-mailer)

Avatar

Community Advisor

Hi All

 thanks for your response.

This got resolved.We had issue with port as outbound was blocked for the port and due to connectivity issue username /pwd was not getting printed.weird but this was the case.After resolving port issue these started printed in logs.

 

Thanks

Dipti