Skip to content

Commit c29011a

Browse files
committed
C++: Add more sinks.
1 parent ae622bd commit c29011a

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

cpp/ql/src/Security/CWE/CWE-319/UseOfHttp.ql

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -54,16 +54,16 @@ class HttpStringToUrlOpenConfig extends TaintTracking::Configuration {
5454

5555
override predicate isSink(DataFlow::Node sink) {
5656
exists(FunctionCall fc |
57-
fc.getTarget().hasGlobalOrStdName(["system", "gethostbyname"]) and
57+
fc.getTarget().hasGlobalOrStdName(["system", "gethostbyname", "getaddrinfo"]) and
5858
sink.asExpr() = fc.getArgument(0)
5959
or
60-
fc.getTarget().hasGlobalOrStdName(["send", "URLDownloadToFile"]) and
60+
fc.getTarget().hasGlobalOrStdName(["send", "URLDownloadToFile", "URLDownloadToCacheFile"]) and
6161
sink.asExpr() = fc.getArgument(1)
6262
or
63-
fc.getTarget().hasGlobalOrStdName("curl_easy_setopt") and
63+
fc.getTarget().hasGlobalOrStdName(["curl_easy_setopt", "getnameinfo"]) and
6464
sink.asExpr() = fc.getArgument(2)
6565
or
66-
fc.getTarget().hasGlobalOrStdName("ShellExecute") and
66+
fc.getTarget().hasGlobalOrStdName(["ShellExecute", "ShellExecuteA", "ShellExecuteW"]) and
6767
sink.asExpr() = fc.getArgument(3)
6868
)
6969
}

0 commit comments

Comments
 (0)