airajena commented on code in PR #5369:
URL: https://github.com/apache/fineract/pull/5369#discussion_r2725060405
##########
fineract-provider/src/main/java/org/apache/fineract/infrastructure/core/service/GmailBackedPlatformEmailService.java:
##########
@@ -74,12 +74,16 @@ public void sendDefinedEmail(EmailDetail emailDetails) {
props.put("mail.debug", "true");
// these are the added lines
- props.put("mail.smtp.starttls.enable", "true");
- // props.put("mail.smtp.ssl.enable", "true");
-
- props.put("mail.smtp.socketFactory.port",
Integer.parseInt(smtpCredentialsData.getPort()));
- props.put("mail.smtp.socketFactory.class",
"javax.net.ssl.SSLSocketFactory");// NOSONAR
- props.put("mail.smtp.socketFactory.fallback", "true");
+ // Only apply strict Gmail settings if we are actually connecting to
Gmail
+ if (smtpCredentialsData.getHost() != null &&
smtpCredentialsData.getHost().endsWith("gmail.com")) {
Review Comment:
I agree, the SMTP settings refactoring is outside the scope of this ticket.
I have reverted those changes and updated the PR. I'll raise a separate ticket
to handle the SMTP connection improvements.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]