Skip to content

Commit cee9139

Browse files
committed
Java: Correctly annotate missing XSS sinks in JaxWs modeling
1 parent adf109b commit cee9139

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

java/ql/test/library-tests/frameworks/JaxWs/JakartaRs1.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ void Post() { // $ ResourceMethod ResourceMethodOnResourceClass
4141
@Produces("text/plain") // $ ProducesAnnotation=text/plain
4242
@DELETE
4343
double Delete() { // $ ResourceMethod=text/plain ResourceMethodOnResourceClass
44-
return 0.0; // $ XssSink
44+
return 0.0; // $ MISSING: XssSink
4545
}
4646

4747
@Produces(MediaType.TEXT_HTML) // $ ProducesAnnotation=text/html
@@ -77,7 +77,7 @@ boolean Post() { // $ ResourceMethod=text/html ResourceMethodOnResourceClass
7777
@Produces(MediaType.TEXT_PLAIN) // $ ProducesAnnotation=text/plain
7878
@DELETE
7979
double Delete() { // $ ResourceMethod=text/plain ResourceMethodOnResourceClass
80-
return 0.0; // $ XssSink
80+
return 0.0; // $ MISSING: XssSink
8181
}
8282

8383
@Path("")

java/ql/test/library-tests/frameworks/JaxWs/JaxRs1.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ void Post() { // $ ResourceMethod ResourceMethodOnResourceClass
4141
@Produces("text/plain") // $ ProducesAnnotation=text/plain
4242
@DELETE
4343
double Delete() { // $ ResourceMethod=text/plain ResourceMethodOnResourceClass
44-
return 0.0; // $ XssSink
44+
return 0.0; // $ MISSING: XssSink
4545
}
4646

4747
@Produces(MediaType.TEXT_HTML) // $ ProducesAnnotation=text/html
@@ -77,7 +77,7 @@ boolean Post() { // $ ResourceMethod=text/html ResourceMethodOnResourceClass
7777
@Produces(MediaType.TEXT_PLAIN) // $ ProducesAnnotation=text/plain
7878
@DELETE
7979
double Delete() { // $ ResourceMethod=text/plain ResourceMethodOnResourceClass
80-
return 0.0; // $ XssSink
80+
return 0.0; // $ MISSING: XssSink
8181
}
8282

8383
@Path("")

0 commit comments

Comments
 (0)