Autoformat.

This commit is contained in:
Anders Schack-Mulligen
2020-11-30 14:42:38 +01:00
parent 931322e4c5
commit 8f2094f0bf
95 changed files with 189 additions and 341 deletions

View File

@@ -19,8 +19,7 @@ import DataFlow::PathGraph
*/
class ELMessageInterpolatorType extends RefType {
ELMessageInterpolatorType() {
this
.getASourceSupertype*()
this.getASourceSupertype*()
.hasQualifiedName("org.hibernate.validator.messageinterpolation",
["ResourceBundleMessageInterpolator", "ValueFormatterMessageInterpolator"])
}
@@ -38,9 +37,8 @@ class SetMessageInterpolatorCall extends MethodAccess {
t.hasQualifiedName("javax.validation", ["Configuration", "ValidatorContext"]) and
m.getName() = "messageInterpolator"
or
t
.hasQualifiedName("org.springframework.validation.beanvalidation",
["CustomValidatorBean", "LocalValidatorFactoryBean"]) and
t.hasQualifiedName("org.springframework.validation.beanvalidation",
["CustomValidatorBean", "LocalValidatorFactoryBean"]) and
m.getName() = "setMessageInterpolator"
)
)
@@ -58,8 +56,7 @@ class SetMessageInterpolatorCall extends MethodAccess {
*/
class BuildConstraintViolationWithTemplateMethod extends Method {
BuildConstraintViolationWithTemplateMethod() {
this
.getDeclaringType()
this.getDeclaringType()
.getASupertype*()
.hasQualifiedName("javax.validation", "ConstraintValidatorContext") and
this.hasName("buildConstraintViolationWithTemplate")

View File

@@ -15,8 +15,7 @@ import java
from MethodAccess call
where
call.getMethod().hasName("disable") and
call
.getReceiverType()
call.getReceiverType()
.hasQualifiedName("org.springframework.security.config.annotation.web.configurers",
"CsrfConfigurer<HttpSecurity>")
select call, "CSRF vulnerability due to protection being disabled."