realpath

c · standard library
sinkDerived from model facts
RoleSink
WeaknessCWE-120 · CWE-22 · CWE-785
WatchesArgument[0]
Kindpath-traversal
Confidencelow
Corroboration1

Sink boundary: Input participates in a filesystem path that should remain inside a trusted directory.

Argument map · what each slot does

The pack does not provide a callable signature for this record; the watched access path is shown directly.

ArgAccess pathPurposeWatched
Argument[0]Argument[0]The access path Atropos marks for this model.▲ sink
The weakness
CWE-120
Classic Buffer Overflow

Input is copied into an output buffer without checking that it fits.

CWE-22
Path Traversal

External input constructs a pathname that can escape its intended directory.

CWE-785
Path Function Without Maximum-sized Buffer

A path operation writes into a buffer smaller than its maximum possible output.

What goes wrong
Attacker's-eye view · path-traversal

Traversal segments, absolute paths, or links escape the intended root and reach another resource.

// modeled boundary: Argument[0] realpath(attacker_influenced_value);
To decide if this call is a bug, check
1Resolve against a fixed root.
2Reject traversal and unexpected schemes.
3Check the resolved path before access.
These checks require the surrounding codebase. The model names the boundary; it does not decide reachability or prove that a guard dominates every path.
Is this a bug in your code?Atropos stops here — by design

Atropos identifies Argument[0] as a path-traversal sink. It cannot see whether untrusted data reaches this call in your repository.

Lachesis is the codebase-level step: it traces reachability and guards for this symbol.

Check this symbol in Lachesis
The family · path-traversal
Model facts · verbatim from the pack
RoleKindAccess pathModel IDConfidence
sinkpath-traversalArgument[0]c.std.realpath.a0low · corrob. 1
summarytransformArgument[0] -> Argument[1]c.std.realpath.a0-a1high · corrob. 2
summarytransformArgument[0] -> ReturnValuec.std.realpath.a0-rethigh · corrob. 2