Moved SortTaintStep to more appropriate home TaintTracking->Arrays

This commit is contained in:
Napalys
2024-11-08 12:05:31 +01:00
parent e920a4c56c
commit f1c6dc1d9b
2 changed files with 13 additions and 13 deletions

View File

@@ -444,4 +444,17 @@ private module ArrayLibraries {
)
}
}
/**
* A taint propagating data flow edge arising from sorting.
*/
private class SortTaintStep extends TaintTracking::SharedTaintStep {
override predicate heapStep(DataFlow::Node pred, DataFlow::Node succ) {
exists(DataFlow::MethodCallNode call |
call.getMethodName() = "sort" and
pred = call.getReceiver() and
succ = call
)
}
}
}

View File

@@ -869,19 +869,6 @@ module TaintTracking {
}
}
/**
* A taint propagating data flow edge arising from sorting.
*/
private class SortTaintStep extends SharedTaintStep {
override predicate heapStep(DataFlow::Node pred, DataFlow::Node succ) {
exists(DataFlow::MethodCallNode call |
call.getMethodName() = "sort" and
pred = call.getReceiver() and
succ = call
)
}
}
/**
* A taint step through an exception constructor, such as `x` to `new Error(x)`.
*/