Remote Code Execution (RCE) Affecting irc-framework package, versions <4.7.0


Severity

Recommended
0.0
critical
0
10

CVSS assessment made by Snyk's Security Team

Do your applications use this vulnerable package?

In a few clicks we can analyze your entire application and see what components are vulnerable in your application, and suggest you quick fixes.

Test your applications
  • Snyk ID SNYK-JS-IRCFRAMEWORK-557137
  • published 26 Feb 2020
  • disclosed 26 Feb 2020
  • credit proton-ab

Introduced: 26 Feb 2020

CVE NOT AVAILABLE CWE-94 Open this link in a new tab

How to fix?

Upgrade irc-framework to version 4.7.0 or higher.

Overview

irc-framework is an IRC framework for node.js.

Affected versions of this package are vulnerable to Remote Code Execution (RCE). Calling event.reply with a message like Hello World\nQUIT will cause the package to pass the input straight to sockets, which in turn will split its input by newlines, resulting in IRC server receiving two lines from client: PRIVMSG #dev :Hello World and QUIT.

The underlying function responsible for handling reply to events will properly split messages and append appropriate prefix (PRIVMSG #dev in previous example) for lines that are above threshold length, however it does not do such thing for messages that explicitly contain \n in them.

CVSS Scores

version 3.1
Expand this section

Snyk

Recommended
9.8 critical
  • Attack Vector (AV)
    Network
  • Attack Complexity (AC)
    Low
  • Privileges Required (PR)
    None
  • User Interaction (UI)
    None
  • Scope (S)
    Unchanged
  • Confidentiality (C)
    High
  • Integrity (I)
    High
  • Availability (A)
    High