diff options
-rw-r--r-- | CHANGELOG.md | 8 | ||||
-rw-r--r-- | models/settings.js | 4 |
2 files changed, 7 insertions, 5 deletions
diff --git a/CHANGELOG.md b/CHANGELOG.md index e5f93a6d..008e5608 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -15,10 +15,12 @@ This release adds the following new features: and fixes the following bugs: -* [Fix Squeezed tickbox in Card](https://github.com/wekan/wekan/pull/1171). +* [Fix Squeezed tickbox in Card](https://github.com/wekan/wekan/pull/1171); +* [Percent-encode SMTP password to prevent URI malformed + errors](https://github.com/wekan/wekan/pull/1190). -Thanks to GitHub users andresmanelli, danhawkes, jonasob, kubiko, nztqa -and xet7 for their contributions. +Thanks to GitHub users andresmanelli, danhawkes, jonasob, kubiko, nztqa, +pkuhner and xet7 for their contributions. # v0.32 2017-07-30 Wekan release diff --git a/models/settings.js b/models/settings.js index ce162d45..a490d9c5 100644 --- a/models/settings.js +++ b/models/settings.js @@ -45,7 +45,7 @@ Settings.helpers({ if (!this.mailServer.username && !this.mailServer.password) { return `${protocol}${this.mailServer.host}:${this.mailServer.port}/`; } - return `${protocol}${this.mailServer.username}:${this.mailServer.password}@${this.mailServer.host}:${this.mailServer.port}/`; + return `${protocol}${this.mailServer.username}:${encodeURIComponent(this.mailServer.password)}@${this.mailServer.host}:${this.mailServer.port}/`; }, }); Settings.allow({ @@ -84,7 +84,7 @@ if (Meteor.isServer) { if (!doc.mailServer.username && !doc.mailServer.password) { process.env.MAIL_URL = `${protocol}${doc.mailServer.host}:${doc.mailServer.port}/`; } else { - process.env.MAIL_URL = `${protocol}${doc.mailServer.username}:${doc.mailServer.password}@${doc.mailServer.host}:${doc.mailServer.port}/`; + process.env.MAIL_URL = `${protocol}${doc.mailServer.username}:${encodeURIComponent(doc.mailServer.password)}@${doc.mailServer.host}:${doc.mailServer.port}/`; } Accounts.emailTemplates.from = doc.mailServer.from; } |