MOSIP SMTP Mail Issue

Hi Team,

We have configured the SMTP settings in our MOSIP system for triggering the mail notifications. But, when we initiate the mail OTP from Pre-RegUI, it is asking me to enter the OTP but I haven’t received any. I have checked with both official and personal ID(GMAIL) but didn’t receive any OTP. I even verified logging in with the mail ID which I configured in the MOSIP system and sent the mails manually and able to send/receive. We are also able to see the relative logs in the prereg-application with 200 response. Kindly check and let us know if we missed anything.

Please find the below screenshots for your reference.

Thanks & Regards
Naveen

1 Like

Hello Naveen,

Could you please check and share the kernel-notification-service logs? Also, could you confirm if you’re using mock-smtp or real SMTP?

Thanks,
Rakshith

1 Like

Hi Rakshith,

Please find the logs screenshot for kernel-notification-service below:

As shown in above screenshot, Is it because of restriction from the mail server?

FYI…Our SMTP settings are configured in the email-gateway configmap of kernel namespace as shown below:

We also observed that this value has been hardcoded in the kernel default properties file which could also be the reason for our mail server to block the mail with anonymous address.

mosip.kernel.notification.email.from=do-not-reply@mosip.io

For your second question, we have deployed mock-smtp service as part of the all MOSIP modules installation. When we deploy actual smtp service, this can be replaced right?

Thanks
Naveen

Hi Naveen,

yes add the “from” address in mosip.kernel.notification.email.from and
to enable real SMTP. Set mosip.kernel.auth.proxy-email to false.

Also, ensure that you are passing the correct username, password, host, and port.

Thanks,
Rakshith

Hi Rakshith,

Thanks for the response. Will try this configurations and let you know if any issue.

Thanks
Naveen