Skip to content

Commit df202ef

Browse files
authored
Merge pull request #468 from xiemaisi/js/has{Path,Flow}+
JavaScript: Rename `hasPathFlow` to `hasFlowPath` for consistency with other languages.
2 parents 4a14bef + 3fcd02a commit df202ef

31 files changed

+43
-34
lines changed

javascript/ql/src/Security/CWE-022/TaintedPath.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,6 @@ import semmle.javascript.security.dataflow.TaintedPath::TaintedPath
1919
import DataFlow::PathGraph
2020

2121
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
22-
where cfg.hasPathFlow(source, sink)
22+
where cfg.hasFlowPath(source, sink)
2323
select sink.getNode(), source, sink, "This path depends on $@.",
2424
source.getNode(), "a user-provided value"

javascript/ql/src/Security/CWE-078/CommandInjection.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import semmle.javascript.security.dataflow.CommandInjection::CommandInjection
1717
import DataFlow::PathGraph
1818

1919
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink, DataFlow::Node highlight
20-
where cfg.hasPathFlow(source, sink) and
20+
where cfg.hasFlowPath(source, sink) and
2121
if cfg.isSinkWithHighlight(sink.getNode(), _) then
2222
cfg.isSinkWithHighlight(sink.getNode(), highlight)
2323
else

javascript/ql/src/Security/CWE-079/ReflectedXss.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ import semmle.javascript.security.dataflow.ReflectedXss::ReflectedXss
1616
import DataFlow::PathGraph
1717

1818
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
19-
where cfg.hasPathFlow(source, sink)
19+
where cfg.hasFlowPath(source, sink)
2020
select sink.getNode(), source, sink, "Cross-site scripting vulnerability due to $@.",
2121
source.getNode(), "user-provided value"

javascript/ql/src/Security/CWE-079/StoredXss.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ import semmle.javascript.security.dataflow.StoredXss::StoredXss
1616
import DataFlow::PathGraph
1717

1818
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
19-
where cfg.hasPathFlow(source, sink)
19+
where cfg.hasFlowPath(source, sink)
2020
select sink.getNode(), source, sink, "Stored cross-site scripting vulnerability due to $@.",
2121
source.getNode(), "stored value"

javascript/ql/src/Security/CWE-079/Xss.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ import semmle.javascript.security.dataflow.DomBasedXss::DomBasedXss
1616
import DataFlow::PathGraph
1717

1818
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
19-
where cfg.hasPathFlow(source, sink)
19+
where cfg.hasFlowPath(source, sink)
2020
select sink.getNode(), source, sink, sink.getNode().(Sink).getVulnerabilityKind() + " vulnerability due to $@.",
2121
source.getNode(), "user-provided value"

javascript/ql/src/Security/CWE-089/SqlInjection.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,6 @@ import DataFlow::PathGraph
1818
from DataFlow::Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
1919
where (cfg instanceof SqlInjection::Configuration or
2020
cfg instanceof NosqlInjection::Configuration) and
21-
cfg.hasPathFlow(source, sink)
21+
cfg.hasFlowPath(source, sink)
2222
select sink.getNode(), source, sink, "This query depends on $@.",
2323
source.getNode(), "a user-provided value"

javascript/ql/src/Security/CWE-094/CodeInjection.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,6 @@ import semmle.javascript.security.dataflow.CodeInjection::CodeInjection
1717
import DataFlow::PathGraph
1818

1919
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
20-
where cfg.hasPathFlow(source, sink)
20+
where cfg.hasFlowPath(source, sink)
2121
select sink.getNode(), source, sink, "$@ flows to here and is interpreted as code.",
2222
source.getNode(), "User-provided value"

javascript/ql/src/Security/CWE-134/TaintedFormatString.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,6 @@ import semmle.javascript.security.dataflow.TaintedFormatString::TaintedFormatStr
1414
import DataFlow::PathGraph
1515

1616
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
17-
where cfg.hasPathFlow(source, sink)
17+
where cfg.hasFlowPath(source, sink)
1818
select sink.getNode(), source, sink, "$@ flows here and is used in a format string.",
1919
source.getNode(), "User-provided value"

javascript/ql/src/Security/CWE-200/FileAccessToHttp.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,6 @@ import semmle.javascript.security.dataflow.FileAccessToHttp::FileAccessToHttp
1313
import DataFlow::PathGraph
1414

1515
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
16-
where cfg.hasPathFlow(source, sink)
16+
where cfg.hasFlowPath(source, sink)
1717
select sink.getNode(), source, sink, "$@ flows directly to outbound network request",
1818
source.getNode(), "File data"

javascript/ql/src/Security/CWE-209/StackTraceExposure.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,6 @@ import semmle.javascript.security.dataflow.StackTraceExposure::StackTraceExposur
1616
import DataFlow::PathGraph
1717

1818
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
19-
where cfg.hasPathFlow(source, sink)
19+
where cfg.hasFlowPath(source, sink)
2020
select sink.getNode(), source, sink, "Stack trace information from $@ may be exposed to an external user here.",
2121
source.getNode(), "here"

0 commit comments

Comments
 (0)