org.webjars.npm:pug-code-gen@2.0.1 vulnerabilities

  • latest version

    2.0.1

  • first published

    5 years ago

  • latest version published

    5 years ago

  • licenses detected

  • package manager

Direct Vulnerabilities

Known vulnerabilities in the org.webjars.npm:pug-code-gen package. This does not include vulnerabilities belonging to this package’s dependencies.

Automatically find and fix vulnerabilities affecting your projects. Snyk scans for vulnerabilities and provides fixes for free.
Fix for free
Vulnerability Vulnerable Version
  • H
Improper Control of Generation of Code ('Code Injection')

org.webjars.npm:pug-code-gen is a Default code-generator for pug. It generates HTML via a JavaScript template function.

Affected versions of this package are vulnerable to Improper Control of Generation of Code ('Code Injection') via the name option of the compileClient, compileFileClient, or compileClientWithDependenciesTracked functions. An attacker can execute arbitrary JavaScript code by providing untrusted input.

Note:

These functions are for compiling Pug templates into JavaScript, and there would typically be no reason to allow untrusted callers.

How to fix Improper Control of Generation of Code ('Code Injection')?

There is no fixed version for org.webjars.npm:pug-code-gen.

[0,)
  • H
Remote Code Execution (RCE)

org.webjars.npm:pug-code-gen is a Default code-generator for pug. It generates HTML via a JavaScript template function.

Affected versions of this package are vulnerable to Remote Code Execution (RCE). If a remote attacker was able to control the pretty option of the pug compiler, e.g. if you spread a user provided object such as the query parameters of a request into the pug template inputs, it was possible for them to achieve remote code execution on the node.js backend.

How to fix Remote Code Execution (RCE)?

There is no fixed version for org.webjars.npm:pug-code-gen.

[0,)