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

Update dependency nodemailer to v6 [SECURITY] #910

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

renovate[bot]
Copy link
Contributor

@renovate renovate bot commented Feb 6, 2024

Mend Renovate

This PR contains the following updates:

Package Change Age Adoption Passing Confidence
nodemailer (source) ^4.6.4 -> ^6.0.0 age adoption passing confidence

GitHub Vulnerability Alerts

GHSA-9h6g-pr28-7cqp

Summary

A ReDoS vulnerability occurs when nodemailer tries to parse img files with the parameter attachDataUrls set, causing the stuck of event loop.
Another flaw was found when nodemailer tries to parse an attachments with a embedded file, causing the stuck of event loop.

Details

Regex: /^data:((?:[^;];)(?:[^,])),(.)$/

Path: compile -> getAttachments -> _processDataUrl

Regex: /(<img\b[^>]* src\s*=[\s"']*)(data:([^;]+);[^"'>\s]+)/

Path: _convertDataImages

PoC

https://gist.github.com/francoatmega/890dd5053375333e40c6fdbcc8c58df6
https://gist.github.com/francoatmega/9aab042b0b24968d7b7039818e8b2698

Impact

ReDoS causes the event loop to stuck a specially crafted evil email can cause this problem.


Release Notes

nodemailer/nodemailer (nodemailer)

v6.9.9

Compare Source

Bug Fixes
  • security: Fix issues described in GHSA-9h6g-pr28-7cqp. Do not use eternal matching pattern if only a few occurences are expected (dd8f5e8)
  • tests: Use native node test runner, added code coverage support, removed grunt (#​1604) (be45c1b)

v6.9.8

Compare Source

Bug Fixes
  • punycode: do not use native punycode module (b4d0e0c)

v6.9.7

Compare Source

Bug Fixes
  • customAuth: Do not require user and pass to be set for custom authentication schemes (fixes #​1584) (41d482c)

v6.9.6

Compare Source

Bug Fixes
  • inline: Use 'inline' as the default Content Dispostion value for embedded images (db32c93)
  • tests: Removed Node v12 from test matrix as it is not compatible with the test framework anymore (7fe0a60)

v6.9.5

Compare Source

Bug Fixes
  • license: Updated license year (da4744e)

v6.9.4

Compare Source

  • Renamed SendinBlue to Brevo

v6.9.3

Compare Source

  • Specified license identifier (was defined as MIT, actual value MIT-0)
  • If SMTP server disconnects with a message, process it and include as part of the response error

v6.9.2

Compare Source

  • Fix uncaught exception on invalid attachment content payload

v6.9.1

Compare Source

  • Fix base64 encoding for emoji bytes in encoded words

v6.9.0

Compare Source

  • Do not throw if failed to resolve IPv4 addresses
  • Include EHLO extensions in the send response
  • fix sendMail function: callback should be optional

v6.8.0

Compare Source

  • Add DNS timeout (huksley)
  • add dns.REFUSED (lucagianfelici)

v6.7.8

Compare Source

  • Allow to use multiple Reply-To addresses

v6.7.7

Compare Source

  • Resolver fixes

v6.7.6

Compare Source

v6.7.5

Compare Source

  • No changes, pushing a new README to npmjs.org

v6.7.4

Compare Source

  • Ensure compatibility with Node 18
  • Replaced Travis with Github Actions

v6.7.3

Compare Source

  • Typo fixes
  • Added stale issue automation fir Github
  • Add Infomaniak config to well known service (popod)
  • Update Outlook/Hotmail host in well known services (popod)
  • fix: DSN recipient gets ignored (KornKalle)

v6.7.2

Compare Source

  • Fix proxies for account verification

v6.7.1

Compare Source

  • fix verify on ses-transport (stanofsky)

v6.7.0

Compare Source

  • Updated DNS resolving logic. If there are multiple responses for a A/AAAA record, then loop these randomly instead of only caching the first one

v6.6.5

Compare Source

  • Replaced Object.values() and Array.flat() with polyfills to allow using Nodemailer in Node v6+

v6.6.4

Compare Source

  • Better compatibility with IPv6-only SMTP hosts (oxzi)
  • Fix ses verify for sdk v3 (hannesvdvreken)
  • Added SECURITY.txt for contact info

v6.6.3

Compare Source

  • Do not show passwords in SMTP transaction logs. All passwords used in logging are replaced by "/* secret */"

v6.6.2

Compare Source

v6.6.1

Compare Source

  • Fixed address formatting issue where newlines in an email address, if provided via address object, were not properly removed. Reported by tmazeika (#​1289)

v6.6.0

Compare Source

  • Added new option newline for MailComposer
  • aws ses connection verification (Ognjen Jevremovic)

v6.5.0

Compare Source

  • Pass through textEncoding to subnodes
  • Added support for AWS SES v3 SDK
  • Fixed tests

v6.4.18

Compare Source

  • Updated README

v6.4.17

Compare Source

  • Allow mixing attachments with caendar alternatives

v6.4.16

Compare Source

  • Applied updated prettier formating rules

v6.4.15

Compare Source

  • Minor changes in header key casing

v6.4.14

Compare Source

  • Disabled postinstall script

v6.4.13

Compare Source

  • Fix normalizeHeaderKey method for single node messages

v6.4.12

Compare Source

  • Better handling of attachment filenames that include quote symbols
  • Includes all information from the oath2 error response in the error message (Normal Gaussian) [1787f22]

v6.4.11

Compare Source

  • Fixed escape sequence handling in address parsing

v6.4.10

Compare Source

  • Fixed RFC822 output for MailComposer when using invalid content-type value. Mostly relevant if message attachments have stragne content-type values set.

v6.4.8

Compare Source

v6.4.7

Compare Source

  • Always set charset=utf-8 for Content-Type headers
  • Catch error when using invalid crypto.sign input

v6.4.6

Compare Source

  • fix: requeueAttempts=n should requeue n times (Patrick Malouin) [a27ed2f]

v6.4.5

Compare Source

v6.4.4

Compare Source

  • Add options.forceAuth for SMTP (Patrick Malouin) [a27ed2f]

v6.4.3

Compare Source

  • Added an option to specify max number of requeues when connection closes unexpectedly (Igor Sechyn) [8a927f5]

v6.4.2

Compare Source

  • Fixed bug where array item was used with a potentially empty array

v6.4.1

Compare Source

  • Updated README

v6.4.0

Compare Source

  • Do not use auth if server does not advertise AUTH support [f419b09]
  • add dns.CONNREFUSED (Hiroyuki Okada) [5c4c8ca]

v6.3.1

Compare Source

  • Ignore "end" events because it might be "error" after it (dex4er) [72bade9]
  • Set username and password on the connection proxy object correctly (UsamaAshraf) [250b1a8]
  • Support more DNS errors (madarche) [2391aa4]

v6.3.0

Compare Source

  • Added new option to pass a set of httpHeaders to be sent when fetching attachments. See PR #​1034

v6.2.1

Compare Source

  • No changes. It is the same as 6.2.0 that was accidentally published as 6.2.1 to npm

v6.1.1

Compare Source

  • Fixed regression bug with missing smtp authMethod property

v6.1.0

Compare Source

  • Added new message property amp for providing AMP4EMAIL content

v6.0.0

Compare Source

  • SMTPConnection: use removeListener instead of removeAllListeners (xr0master) [ddc4af1]
    Using removeListener should fix memory leak with Node.js streams

v5.1.1

Compare Source

  • Added missing option argument for custom auth

v5.1.0

Compare Source

  • Official support for custom authentication methods and examples (examples/custom-auth-async.js and examples/custom-auth-cb.js)

v5.0.1

Compare Source

  • Fixed regression error to support Node versions lower than 6.11
  • Added expiremental custom authentication support

v5.0.0

Compare Source

  • Start using dns.resolve() instead of dns.lookup() for resolving SMTP hostnames. Might be breaking change on some environments so upgrade with care
  • Show more logs for renewing OAuth2 tokens, previously it was not possible to see what actually failed

v4.7.0

Compare Source

  • Cleaned up List-* header generation
  • Fixed 'full' return option for DSN (klaronix) [23b93a3]
  • Support promises for mailcomposer.build()

v4.6.8

Compare Source

  • Use first IP address from DNS resolution when using a proxy (Limbozz) [d4ca847]
  • Return raw email from SES transport (gabegorelick) [3aa0896]

Configuration

📅 Schedule: Branch creation - "" (UTC), Automerge - At any time (no schedule defined).

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate bot changed the title Update dependency nodemailer to v6 [SECURITY] Update dependency nodemailer to v6 [SECURITY] - autoclosed Apr 3, 2024
@renovate renovate bot closed this Apr 3, 2024
@renovate renovate bot deleted the renovate/npm-nodemailer-vulnerability branch April 3, 2024 13:25
@renovate renovate bot changed the title Update dependency nodemailer to v6 [SECURITY] - autoclosed Update dependency nodemailer to v6 [SECURITY] Apr 3, 2024
@renovate renovate bot reopened this Apr 3, 2024
@renovate renovate bot restored the renovate/npm-nodemailer-vulnerability branch April 3, 2024 15:58
@renovate renovate bot force-pushed the renovate/npm-nodemailer-vulnerability branch from 84733c5 to 7265617 Compare April 3, 2024 15:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

0 participants