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

fix(core): Decrease reset password token expire time #7598

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
<p>Hi {{firstName}},</p>
<p>Somebody asked to reset your password on n8n ({{ domain }}).</p>
<br />
<p>Click the following link to choose a new password. The link is valid for 2 hours.</p>
<p>Click the following link to choose a new password. The link is valid for 20 minutes.</p>
<a href="{{ passwordResetUrl }}">{{ passwordResetUrl }}</a>
2 changes: 1 addition & 1 deletion packages/cli/src/controllers/passwordReset.controller.ts
Original file line number Diff line number Diff line change
Expand Up @@ -120,7 +120,7 @@ export class PasswordResetController {
const resetPasswordToken = this.jwtService.signData(
{ sub: id },
{
expiresIn: '1d',
expiresIn: '20m',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

love it.. so simple.. can you double check that the email does not say anything about a day expiry?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will check 🫡

Copy link
Contributor Author

@tomi tomi Nov 3, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice catch! It actually said 2 hours. I amended the change to the same commit as this was so tiny change. Also rebased to master. @mutdmour can you have another look?

},
);

Expand Down
Loading