Skip to content

Commit f1c6dc1

Browse files
committed
Moved SortTaintStep to more appropriate home TaintTracking->Arrays
1 parent e920a4c commit f1c6dc1

File tree

2 files changed

+13
-13
lines changed

2 files changed

+13
-13
lines changed

javascript/ql/lib/semmle/javascript/Arrays.qll

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -444,4 +444,17 @@ private module ArrayLibraries {
444444
)
445445
}
446446
}
447+
448+
/**
449+
* A taint propagating data flow edge arising from sorting.
450+
*/
451+
private class SortTaintStep extends TaintTracking::SharedTaintStep {
452+
override predicate heapStep(DataFlow::Node pred, DataFlow::Node succ) {
453+
exists(DataFlow::MethodCallNode call |
454+
call.getMethodName() = "sort" and
455+
pred = call.getReceiver() and
456+
succ = call
457+
)
458+
}
459+
}
447460
}

javascript/ql/lib/semmle/javascript/dataflow/TaintTracking.qll

Lines changed: 0 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -869,19 +869,6 @@ module TaintTracking {
869869
}
870870
}
871871

872-
/**
873-
* A taint propagating data flow edge arising from sorting.
874-
*/
875-
private class SortTaintStep extends SharedTaintStep {
876-
override predicate heapStep(DataFlow::Node pred, DataFlow::Node succ) {
877-
exists(DataFlow::MethodCallNode call |
878-
call.getMethodName() = "sort" and
879-
pred = call.getReceiver() and
880-
succ = call
881-
)
882-
}
883-
}
884-
885872
/**
886873
* A taint step through an exception constructor, such as `x` to `new Error(x)`.
887874
*/

0 commit comments

Comments
 (0)