MCPcopy Index your code
hub / github.com/sqlmapproject/sqlmap / isWindowsDriveLetterPath

Function isWindowsDriveLetterPath

lib/core/common.py:2299–2309  ·  view source on GitHub ↗

Returns True if given filepath starts with a Windows drive letter >>> isWindowsDriveLetterPath('C:\\boot.ini') True >>> isWindowsDriveLetterPath('/var/log/apache.log') False

(filepath)

Source from the content-addressed store, hash-verified

2297 return commonWords
2298
2299def isWindowsDriveLetterPath(filepath):
2300 """
2301 Returns True if given filepath starts with a Windows drive letter
2302
2303 >>> isWindowsDriveLetterPath('C:\\boot.ini')
2304 True
2305 >>> isWindowsDriveLetterPath('/var/log/apache.log')
2306 False
2307 """
2308
2309 return re.search(r"\A[\w]\:", filepath) is not None
2310
2311def posixToNtSlashes(filepath):
2312 """

Callers 6

webInitMethod · 0.90
udfSetRemotePathMethod · 0.90
getManualDirectoriesFunction · 0.85
parseFilePathsFunction · 0.85
directoryPathFunction · 0.85
normalizePathFunction · 0.85

Calls 1

searchMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…