Utilities

PyNtpath

Python stdlib module — ntpath. Auto-indexed from CDN. Method-level security roles have not been annotated; rule writers should inspect the source before use.

Other Methods

.abspath()Neutral
#
Signature
abspath(path)

Return the absolute version of a path as a fallback function in case

.basename()Neutral
#
Signature
basename(p)

Returns the final component of a pathname

.commonpath()Neutral
#
Signature
commonpath(paths)

Given a sequence of path names, returns the longest common sub-path.

.commonprefix()Neutral
#
Signature
commonprefix(m)

Given a list of pathnames, returns the longest common leading component

.dirname()Neutral
#
Signature
dirname(p)

Returns the directory component of a pathname

.exists()Neutral
#
Signature
exists(path)

Test whether a path exists. Returns False for broken symbolic links

.expanduser()Neutral
#
Signature
expanduser(path)

Expand ~ and ~user constructs.

.expandvars()Neutral
#
Signature
expandvars(path)

Expand shell variables of the forms $var, ${var} and %var%.

.getatime()Neutral
#
Signature
getatime(filename)

Return the last access time of a file, reported by os.stat().

.getctime()Neutral
#
Signature
getctime(filename)

Return the metadata change time of a file, reported by os.stat().

Fully-Qualified Names

FQNField
ntpathfqns[0]

Wrong FQN → 0 findings. Verify with: change fqns to garbage → must produce 0 results.

Import

rule.py
import ntpath