Aman-Mittal commented on PR #5369: URL: https://github.com/apache/fineract/pull/5369#issuecomment-3794615860
Brother, by your logic if it's for strict gmail. Then what about cases which uses their custom domain for example organization email or education email from Google workspace. What would happen to that? Will that work? On Sat, 24 Jan, 2026, 5:05 pm Aira Jena, ***@***.***> wrote: > ***@***.**** commented on this pull request. > ------------------------------ > > In > fineract-provider/src/main/java/org/apache/fineract/infrastructure/core/service/GmailBackedPlatformEmailService.java > <https://github.com/apache/fineract/pull/5369#discussion_r2724067122>: > > > @@ -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")) { > > The code already handles this - it only applies strict SSL/TLS settings > when the SMTP host ends with gmail.com. For other providers (Yahoo, > Outlook, ProtonMail, or even local testing with Mailhog), it uses relaxed > settings without forcing the SSL SocketFactory. This way, the email service > works with any SMTP provider configured in the external services settings. > > — > Reply to this email directly, view it on GitHub > <https://github.com/apache/fineract/pull/5369#discussion_r2724067122>, or > unsubscribe > <https://github.com/notifications/unsubscribe-auth/AHV6TA63OV2P7O3AEJXFMS34INKIHAVCNFSM6AAAAACSUFDBTOVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZTOMBRGQ3TKMRRG4> > . > You are receiving this because you commented.Message ID: > ***@***.***> > -- 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]
