Nmap Oracle TNS Listener Enumeration
Oracle TNS listener enumeration extracts the listener version and discovers the SIDs and service names needed to attempt database connections. Without a valid SID or service name, no connection is possible regardless of credentials. The listener typically runs on port 1521 but can be on any port. SIDs discovered here feed directly into connectivity checks and credential testing.
Service Detection
1521/tcp open oracle-tns Oracle TNS listener 11.2.0.2.0
Pull Listener Version
| oracle-tns-version: | Version: TNSLSNR for Linux: Version 11.2.0.2.0 | Start Date: 28-MAR-2026 09:00:00 |_ Uptime: 0 days 3 hr. 0 min. 22 sec
The exact version determines which CVEs apply and helps gauge how hardened the installation is. Older versions (10g, 11g) are more likely to have weak default accounts still active. Cross-reference immediately with searchsploit.
SID Discovery
oracle-sid-brute tests common SID names against the listener. Any discovered SID is immediately usable in connection strings:
| oracle-sid-brute: | orcl | prod |_ XE
Multiple SIDs mean multiple databases behind one listener — treat each as a separate target. XE (Express Edition) is common in lab environments and typically has weaker default configurations. Store all discovered SIDs for use in the next steps.
Run Both Scripts Together
When Scripts Return Nothing
Some listeners restrict status queries. When nmap returns nothing despite the port being open, fall back to ODAT and direct client probes:
Connection to 10.10.10.50 1521 port [tcp/oracle] succeeded! port reachable
Port reachable but scripts empty means the listener is filtering metadata queries. Move to ODAT listener enumeration and tnsping/sqlplus connectivity checks.
References
-
nmap — oracle-tns-version NSEnmap.org/nsedoc/scripts/oracle-tns-version.html (opens in new tab)
Listener version detection
-
nmap — oracle-sid-brute NSEnmap.org/nsedoc/scripts/oracle-sid-brute.html (opens in new tab)
Common SID discovery against TNS listener
Was this helpful?
Your feedback helps improve this page.