Reset password is working fine for me but forgot username is not.
cas.authn.pm.enabled=true
cas.authn.pm.reset.expirationMinutes=1
cas.authn.pm.reset.security-questions-enabled=false
cas.authn.pm.jdbc.user=xxx
cas.authn.pm.jdbc.password=xxx
cas.authn.pm.jdbc.driver-class=com.mysql.cj.jdbc.Driver
cas.authn.pm.jdbc.dialect=org.hibernate.dialect.MySQLDialect
cas.authn.pm.jdbc.password-encoder.type=DEFAULT
cas.authn.pm.jdbc.password-encoder.encoding-algorithm=SHA-256
cas.authn.pm.jdbc.sql-find-email=SELECT email FROM user_info WHERE name=?
cas.authn.pm.jdbc.sql-find-user=SELECT name FROM user_info WHERE email=?
cas.authn.pm.jdbc.sql-change-password=UPDATE user_info SET password=? WHERE name=?
cas.authn.pm.reset.mail.text=Reset your password with this link: %s
cas.authn.pm.reset.mail.subject=Test
spring.mail.port=587
spring.mail.username=xxx
spring.mail.password=xxx
spring.mail.properties.mail.smtp.auth=true
spring.mail.properties.mail.smtp.starttls.enable=true
2020-12-26 14:19:07,635 WARN [org.apereo.cas.util.io.CommunicationsManager] - <Could not send email to [xxx] because either no from/to/subject/text is defined or email settings are not configured.>
2020-12-26 14:19:07,657 ERROR [org.apereo.cas.pm.web.flow.actions.SendForgotUsernameInstructionsAction] - <Failed to send the username to the given email address>