Skip to content

Commit

Permalink
Set additional properties for javamail
Browse files Browse the repository at this point in the history
  • Loading branch information
dersmon committed Jul 11, 2024
1 parent 20a5b02 commit 851cf2d
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,8 @@ public MailService(final @Value("${mailSMTPServer}") String smtpServer

Properties props = new Properties();
props.put("mail.smtps.auth", true);

props.put("mail.transport.protocol","smtp");
props.put("mail.smtp.tls", "true");
mailSender.setJavaMailProperties(props);
mailSender.setHost(smtpServer);
mailSender.setUsername(smtpUserName);
Expand Down

0 comments on commit 851cf2d

Please sign in to comment.