Join our Newsletter — 33% off our NHI Course

How can security teams detect NTFS Hard Link?

Security teams detect NTFS Hard Link abuse by identifying files that point to the same underlying content while appearing under different names. Focus on sensitive executables or scripts in user-writable paths, unexpected changes to one link affecting another, and tampering that bypasses path-based controls. Compare file metadata and watch for links created to hide persistence or evade detection.

ntfs hard link are a file system feature, but they become a detection problem when the same underlying file content is reachable through multiple names. That matters because many controls and investigations reason from the path, while the operating system may treat the content as the same object. The practical consequence is that a file can be renamed, relocated through another link, or hidden in a user-writable path without changing the bytes defenders are trying to monitor.

Detection should therefore start with the file object, not just the pathname. Compare metadata that reveals whether multiple names resolve to the same underlying file, and look for sensitive executables or scripts that appear in unexpected locations. A hard link is especially suspicious when it lets a file in a trusted location and a file in a less trusted location behave as one object.

Security teams also need to watch for state changes that propagate across links. If a modification in one path appears in another path that should be independent, that is a strong signal that the paths are aliases to the same object. That pattern is useful both for investigation and for distinguishing legitimate file reuse from abuse intended to obscure persistence or tampering.

What to look for during triage and hunting

Good hunts focus on where hard links are most likely to be abused: user-writable directories, staging areas, temporary locations, and paths that are commonly trusted by logics or policy engines. A link that points to a script, service binary, or scheduled task artifact can be used to make a malicious file appear benign, or to make a benign-looking path point back to a sensitive object.

MITRE D3FEND Guide is useful here because the defensive work is not only discovery, but also file metadata analysis, executable verification, script execution analysis, and local file access mediation. Those are the kinds of controls that help security teams separate normal file usage from path-based abuse.

Hunting is strongest when it combines file inventory with process context. If a suspicious process creates or touches files that later show up under alternate names, or if a file in a sensitive path shares identity with content created elsewhere, the link relationship itself becomes part of the signal. The key question is not only “what file is this?” but “what else points to the same underlying object?”

CWE Top 25 Guide helps frame the underlying weakness pattern, especially path equivalence, insecure file handling, and race-condition style problems that let attackers exploit how the file system interprets names versus objects. That perspective is useful when a detection rule must account for object identity, not just a string comparison on the path.

Once a hard link is confirmed, the response should focus on why the link exists and what it changes operationally. If it is tied to a persistence mechanism, a service path, or a control bypass, treat it as a containment issue rather than a cosmetic file-system oddity. Investigate whether the same content is reachable from a path that should have been blocked, especially when path-based allowlists or monitoring rules were expected to stop it.

Defensive verification should include whether the file’s ownership, location, and expected use still make sense together. A hard link used to disguise malicious content often succeeds because one path looks normal while another path carries the real operational risk. That is why responders should inspect the full set of references, not only the path that first triggered the alert.

Risk and Threat Considerations

Hard links create a detection gap when defenders trust paths more than file identity. An attacker can use that gap to keep the same content reachable through a safer-looking name, which can weaken path-based allowlists, conceal persistence, or make malicious changes appear to happen in an unexpected location.

Failure mechanism: The same inode or underlying file content is referenced by multiple names, so controls that key off directory name, file name, or path reputation can miss the real execution or modification surface.

Impact: Security teams may miss tampering, misattribute changes, or fail to block a file that is still reachable through an alternate trusted path. That can extend persistence and complicate containment.

Standards & Framework Alignment

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

MITRE ATT&CK addresses the attack and risk surface, while CIS Controls v8 and NIST SP 800-53 Rev 5 set the governance and control requirements practitioners need to meet.

Framework Control / Reference Relevance
MITRE ATT&CK T1096 — System Time Discovery Hard links affect file-system object visibility and can hide persistence paths.
Recommendation — Hunt for file-link abuse patterns that conceal persistence or tamper with trusted paths.
CIS Controls v8 CIS-4 — Secure Configuration of Enterprise Assets and Software Detecting hard-link abuse relies on secure file-system and endpoint configuration baselines.
Recommendation — Baseline endpoint file-system settings and alert on unexpected link creation in sensitive paths.
NIST SP 800-53 Rev 5 SI-3 — Malicious Code Protection Hard-link abuse can disguise malicious scripts or executables in trusted locations.
AU-6 — Audit Record Review, Analysis, and Reporting Investigation depends on correlating file changes, object identity, and path activity.
CM-5 — Access Restrictions for Change Link abuse can bypass path-based change restrictions and alter sensitive content.
Recommendation — Scan executable and script objects for alternate references before trusting the path. Correlate file events with object-level metadata to spot changes that follow a hard link. Restrict who can create links in sensitive directories and review exceptions tightly.

Practitioner Guidance

What to verify: Confirm whether the suspicious names resolve to the same underlying file object before you decide the event is benign. If metadata, reference counts, or cross-path change behavior do not line up with the expected file lifecycle, treat it as a potential abuse case.

Decision rule: If the hard link connects a sensitive binary or script to a user-writable or otherwise unexpected path, prioritise containment and path-review over simple file-name cleanup. The operational risk comes from the alternate access path, not just from the file name itself.

Practitioner takeaway: The most reliable detection mindset is object-centric, not path-centric, because hard links let one file masquerade as many names while still preserving a single underlying payload.