PortScan › Port guide › Port 9200
Port 9200 (Elasticsearch): A Recurring Cause of Massive Data Leaks
Port 9200 is the Elasticsearch REST API. Unauthenticated clusters open to the internet have caused many huge data leaks. 8.x security defaults and checks.
What is port 9200?
Elasticsearch is a database for search and log analytics; port 9200 is its HTTP REST API and 9300 is used for node-to-node communication. It is widely used for log collection (the ELK stack), product search and searching member data.
Free versions before 7.x long had no authentication by default; starting with 8.0, security features (authentication and TLS) are on by default. The core problem is old clusters left open to the internet as-is.
When it is normally open
- Log and search clusters on the internal network — only Kibana or the application should be exposed externally
Risks if it is open
Data exposed without authentication
Simply opening http://IP:9200/_cat/indices in a browser lists every index. Security researchers have reported, year after year, cases where hundreds of millions of member records and log entries were left open this way.
Deletion and ransom
Attacks that delete exposed indices and leave only a ransom note have also happened repeatedly.
Security checklist
- Keep
network.hoston an internal address and do not open 9200 or 9300 to the internet. - Turn on security features:
xpack.security.enabled: true(the default in 8.x). Set passwords for the built-in accounts. - In Docker,
-p 9200:9200exposes it on every interface. Use127.0.0.1:9200:9200. - Keep it on the latest supported version.
How to check whether port 9200 is open
From outside (is it exposed to the internet?)
Whether your server or home router accepts port 9200 from the internet can only be confirmed by connecting from outside. A check from inside the same network bypasses the router's firewall and gives a different answer.
PortScan opens a real TCP connection from the Cloudflare edge and reports Open, Closed or Filtered. Members can scan every port on their own IP for free and other targets free once a day.
Check port 9200On the server (what is listening?)
Windows (PowerShell):
netstat -ano | findstr ":9200 "
Get-NetTCPConnection -LocalPort 9200 -State Listen | Select LocalAddress,OwningProcess
Linux:
sudo ss -tlnp | grep ':9200 '
If it listens on 0.0.0.0 or [::] it is open on every network; 127.0.0.1 means only that machine can connect. To test port 9200 on a server from another computer, use Test-NetConnection server-address -Port 9200 on Windows or nc -vz server-address 9200 on Linux and macOS.
How to close or restrict port 9200
The best fix is to turn the service off or make it listen only on 127.0.0.1 (see the checklist above). If you need the service but must keep it off the internet, use a firewall.
Windows Firewall
# Administrator PowerShell
New-NetFirewallRule -DisplayName "Block TCP 9200" -Direction Inbound -Protocol TCP -LocalPort 9200 -Action Block
# To allow a single IP instead (block rules take precedence, so use this instead of the rule above)
New-NetFirewallRule -DisplayName "Allow TCP 9200 from office" -Direction Inbound -Protocol TCP -LocalPort 9200 -RemoteAddress 203.0.113.10 -Action Allow
Linux (ufw)
sudo ufw deny 9200/tcp
# Allow a single IP only
sudo ufw allow from 203.0.113.10 to any port 9200 proto tcp
On a cloud server, also check port 9200 in the security group (inbound rules), which is separate from the OS firewall. For services running in Docker, the rules Docker creates can bypass ufw, so binding the port to localhost with -p 127.0.0.1:9200:9200 is the reliable option.
Router
At home or in a small office, open the router's admin page and check whether port 9200 is in the port forwarding list, whether DMZ is enabled, and whether any program opened ports by itself through UPnP. If any of the three applies, port 9200 on your PC is directly visible from the internet.
How to read the scan result
- Open — something accepted a connection on port 9200. Work through the risks above.
- Closed — the packet reached the device, but nothing is listening on that port, so it was refused immediately (RST). The service is off.
- Filtered — no response. A firewall or the ISP is dropping packets, or the device is off. From an exposure point of view this is the safest state.
The verdict can depend on where you connect from. Many ISPs (including most Korean ISPs) block some ports such as 135, 139 and 445 on their network, so the same server can look Filtered from inside that network and Closed from abroad.
FAQ
- Does Kibana (5601) have the same problem?
- Yes. An unauthenticated Kibana displays your Elasticsearch data on screen for anyone. Check port 5601 as well.
Related ports
Last updated 2026-11-04 · Use this guide to check systems you manage. Scanning systems without permission may carry legal liability.