Exclude queries without precision

This commit is contained in:
Tony Torralba
2022-03-15 10:22:10 +01:00
parent 18165cbb46
commit 82b2fd2d23
3 changed files with 17 additions and 0 deletions

View File

@@ -15,6 +15,9 @@ predicate missingSecuritySeverity(QLDoc doc) {
exists(string securityTag | securityTag = s.splitAt("@") |
securityTag.matches("tags%security%")
) and
exists(string precisionTag | precisionTag = s.splitAt("@") |
precisionTag.matches("precision %")
) and
not exists(string securitySeverity | securitySeverity = s.splitAt("@") |
securitySeverity.matches("security-severity %")
)

View File

@@ -0,0 +1,14 @@
/**
* @name Some query
* @description Some description
* @kind problem
* @problem.severity warning
* @id ql/some-query
* @tags quality
* security
*/
import ql
from Class c
select c