Monitoring and detection
Logs, SIEM, EDR, SOC, MITRE ATT&CK: why attacks go unnoticed for days on end, and how an SME can organise its threat detection in practice.
What you will learn
- Understand why attackers often stay for days, or even months, without being seen
- Know which logs to collect, how to protect them and how long to keep them
- Tell SIEM, EDR, XDR, SOC and MDR apart, and choose between in-house and outsourced monitoring
- Use MITRE ATT&CK to measure what you can detect, and what slips past you
- Reduce alert fatigue and track indicators such as MTTD and MTTR
- Build a realistic detection plan for an SME
Most organisations invest in protection first: firewalls, antivirus, passwords. That is essential, but no protection is perfect. The real question then becomes: if someone gets in, how long will it take you to notice? This chapter explains how an information system is monitored, with which tools and which teams, and where to start if you are an SME.
Why are attacks detected so late?
Every year, Mandiant (Google Cloud) publishes M-Trends, a report drawn from its investigations of real intrusions: more than 500,000 hours of investigation in 2025. One of the things it measures is dwell time, the gap between an intrusion and its discovery.
That median hides wide gaps. For espionage, carried out by patient APTAPT (advanced persistent threat)A highly organised group of attackers, often linked to a state, that quietly gains long-term access to a targeted network to spy, steal secrets or prepare sabotage. groups, and for fake IT workers hired remotely on behalf of North Korea, it reached 122 days. Above all, in only 52% of cases did the organisation spot the malicious activity itself in 2025 (43% in 2024). In the remaining cases, the alert came from outside: a partner, the authorities, or the attacker themselves, when demanding a ransom.
The reasons are nearly always the same:
- Missing or scattered logs that nobody reads.
- Blind spots: according to Mandiant, some groups deliberately target VPNs and routers, where no security agent is installed.
- Legitimate tools turned against you: attackers use the same administration tools as your staff, which helps them stay under the radar.
- Nobody watching at night or at weekends, times attackers favour.
- Too many alerts, so the one that matters goes unnoticed.
Logs: your system’s memory
A log is a timestamped record of what happens on a device: a login, a change of permissions, a deleted file. Without logs, you can neither detect an attack in progress nor reconstruct what happened.
What to collect
ANSSI, the French national cybersecurity agency, published version 2.0 of its recommendations for the architecture of a logging system in January 2022. It describes a minimum baseline: successful and failed logins, account creation, privileges granted, additions to groups, changes to security settings, log deletion and access to sensitive resources. In practice, the priority sources are:
| Source | Examples of useful events |
|---|---|
| Company directory (Active DirectoryActive Directory (AD)Microsoft’s directory service, which centralises the accounts, passwords and permissions of most corporate Windows networks: whoever controls it controls the whole network. or cloud directory) | bursts of failed logins, account creation, additions to the administrators group |
| Email and online office suite | login from an unusual country, new automatic forwarding rule |
| Remote access (VPN, remote desktop) | logins, origin, times |
| Firewall, proxy, DNS | connections to unknown domains, blocked traffic |
| Workstations and servers | scripts launched, antivirus disabled, logs cleared |
| Backups and virtualisation | backups deleted, virtual machines shut down en masse |
ANSSI advises a step-by-step approach: quickly obtain a first set of properly logged, usable events, then build on it. Completeness is an end goal, not a prerequisite.
Timestamp, centralise, protect
- Synchronise the clocks of all devices to consistent time sources (the NTP protocol), accurate to at least one second. Otherwise, you cannot rebuild the timeline.
- Centralise logs on dedicated collection servers in a trusted zone: an attacker who wipes the traces on one machine must not be able to wipe the copy.
- Protect them: deletion rights limited to a few accounts, an alert whenever logs are cleared, offline archiving. The CNIL also recommends timestamping and signing logs as soon as they are created.
How long should you keep them?
CNIL recommendation (deliberation no. 2021-122 of 14 October 2021). For the logs of applications that process personal data, France’s data protection authority recommends keeping them for between six months and one year in the general case; ANSSI uses the same range as its reference. A longer period, up to three years in common cases, can be justified for certain internal controls, and the need to analyse an attack can justify keeping the traces needed for the investigation for longer. It also recommends automated log analysis with a process for handling alerts, and informing the users concerned.
Mandiant points the same way: given long-running intrusions, it advises going beyond the 90 days of retention often offered by default, and centralising network device logs too.
The tools: SIEM, EDR and XDR
| Tool | What it does | Its limit |
|---|---|---|
| SIEMSIEM (security information and event management)A tool that centralises logs from across the information system, correlates them and raises an alert when a combination of events gives an attack away. | Centralises logs from every source, correlates them and raises alerts based on rules | Only as good as its logs and rules; costly to feed |
| EDREDR (endpoint detection and response)Software installed on computers and servers that watches their behaviour, detects malicious activity and lets defenders isolate or clean up a machine remotely. | An agent on every workstation and server that watches processes and can isolate a machine remotely | Blind wherever there is no agent (VPNs, routers, printers) |
| XDR | Extends EDR to email, identities, cloud and network, with built-in correlation | Often tied to a single vendor |
For an SME, EDR on every workstation and server is often the most cost-effective first investment: it sees suspicious behaviour and can cut a machine off in seconds. A SIEM becomes worthwhile when sources multiply and you need to cross-check events from different devices.
In-house SOC or outsourced service?
A SOCSOC (security operations centre)The team and tools that monitor the information system around the clock to detect security incidents, assess them and trigger the response. (security operations centre) is the team that monitors alerts, triages them, investigates and triggers the response. It is the blue teamBlue teamThe team that defends the information system day to day: monitoring, detecting attacks, responding to them and hardening configurations.’s job. Round-the-clock monitoring requires several analysts working in shifts, which is beyond the means of most SMEs. Hence the rise of managed detection and response (MDR) services, where a provider watches your tools and acts on your behalf.
| Criterion | In-house SOC | Outsourced service (MDR) |
|---|---|---|
| Knowledge of your context | Excellent | Has to be built, depends on onboarding |
| 24/7 monitoring | Expensive | Usually included |
| Cost | Recruitment, tools, training | Subscription |
| Authority to act | Direct | To be defined in the contract |
In France, ANSSI qualifies security incident detection providers (PDIS) and incident response providers (PRIS) against public requirement frameworks. Before signing, ask at least these questions: who can isolate a workstation at 3 a.m., and on whose decision? What response times are guaranteed? Where are your logs hosted? Do you get your rules and data back if you switch provider?
Indicators or behaviour: two ways to recognise an attacker
An indicator of compromiseIndicator of compromise (IoC)A technical trace suggesting that a system has probably been compromised: a malicious IP address or domain, a file hash, a process name, a registry key. (IoC) is a known technical trace: an IP address, a domain name, the hash of a malicious file. It is precise and easy to search for, but it goes stale quickly, because attackers change it effortlessly. Threat intelligenceThreat intelligence (CTI)Information gathered and analysed about attackers (who they are, what they target, how they operate) to guide defence decisions. feeds publish new ones every day.
Behaviour, on the other hand, describes a way of operating: an office document launching a script, an account logging in from two countries within an hour, thousands of files renamed in minutes, backups deleted. These methods change far more slowly. Good detection combines both: IoCs to catch known threats quickly, behaviour to spot new ones.
MITRE ATT&CK: knowing what you see, and what slips past you
MITRE ATT&CKMITRE ATT&CKA free knowledge base, maintained by the US not-for-profit organisation MITRE, that describes the tactics and techniques attackers actually use, based on public observations. is a free, public knowledge base describing the techniques attackers actually use, as observed in real incidents. In version 19 (April 2026), its Enterprise matrix contains 15 tactics (the broad goals: initial access, persistence, privilege escalation, exfiltration and so on), 222 techniques and 475 sub-techniques. This version notably split the former Defense Evasion tactic in two: Stealth and Defense Impairment.
It serves three purposes:
- Mapping your coverage: for each detection rule, note the technique it covers. The empty cells show your blind spots.
- Prioritising: focus on the techniques used by groups that target your sector, and on those common to almost every attack (credential theft, abuse of administration tools, destruction of backups).
- Testing: a purple team exercise, where attackers and defenders work together, or a penetration test will show whether your rules really fire.
Aiming for 100% coverage is an illusion. Detecting the twenty most likely techniques well beats detecting two hundred badly.
Alerts and alert fatigue
A poorly tuned tool can produce hundreds of alerts a day, the vast majority of them false positives. Analysts end up skimming them, and the real attack slips through in the flood. That is alert fatigue. To fight it:
- Tune every rule that keeps firing wrongly, or remove it.
- Rank alerts by the criticality of the asset involved: a payroll server is not a reception kiosk.
- Enrich each alert automatically (who is the user, which machine, is this usual?) so the analyst can decide quickly.
- Attach a course of action to each type of alert: if nobody knows what to do, the alert is pointless.
Measuring: MTTD, MTTR and a few others
Two indicators dominate:
- MTTD (mean time to detect): the average time between the start of an incident and its detection.
- MTTR (mean time to respond, sometimes to recover): the average time between detection and containment, or a return to normal, depending on the definition you adopt.
Add coverage measures: the share of workstations and servers with EDR, the share of log sources centralised, the ATT&CK techniques covered, the false positive rate and the time needed to isolate a machine.
Define your stopwatches precisely. Does MTTR start at the first alert or at confirmation? Does it stop at containment or at a return to normal? Without a written definition, your figures will be comparable neither from one quarter to the next nor with your provider’s.
A realistic plan for an SME
- Identify your critical assets: customer data, payroll, production, administrator accounts. That is where detection must be at its best.
- Switch on the logs you already have: email and online suite, directory, VPN, firewall. Synchronise clocks, centralise, keep for six months to a year.
- Deploy EDR on all workstations and servers, with someone to respond: a trained person in-house, or an MDR service if you have no team.
- Turn on identity alerts: geographically impossible logins, new administrators, multi-factor authenticationMulti-factor authentication (MFA)A login that requires at least two proofs of identity of different kinds (something you know, something you have, something you are), so that a stolen password is no longer enough. being disabled, email forwarding rules.
- Write about ten priority scenarios: backups deleted, logs cleared, mass file encryption typical of ransomware, an administrator logging in in the middle of the night.
- Formalise escalation: who calls whom, who can isolate a machine, who informs management. This is the first link in your incident responseIncident responseThe organised set of actions taken to detect an attack, limit the damage, drive the attacker out, restore operations and learn the lessons. (chapter 15).
- Test: an exercise or a penetration test shows whether you saw what you needed to see.
- Review every quarter: noisy rules, blind spots, indicators.
Detection is never finished. But an SME that knows within the hour that an administrator account was created at 3 a.m. is already a step ahead of most attackers.
Key takeaways
- In 2025, attackers stayed a median of 14 days inside their victims before being discovered, and nearly half the time the alert came from outside.
- Without centralised, timestamped and protected logs, neither detection nor investigation is possible; France’s CNIL recommends keeping them for six months to a year.
- A tool detects nothing on its own: you need people who read the alerts and can act, in-house or through an outsourced service.
- Attacker behaviour is a more durable thing to detect than technical indicators, which attackers change in minutes.
- A few reliable rules, all handled, beat thousands of ignored alerts; measure how long you take to detect and respond.
Were you paying attention?
Three questions to check, no score, no account.
Sources
- ANSSI, Recommandations de sécurité pour l’architecture d’un système de journalisation (v2.0, 28 January 2022)
- CNIL, deliberation no. 2021-122 of 14 October 2021 adopting a recommendation on logging
- ANSSI, security incident detection providers (PDIS)
- ANSSI, requirement frameworks for qualified providers (PDIS, PRIS)
- CERT-FR (ANSSI), French government computer emergency response team
- NIST SP 800-61 Rev. 3, Incident Response Recommendations and Considerations for Cybersecurity Risk Management (April 2025)
- NIST, Cybersecurity Framework 2.0
- Mandiant (Google Cloud), M-Trends 2026
- MITRE ATT&CK
- MITRE ATT&CK, April 2026 release notes (v19)