Common attacks and weaknesses
- SID enumeration and brute force.
- TNS poisoning on old versions.
- Default accounts (scott/tiger).
Oracle Database TNS listener (IANA lists ncube-lm, but 1521 is Oracle's default).
The application sends a SQL query to the Oracle Database server on port 1521, which returns rows from its tables. Encryption is optional: traffic is only protected if TLS is enabled on the server and the client.
Unofficial use. The IANA assignment below differs from what is usually found on this port in practice.
| Service | Port | Transport | Description | Reference | Updated |
|---|---|---|---|---|---|
| ncube-lm | 1521 | TCP, UDP | nCube License Manager Reported: Unauthorized Use Known on port 1521 | - | 2022-02-14 |
// source: IANA service name and port number registry
Linux
sudo ss -ltnup 'sport = :1521' # process listening on 1521
sudo lsof -nP -i :1521macOS
sudo lsof -nP -i :1521
Windows (PowerShell)
Get-NetTCPConnection -LocalPort 1521 -State Listen | Select LocalAddress, OwningProcess Get-NetUDPEndpoint -LocalPort 1521 netstat -ano | findstr :1521
From another machine
nmap -p 1521 -sV <host> sudo nmap -sU -p 1521 <host> nc -zv <host> 1521
Block it in the firewall
sudo ufw deny 1521/tcp # Linux (ufw) New-NetFirewallRule -DisplayName "Block 1521" -Direction Inbound -LocalPort 1521 -Protocol TCP -Action Block # Windows
Oracle Database TNS listener (IANA lists ncube-lm, but 1521 is Oracle's default).
Port 1521 is registered for TCP and UDP. In practice the service mostly uses TCP.
It is rated 8/10 (high) when exposed to the Internet. SID enumeration and brute force. Restrict to application servers.
On Linux run "ss -ltnup 'sport = :1521'", on macOS "lsof -nP -i :1521", and on Windows "netstat -ano | findstr :1521" to see the local process. From another machine, "nmap -p 1521 <host>" shows whether it is reachable.