mirror of
https://github.com/github/codeql.git
synced 2025-12-23 04:06:37 +01:00
python: allow alternative middleware
(observed [on LGTM](9d6a7ee180/files/mozillians/settings.py (L96)))
This commit is contained in:
@@ -2340,7 +2340,12 @@ module PrivateDjango {
|
||||
}
|
||||
|
||||
override boolean getVerificationSetting() {
|
||||
if list.getAnElt().(StrConst).getText() = "django.middleware.csrf.CsrfViewMiddleware"
|
||||
if
|
||||
list.getAnElt().(StrConst).getText() in [
|
||||
"django.middleware.csrf.CsrfViewMiddleware",
|
||||
// see https://github.com/mozilla/django-session-csrf
|
||||
"session_csrf.CsrfMiddleware"
|
||||
]
|
||||
then result = true
|
||||
else result = false
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user