Join our Newsletter — 33% off our NHI Course

What are the key On-Access Scanning best practices?

On-Access Scanning should inspect files as they are opened, read, or executed, with exclusions kept as narrow as possible. Best practice is to tune performance impact, ensure archive and script handling is enabled where supported, and log detections centrally. Security teams should regularly test whether scanning still covers new file types and paths.

How On-Access Scanning should behave at the point of execution

On-access scanning is most effective when it behaves like a gate, not a background afterthought. The control should inspect files as they are opened, read, or executed, because that is the point where malicious content is most likely to become active. When the scanner is too permissive, too delayed, or too narrowly scoped, it stops being a preventive control and becomes a partial visibility tool.

That operating model also means the control has to be predictable under normal user and application load. If the scanner repeatedly slows launches, file access, or build workflows, teams tend to weaken it through broad exclusions or disablement. The practical goal is to preserve protection without making the endpoint unusable.

For endpoint coverage and response context, the Endpoint Security Guide is a useful companion because it covers telemetry, hardening, host isolation, and the broader control stack that makes scanning effective.

Which file paths, file types, and content flows matter most

Exclusions should be narrow and justified, not broad and permanent. Best practice is to exclude only where the business case is clear, such as known performance hot spots, trusted temporary directories, or vendor paths that would otherwise create unacceptable overhead. Every exclusion should be reviewed as a security decision, because exclusions are often the easiest place for malware to hide.

Coverage also needs to match the way modern content actually enters the system. Archive handling and script handling should be enabled where supported, because compressed files, nested archives, and scripts are common delivery paths for payloads. If those paths are not scanned, the control may appear to be working while missing the most relevant execution channels.

For lifecycle-oriented control hygiene, the NHI Lifecycle Management Guide aligns with the same operational principle of keeping discovery, visibility, and review current as environments change.

How to keep On-Access Scanning useful as the environment changes

On-access scanning should be treated as a living control that needs periodic validation. New file types, new mount points, new application paths, and new developer or automation workflows can all bypass old assumptions. Regular testing should confirm that scanning still triggers where it is supposed to, especially after storage changes, endpoint agent updates, or application rollouts.

Central logging matters because local detection without central visibility is hard to operationalise. Security teams should route detections into a central platform so they can correlate repeated hits, spot suspicious file access patterns, and distinguish genuine malicious activity from noisy but benign scanning events. That logging also supports tuning decisions, because it shows which events are frequent, disruptive, or genuinely useful.

When file access involves cloud credentials or other sensitive material, response playbooks should already assume that the file may have been exposed before the alert fired. The Cloud Credential Compromise Playbook is relevant here because quick containment, log review, and session cleanup often matter more than the original malware name.

Risk and Threat Considerations

Weak on-access scanning creates two distinct problems: it can miss active malware in the moment of execution, and it can push administrators toward broad exclusions that quietly reduce protection across the estate. Attackers benefit from both outcomes, especially when scripts, archives, shared paths, or high-noise directories are treated as exceptions.

Failure mechanism: The control is bypassed when exclusions are too broad, when archive or script inspection is disabled, or when new file locations are introduced without retesting. In those cases, malicious content can reach execution or remain invisible in the most relevant access paths.

Impact: The endpoint may still look protected while allowing malware staging, payload delivery, or repeated access to go undetected. Over time, the blind spot can extend to multiple teams and workflows if the same exclusion pattern is copied across systems.

Standards & Framework Alignment

This section maps relevant standards and security frameworks to the operational risks and controls described in this guidance.

CIS Controls v8, NIST SP 800-53 Rev 5 and OWASP ASVS set the technical controls, while ISO/IEC 27001:2022 defines the regulatory obligations.

Framework Control / Reference Relevance
CIS Controls v8 CIS-10 — Malware Defenses On-access scanning directly reduces malware execution risk on endpoints.
Recommendation — Tune malware scanning to inspect files at access and verify exclusions stay minimal.
NIST SP 800-53 Rev 5 SI-3 — System and Information Integrity – Malicious Code Protection On-access scanning is a direct malicious-code protection control for file access and execution.
AU-6 — Audit Review, Analysis, and Reporting Central logging and review of detections are material to operating on-access scanning effectively.
Recommendation — Enable malicious code protection on file-open, file-read, and file-execute events. Centralize scan detections and review them for repeated hits and coverage gaps.
ISO/IEC 27001:2022 A.8.7 — Protection Against Malware Malware protection controls encompass endpoint scanning, exclusions, and coverage validation.
Recommendation — Apply malware protection controls and confirm they still cover new paths and file types.
OWASP ASVS V13 — Configuration Scanner exclusions and coverage settings are security-relevant configuration decisions.
Recommendation — Review security-relevant scanning configuration changes and keep exceptions narrowly scoped.

Practitioner Guidance

What to verify: Confirm that the scanner triggers on open, read, and execute events for the file types your environment actually uses, including archives and scripts where the product supports them. Re-test after major endpoint, storage, or application changes rather than assuming the last tuning decision still holds.

Common mistake: Treating performance complaints as a reason to disable inspection broadly. If tuning is necessary, constrain the exception to the smallest path, process, or content class that solves the problem, then document why it is safe enough to keep.

What good looks like: Detections are centrally visible, exclusions are rare and reviewable, and operations teams can show that scanning still covers new paths and file types after change events.

Practitioner takeaway: The best On-Access Scanning programmes preserve inspection at the exact moment content becomes executable, while keeping every exception narrow enough that it can be defended in a security review.