Malicious Package

Affecting text-qrcode package, ALL versions

Do your applications use this vulnerable package? Test your applications

Overview

text-qrcode is a Malicious package that generated QR Code.

It contains a malicious code that overwrites the randomBytes method for the crypto module with a function that generates weak entropy. Instead of generating 32 bytes, the infected randomBytes will generate 3 bytes of entropy and hash them, resulting in a 32 byte value being returned, but one that is easily guessable.

Remediation

Avoid using text-qrcode altogether.

References

CVSS Score

9.8
high severity
  • Attack Vector
    Network
  • Attack Complexity
    Low
  • Privileges Required
    None
  • User Interaction
    None
  • Scope
    Unchanged
  • Confidentiality
    High
  • Integrity
    High
  • Availability
    High
CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Credit
Unknown
CWE
CWE-506
Snyk ID
SNYK-JS-TEXTQRCODE-73501
Disclosed
29 Nov, 2018
Published
10 Jan, 2019