mirror of
https://github.com/github/codeql.git
synced 2026-04-17 13:04:02 +02:00
Python: Use API graphs instead of points-to for simple built-ins
Also extends the list of known built-ins slightly, to add some that were missing.
This commit is contained in:
@@ -10,9 +10,10 @@
|
||||
*/
|
||||
|
||||
import python
|
||||
private import LegacyPointsTo
|
||||
private import semmle.python.types.Builtins
|
||||
private import semmle.python.ApiGraphs
|
||||
|
||||
from CallNode call, ControlFlowNodeWithPointsTo func
|
||||
where major_version() = 2 and call.getFunction() = func and func.pointsTo(Value::named("apply"))
|
||||
from CallNode call
|
||||
where
|
||||
major_version() = 2 and
|
||||
call = API::builtin("apply").getACall().asCfgNode()
|
||||
select call, "Call to the obsolete builtin function 'apply'."
|
||||
|
||||
Reference in New Issue
Block a user