mirror of
https://github.com/github/codeql.git
synced 2026-04-28 02:05:14 +02:00
Added support for del function in superagent
This commit is contained in:
@@ -513,6 +513,13 @@ module ClientRequest {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets the name of a superagent request method.
|
||||
*/
|
||||
private string getSuperagentRequestMethodName() {
|
||||
result = [httpMethodName(), any(Http::RequestMethodName m), "del", "DEL"]
|
||||
}
|
||||
|
||||
/**
|
||||
* A model of a URL request made using the `superagent` library.
|
||||
*/
|
||||
@@ -522,7 +529,7 @@ module ClientRequest {
|
||||
SuperAgentUrlRequest() {
|
||||
exists(string moduleName, DataFlow::SourceNode callee | this = callee.getACall() |
|
||||
moduleName = "superagent" and
|
||||
callee = DataFlow::moduleMember(moduleName, httpMethodName()) and
|
||||
callee = DataFlow::moduleMember(moduleName, getSuperagentRequestMethodName()) and
|
||||
url = this.getArgument(0)
|
||||
)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user