Hardening an exposed server: the minimal list that changes everything
An exposed server receives intrusion attempts within an hour of going live. The good news: almost all of them target services that had no reason to be reachable.
RGAIX team · · 7 min read
Start by closing, not by watching
The first measure is not a detection tool: it is the inventory of what listens on the network. A database, an administration interface or a monitoring dashboard reachable publicly are open doors, whatever the rules behind them.
- List the ports actually open from outside, not the ones in the configuration.
- Put everything that can be behind a reverse proxy or a tunnel.
- Restrict administration access to a VPN or to known addresses.
- Leave public only the services that must be: web, and nothing else by default.
Access: keys, separate accounts, revocation
Password authentication on remote access must be disabled. Each person has their own key and their own account: that is what allows revoking access without general coordination, and knowing who did what.
Plan the exit as much as the entry. The question “what happens if this key leaks tonight?” must have an answer in one command, not in a meeting.
Limit what gets through anyway
| Measure | What it stops | What it does not stop |
|---|---|---|
| Rate limiting by address | Brute force, mass scanning | A slow, targeted attack |
| Automatic banning | Repetition from one source | Distributed sources |
| Geographic filtering | Regional background noise | Proxies and VPNs |
| Regular updates | Exploitation of known flaws | Undisclosed vulnerabilities |
No line is enough on its own. Their value is cumulative: they reduce the noise until the attempts that deserve human attention become visible.
Make the logs usable before you need them
Logs kept only on the machine concerned disappear with it. A copy off the server, with sufficient retention, is what will separate an investigation from a guess.
Check as well that the visitor’s real address reaches the application: behind a badly configured proxy, every access appears to come from the same internal address, and any analysis becomes impossible.
Check from the outside, regularly
Hardening is verified from the internet, not from the configuration. A monthly scan of open ports and a certificate check are enough to detect drift: a service exposed temporarily for a test, and never closed again.
The best protection remains the surface you do not expose. Everything else consists of watching what you could not close.
Related pages
Private cloud, servers & architecture
Design, operate and sustain your platform.
Discover the service ↗READ NEXTIncident response: collect the evidence before cleaning up
Cleaning a compromised server without looking for the entry point guarantees a repeat. The order of the steps matters more than their speed.
Read the article ↗READ NEXTPaid search: connecting media budget to genuinely useful enquiries
An ad account optimised on the wrong conversions spends efficiently for a useless result.
Read the article ↗Let’s talk about what is blocking you.
An emergency, a profile to find or a project to structure: let’s start with your need.
