Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Improve reset password email formatting to fix broken link #19354

Closed
leaf-node opened this issue Jun 14, 2022 · 1 comment · Fixed by #19357
Closed

Improve reset password email formatting to fix broken link #19354

leaf-node opened this issue Jun 14, 2022 · 1 comment · Fixed by #19357
Assignees
Labels
Bug For errors / faults / flaws.
Milestone

Comments

@leaf-node
Copy link

Expected Behavior

  1. Send yourself a password reset email on the login screen of your Matomo site
  2. Open email in plain text mode, click on link
  3. Complete change of password on your site

Current Behavior

Instead of 3. above, one ends up with an expired / invalid token error on your site.

The URL ends in something like: ...96b9f4131cfNote, because it is part of the following string: Note: this link will expire in 24 hours.And thank you for using Matomo!

Possible Solution

Put the link on a new line by itself, and split the trailing "Next: ..." text out onto a following new line.

Steps to Reproduce (for Bugs)

  1. Send yourself a password reset email on the login screen of your Matomo site
  2. View email in Thunderbird with plain text mode
  3. Click link, and see error in your browser window
  4. Edit link by removing Note from the end, and visit that URL, for success.

Context

This prevents people from resetting their password if they are using plain text mode in their email client, but don't have the idea of manually checking the end of the password reset link for combined text.

Thanks : )

Your Environment

  • Matomo Version: 4.10.1
  • PHP Version: 7.2.24-0ubuntu0.18.04.11
  • Server Operating System: Trisquel 9.0.2
  • Additionally installed plugins: CustomVariables, MarketingCampaignsReporting, SecurityInfo, Provider
  • Thunderbird version: 91.10.0 (64-bit)
@leaf-node leaf-node added the Potential Bug Something that might be a bug, but can't be reproduced (yet). label Jun 14, 2022
@bx80
Copy link
Contributor

bx80 commented Jun 14, 2022

Hi @leaf-node, thanks for reporting this.

I can confirm that the reset link is combined with the extra text when the email is viewed in plaintext mode. Additionally the HTML reset link doesn't wrap in it's container and can overflow off screen.

This is easy to correct so I've created PR #19357 to fix it

@bx80 bx80 added Bug For errors / faults / flaws. and removed Potential Bug Something that might be a bug, but can't be reproduced (yet). labels Jun 14, 2022
@bx80 bx80 added this to the 4.12.0 milestone Jun 14, 2022
@justinvelluppillai justinvelluppillai changed the title Password reset link in plain text email is joined with trailing text, causing an error after following it Improve reset password email formatting to fix broken link Sep 29, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug For errors / faults / flaws.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants