Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit 20625ae

Browse files
committed
update {js/go/py}/xpath-injection to match csharp/java
1 parent b5458b2 commit 20625ae

3 files changed

Lines changed: 5 additions & 4 deletions

File tree

go/ql/src/Security/CWE-643/XPathInjection.ql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,5 +24,5 @@ predicate isStringOrByte(DataFlow::PathNode node) {
2424

2525
from Configuration config, DataFlow::PathNode source, DataFlow::PathNode sink
2626
where config.hasFlowPath(source, sink) and isStringOrByte(sink)
27-
select sink.getNode(), source, sink, "$@ flows here and is used in an XPath expression.",
28-
source.getNode(), "A user-provided value"
27+
select sink.getNode(), source, sink, "$@ flows to here and is used in an XPath expression.",
28+
source.getNode(), "User-provided value"

javascript/ql/src/Security/CWE-643/XpathInjection.ql

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,5 +17,5 @@ import DataFlow::PathGraph
1717

1818
from Configuration cfg, DataFlow::PathNode source, DataFlow::PathNode sink
1919
where cfg.hasFlowPath(source, sink)
20-
select sink.getNode(), source, sink, "$@ flows here and is used in an XPath expression.",
20+
select sink.getNode(), source, sink, "$@ flows to here and is used in an XPath expression.",
2121
source.getNode(), "User-provided value"

python/ql/src/Security/CWE-643/XpathInjection.ql

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,4 +17,5 @@ import DataFlow::PathGraph
1717

1818
from Configuration config, DataFlow::PathNode source, DataFlow::PathNode sink
1919
where config.hasFlowPath(source, sink)
20-
select sink, source, sink, "This Xpath query depends on $@.", source, "a user-provided value"
20+
select sink.getNode(), source, sink, "$@ flows to here and is used in an XPath expression.",
21+
source.getNode(), "User-provided value"

0 commit comments

Comments
 (0)