Skip to content

Commit 104a8d9

Browse files
author
Max Schaefer
committed
Automodel: Make description of some negative characteristics more explicit.
1 parent 566351a commit 104a8d9

File tree

2 files changed

+6
-6
lines changed

2 files changed

+6
-6
lines changed

java/ql/automodel/src/AutomodelApplicationModeCharacteristics.qll

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -465,7 +465,7 @@ predicate isPositiveExample(
465465
* TODO: this might filter too much, it's possible that methods with more than one parameter contain interesting sinks
466466
*/
467467
private class UnexploitableIsCharacteristic extends CharacteristicsImpl::NotASinkCharacteristic {
468-
UnexploitableIsCharacteristic() { this = "unexploitable (is-style boolean method)" }
468+
UnexploitableIsCharacteristic() { this = "argument of is-style boolean method" }
469469

470470
override predicate appliesToEndpoint(Endpoint e) {
471471
e.getCallable().getName().matches("is%") and
@@ -483,7 +483,7 @@ private class UnexploitableIsCharacteristic extends CharacteristicsImpl::NotASin
483483
* dangerous/interesting thing, so we want the latter to be modeled as the sink.
484484
*/
485485
private class UnexploitableExistsCharacteristic extends CharacteristicsImpl::NotASinkCharacteristic {
486-
UnexploitableExistsCharacteristic() { this = "unexploitable (existence-checking boolean method)" }
486+
UnexploitableExistsCharacteristic() { this = "argument of existence-checking boolean method" }
487487

488488
override predicate appliesToEndpoint(Endpoint e) {
489489
exists(Callable callable | callable = e.getCallable() |
@@ -499,7 +499,7 @@ private class UnexploitableExistsCharacteristic extends CharacteristicsImpl::Not
499499
*/
500500
private class ExceptionCharacteristic extends CharacteristicsImpl::NeitherSourceNorSinkCharacteristic
501501
{
502-
ExceptionCharacteristic() { this = "exception" }
502+
ExceptionCharacteristic() { this = "argument/result of exception-related method" }
503503

504504
override predicate appliesToEndpoint(Endpoint e) {
505505
e.getCallable().getDeclaringType().getASupertype*() instanceof TypeThrowable and

java/ql/automodel/src/AutomodelFrameworkModeCharacteristics.qll

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -404,7 +404,7 @@ predicate isPositiveExample(
404404
*/
405405
private class UnexploitableIsCharacteristic extends CharacteristicsImpl::NeitherSourceNorSinkCharacteristic
406406
{
407-
UnexploitableIsCharacteristic() { this = "unexploitable (is-style boolean method)" }
407+
UnexploitableIsCharacteristic() { this = "argument of is-style boolean method" }
408408

409409
override predicate appliesToEndpoint(Endpoint e) {
410410
e.getCallable().getName().matches("is%") and
@@ -430,7 +430,7 @@ private class UnexploitableIsCharacteristic extends CharacteristicsImpl::Neither
430430
*/
431431
private class UnexploitableExistsCharacteristic extends CharacteristicsImpl::NeitherSourceNorSinkCharacteristic
432432
{
433-
UnexploitableExistsCharacteristic() { this = "unexploitable (existence-checking boolean method)" }
433+
UnexploitableExistsCharacteristic() { this = "argument of existence-checking boolean method" }
434434

435435
override predicate appliesToEndpoint(Endpoint e) {
436436
exists(Callable callable |
@@ -454,7 +454,7 @@ private class UnexploitableExistsCharacteristic extends CharacteristicsImpl::Nei
454454
*/
455455
private class ExceptionCharacteristic extends CharacteristicsImpl::NeitherSourceNorSinkCharacteristic
456456
{
457-
ExceptionCharacteristic() { this = "exception" }
457+
ExceptionCharacteristic() { this = "argument/result of exception-related method" }
458458

459459
override predicate appliesToEndpoint(Endpoint e) {
460460
e.getCallable().getDeclaringType().getASupertype*() instanceof TypeThrowable and

0 commit comments

Comments
 (0)