mirror of
https://github.com/davidhalter/django-stubs.git
synced 2025-12-13 15:31:55 +08:00
19 lines
507 B
Python
19 lines
507 B
Python
from django.core.handlers.wsgi import WSGIRequest
|
|
from django.http.response import (
|
|
HttpResponse,
|
|
HttpResponsePermanentRedirect,
|
|
)
|
|
from typing import Optional
|
|
|
|
|
|
class SecurityMiddleware:
|
|
def __init__(self, get_response: None = ...) -> None: ...
|
|
def process_request(
|
|
self,
|
|
request: WSGIRequest
|
|
) -> Optional[HttpResponsePermanentRedirect]: ...
|
|
def process_response(
|
|
self,
|
|
request: WSGIRequest,
|
|
response: HttpResponse
|
|
) -> HttpResponse: ... |