# 5800,5801,5900,5901 - Pentesting VNC
{% hint style="success" %}
Learn & practice AWS Hacking:[**HackTricks Training AWS Red Team Expert (ARTE)**](https://training.hacktricks.xyz/courses/arte)\
Learn & practice GCP Hacking: [**HackTricks Training GCP Red Team Expert (GRTE)**](https://training.hacktricks.xyz/courses/grte)
Support HackTricks
* Check the [**subscription plans**](https://github.com/sponsors/carlospolop)!
* **Join the** ๐ฌ [**Discord group**](https://discord.gg/hRep4RUj7f) or the [**telegram group**](https://t.me/peass) or **follow** us on **Twitter** ๐ฆ [**@hacktricks\_live**](https://twitter.com/hacktricks\_live)**.**
* **Share hacking tricks by submitting PRs to the** [**HackTricks**](https://github.com/carlospolop/hacktricks) and [**HackTricks Cloud**](https://github.com/carlospolop/hacktricks-cloud) github repos.
{% endhint %}
If you are interested in **hacking career** and hack the unhackable - **we are hiring!** (_fluent polish written and spoken required_).
{% embed url="https://www.stmcyber.com/careers" %}
## ๊ธฐ๋ณธ ์ ๋ณด
**Virtual Network Computing (VNC)**๋ **Remote Frame Buffer (RFB)** ํ๋กํ ์ฝ์ ์ฌ์ฉํ์ฌ ์๊ฒฉ ์ ์ด ๋ฐ ๋ค๋ฅธ ์ปดํจํฐ์์ ํ์ ์ ๊ฐ๋ฅํ๊ฒ ํ๋ ๊ฐ๋ ฅํ ๊ทธ๋ํฝ ๋ฐ์คํฌํ ๊ณต์ ์์คํ ์ ๋๋ค. VNC๋ฅผ ์ฌ์ฉํ๋ฉด ์ฌ์ฉ์๊ฐ ํค๋ณด๋ ๋ฐ ๋ง์ฐ์ค ์ด๋ฒคํธ๋ฅผ ์๋ฐฉํฅ์ผ๋ก ์ ์กํ์ฌ ์๊ฒฉ ์ปดํจํฐ์ ์ํํ๊ฒ ์ํธ์์ฉํ ์ ์์ต๋๋ค. ์ด๋ฅผ ํตํด ์ค์๊ฐ ์ก์ธ์ค๊ฐ ๊ฐ๋ฅํ๋ฉฐ ๋คํธ์ํฌ๋ฅผ ํตํ ํจ์จ์ ์ธ ์๊ฒฉ ์ง์ ๋๋ ํ์ ์ ์ด์งํฉ๋๋ค.
VNC๋ ์ผ๋ฐ์ ์ผ๋ก **5800 ๋๋ 5801 ๋๋ 5900 ๋๋ 5901** ํฌํธ๋ฅผ ์ฌ์ฉํฉ๋๋ค.
```
PORT STATE SERVICE
5900/tcp open vnc
```
## ์ด๊ฑฐ
```bash
nmap -sV --script vnc-info,realvnc-auth-bypass,vnc-title -p
msf> use auxiliary/scanner/vnc/vnc_none_auth
```
### [**๋ฌด์ฐจ๋ณ ๋์ ๊ณต๊ฒฉ**](../generic-methodologies-and-resources/brute-force.md#vnc)
## Kali๋ฅผ ์ฌ์ฉํ์ฌ vnc์ ์ฐ๊ฒฐํ๊ธฐ
```bash
vncviewer [-passwd passwd.txt] ::5901
```
## VNC ๋น๋ฐ๋ฒํธ ๋ณตํธํ
๊ธฐ๋ณธ **๋น๋ฐ๋ฒํธ๋ ์ ์ฅ๋ฉ๋๋ค**: \~/.vnc/passwd
VNC ๋น๋ฐ๋ฒํธ๊ฐ ์๊ณ ์ํธํ๋ ๊ฒ์ฒ๋ผ ๋ณด์ธ๋ค๋ฉด(๋ช ๋ฐ์ดํธ, ์ํธํ๋ ๋น๋ฐ๋ฒํธ์ผ ์ ์๋ ๊ฒฝ์ฐ), ์๋ง๋ 3des๋ก ์ํธํ๋ ๊ฒ์ ๋๋ค. [https://github.com/jeroennijhof/vncpwd](https://github.com/jeroennijhof/vncpwd)๋ฅผ ์ฌ์ฉํ์ฌ ํ๋ฌธ ๋น๋ฐ๋ฒํธ๋ฅผ ์ป์ ์ ์์ต๋๋ค.
```bash
make
vncpwd
```
You can do this because the password used inside 3des to encrypt the plain-text VNC passwords was reversed years ago.\
For **Windows** you can also use this tool: [https://www.raymond.cc/blog/download/did/232/](https://www.raymond.cc/blog/download/did/232/)\
I save the tool here also for ease of access:
{% file src="../.gitbook/assets/vncpwd.zip" %}
## Shodan
* `port:5900 RFB`
If you are interested in **hacking career** and hack the unhackable - **we are hiring!** (_์ ์ฐฝํ ํด๋๋์ด ํ๊ธฐ ๋ฐ ๊ตฌ์ฌ ํ์_).
{% embed url="https://www.stmcyber.com/careers" %}
{% hint style="success" %}
Learn & practice AWS Hacking:[**HackTricks Training AWS Red Team Expert (ARTE)**](https://training.hacktricks.xyz/courses/arte)\
Learn & practice GCP Hacking: [**HackTricks Training GCP Red Team Expert (GRTE)**](https://training.hacktricks.xyz/courses/grte)
Support HackTricks
* Check the [**subscription plans**](https://github.com/sponsors/carlospolop)!
* **Join the** ๐ฌ [**Discord group**](https://discord.gg/hRep4RUj7f) or the [**telegram group**](https://t.me/peass) or **follow** us on **Twitter** ๐ฆ [**@hacktricks\_live**](https://twitter.com/hacktricks\_live)**.**
* **Share hacking tricks by submitting PRs to the** [**HackTricks**](https://github.com/carlospolop/hacktricks) and [**HackTricks Cloud**](https://github.com/carlospolop/hacktricks-cloud) github repos.
{% endhint %}