← 返回列表

VMware vCenter Server CVE-2021-21972远程代码执行漏洞

单站 Rapid7 发布 Fri, 05 Mar 2021 11:08:00 +0800 入库 2026-11-18T12:16:48

翻译:李鹏 2021-03-05 11:08

2021年2月23日,VMware发布了一份公告(VMSA-2021-0002),公布了影响VMware ESXi、VMware vCenterServer和VMware Cloud Foundation的三个威胁

@RequestMapping( value = {"/uploadova"}, method = {RequestMethod.POST} ) public void uploadOvaFile(@RequestParam(value = "uploadFile",required = true) CommonsMultipartFile uploadFile, HttpServletResponse response) throws Exception { logger.info("Entering uploadOvaFile api"); int code = uploadFile.isEmpty() ? 400 : 200; PrintWriter wr = null; try { if (code != 200) { response.sendError(code, "Arguments Missing"); return; } wr = response.getWriter(); } catch (IOException var14) { var14.printStackTrace(); logger.info("upload Ova Controller Ended With Error"); } response.setStatus(code); String returnStatus = "SUCCESS"; if (!uploadFile.isEmpty()) { try { logger.info("Downloading OVA file has been started"); logger.info("Size of the file received : " + uploadFile.getSize()); InputStream inputStream = uploadFile.getInputStream(); File dir = new File("/tmp/unicorn_ova_dir"); if (!dir.exists()) { dir.mkdirs(); } else { String[] entries = dir.list(); String[] var9 = entries; int var10 = entries.length; for(int var11 = 0; var11 < var10; ++var11) { String entry = var9[var11]; File currentFile = new File(dir.getPath(), entry); currentFile.delete(); } logger.info("Successfully cleaned : /tmp/unicorn_ova_dir"); } TarArchiveInputStream in = new TarArchiveInputStream(inputStream); TarArchiveEntry entry = in.getNextTarEntry(); ArrayList result = new ArrayList(); while(entry != null) { if (entry.isDirectory()) { entry = in.getNextTarEntry(); } else { File curfile = new File("/tmp/unicorn_ova_dir", entry.getName()); File parent = curfile.getParentFile(); if (!parent.exists()) { parent.mkdirs(); } OutputStream out = new FileOutputStream(curfile); IOUtils.copy(in, out); out.close(); result.add(entry.getName()); entry = in.getNextTarEntry(); } } in.close(); logger.info("Successfully deployed File at Location :/tmp/unicorn_ova_dir"); } catch (Exception var15) { logger.error("Unable to upload OVA file :" + var15); returnStatus = "FAILED"; } } wr.write(returnStatus); wr.flush(); wr.close(); }

CVE-2021-21974是影响 HTML5 vSphere 客户端的中度(CVSSv3 基础 5.3)服务器端请求伪造漏洞。访问受影响系统的端口 443 的攻击者可以利用此弱点访问基础系统信息。

VMware已为临时缓解提供了步骤(https://kb.vmware.com/s/article/82374),其中包括禁用插件。

Rapid7实验室尚未检测到来自互联网的VMware vCenter服务器的无差别扫描,但Bad Packets(https://twitter.com/bad_packets/status/1364661586070102016?s=20)已检测到了恶意事件。我们将持续关注这个事件,并更新此文章!

原文链接:https://mp.weixin.qq.com/s?__biz=MzI4OTUxMzA1NA==&mid=2247484505&idx=1&sn=90289053f10f66496fae4acef3a85d12