React2Shell (CVE-2025–55182) explained for mere mortals
嗯,用户让我帮忙总结一篇文章的内容,控制在100字以内,而且不需要特定的开头。首先,我需要仔细阅读文章内容,理解主要信息。 文章主要讲的是JavaScript中的Function构造函数。看起来它解释了如何使用Function()来创建函数,包括如何传递字符串作为函数体和参数。这部分内容对于理解漏洞可能很重要。 用户的需求是总结文章内容,所以我要抓住关键点:Function构造函数的作用、如何用字符串创建函数、以及可能的安全问题。这样总结起来既简洁又全面。 另外,用户可能希望这个总结用于快速了解文章内容,或者用于其他用途,比如学习或教学。因此,我需要确保语言简练明了,不使用复杂的术语。 最后,检查一下字数是否在限制内,并确保没有使用任何不需要的开头词。这样就能满足用户的所有要求了。 </think> 文章介绍了JavaScript中`Function`构造函数的概念及其用法,展示了如何通过传递字符串参数动态创建函数,并解释了其潜在的安全风险和利用方式。 2026-1-26 09:12:57 Author: infosecwriteups.com(查看原文) 阅读量:2 收藏

Fady Othman

Press enter or click to view image in full size

Free Link

Disclaimer: This article is based on the amazing write up by Moritz Sanft that can be found here but with more information added to make it easier to understand.

What you need to know

There are some concepts that you need to understand before reading the PoC, I will explain them before diving into the bug details

Function constructors in Javascript

In Javascript, it’s possible to create a function using the “Function()” constructor, the code goes something like this

var myfunc = Function() // equivalent to empty function, i.e. function myfunc  () {}

As seen above we created an empty function by calling the function constructor, now what if we want to add code to that function, well, we can do something like the following.

var myfunc = Function("alert(123)")
//The above code is equivalent to the following
function myfunc() {
alert(123);
}

As seen above the string passed to the function constructor is treated as the function body, we can also create functions with arguments as below

var myfunc = Function("x","alert(x)")
//The above code is equivalent to the following
function…

文章来源: https://infosecwriteups.com/react2shell-cve-2025-55182-explained-for-mere-mortals-66c4d6864dab?source=rss----7b722bfd1b8d---4
如有侵权请联系:admin#unsafe.sh