Skip to content

CS 4.20.1 Password Reset Functionality Java Error #11159

Description

@tatay188

problem

The Password Reset Functionality throws an error, Using ubuntu msmtp works.

We have enabled the password reset functionality:

the sender username is noreply@mydomain.com

Image

Image

Logs from the management server:

2025-07-04 15:01:57,332 ERROR [o.a.c.u.m.SMTPMailSender] (qtp1404565079-345:[ctx-80979faa]) (logid:0e1f5dee) Unable to send mail [Password Reset Request] to the recipcients [[{"mailAddress":"tatay@mymail.com"}]]. javax.mail.MessagingException: Could not connect to SMTP host: smtp.office365.com, port: 587;
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1961)
at com.sun.mail.smtp.SMTPTransport.protocolConnect(SMTPTransport.java:654)
at javax.mail.Service.connect(Service.java:295)
at javax.mail.Service.connect(Service.java:176)
at javax.mail.Service.connect(Service.java:125)
at org.apache.cloudstack.utils.mailing.SMTPMailSender.sendMail(SMTPMailSender.java:175)
at com.sun.mail.util.SocketFetcher.configureSSLSocket(SocketFetcher.java:527)
at com.sun.mail.util.SocketFetcher.createSocket(SocketFetcher.java:332)
at com.sun.mail.util.SocketFetcher.getSocket(SocketFetcher.java:234)
at com.sun.mail.smtp.SMTPTransport.openServer(SMTPTransport.java:1927)
2025-07-04 15:01:57,336 DEBUG [o.a.c.u.UserPasswordResetManagerImpl] (qtp1404565079-345:[ctx-80979faa]) (logid:0e1f5dee) User password reset email for user UserAccount {"accountName":"domain1","id":5,"username":"tatay"}. account id: 5 domain id: 3 sent to tatay@mymail.com with token expiry at 2025-07-04T15:31:57.243+0000
2025-07-04 15:08:28,663 WARN [c.c.c.ConfigurationManagerImpl] (qtp1404565079-447:[ctx-7d09367d, ctx-af7db5cb]) (logid:37392271) Configuration user.password.reset.email.sender no found. Perhaps moved to ConfigDepot
2025-07-04 15:08:28,675 WARN [c.c.c.ConfigurationManagerImpl] (qtp1404565079-447:[ctx-7d09367d, ctx-af7db5cb]) (logid:37392271) Configuration user.password.reset.mail.template no found. Perhaps moved to ConfigDepot

We tested from the server and Works using the msmtp in Ubuntu

versions

ACS version 4.20.1

The steps to reproduce the bug

  1. create an email account in Microsoft, with TLS and and AUTH port 587
  2. Fill the information in the CS management servers
  3. test.
    ...

What to do about it?

No response

Activity

  1. changed the title [-]CS 4.20.1 Password Reset Functionality[/-] [+]CS 4.20.1 Password Reset Functionality Java Error[/+] on Jul 9, 2025
  2. weizhouapache commented on Jul 10, 2025

    @weizhouapache
    Member

    there is no setting like "user.password.reset.useStartTLS".
    should it be added , similar to alert.smtp.useStartTLS and quota.usage.smtp.useStartTLS, project.smtp.useStartTLS ?

    cc @vishesh92

  3. added this to the 4.20.2 milestone on Jul 10, 2025
  4. moved this from Todo to ready for Review in Apache CloudStack BugFest - Issueson Jul 17, 2025
  5. removed their assignment
    on Sep 22, 2025
  6. weizhouapache commented on Oct 7, 2025

    @weizhouapache
    Member

    fixed by #11228

    @tatay188
    if you still face the same issue with upcoming 4.20.2 or 4.22, let us know

  7. tatay188 commented on Oct 7, 2025

    @tatay188
    Author
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions