... SER when supplied via an HTTP header, as in ASGI). Django can be configured to make use of the REMOTE_USER value using the RemoteUserMiddleware or PersistentRemoteUserMiddleware , and RemoteUserBackend classes found in django.contrib.auth . 設定 最初に次のように MID ... DLEWARE 設定に django.contrib.auth.middleware.RemoteUserMiddleware を加える必要があります。これは django.contrib.auth.middleware.AuthenticationMiddleware の 後に 追加してください: MIDDLEWAR ... E = [ "..." , "django.contrib.auth.middleware.AuthenticationMiddleware" , "django.contrib.auth.middleware.RemoteUserMiddleware" , "..." , ] 続いて、 AUTHENTICATION_BACKENDS 設定の ModelBackend を RemoteUserBackend に変更します: AUTHENTICATION_BACKEN ... ... ric string (e.g. "_x3a1gho" ), rather than iterating through an underscore followed by a number (e.g. "_1" , "_2" , etc.). RemoteUserMiddleware session hijacking When using the RemoteUserMiddleware and the RemoteUserBackend , a change to the REMOTE_USER header betwe ... ... ric string (e.g. "_x3a1gho" ), rather than iterating through an underscore followed by a number (e.g. "_1" , "_2" , etc.). RemoteUserMiddleware session hijacking When using the RemoteUserMiddleware and the RemoteUserBackend , a change to the REMOTE_USER header betwe ... ... ric string (e.g. "_x3a1gho" ), rather than iterating through an underscore followed by a number (e.g. "_1" , "_2" , etc.). RemoteUserMiddleware session hijacking When using the RemoteUserMiddleware and the RemoteUserBackend , a change to the REMOTE_USER header betwe ... ... ッシュが発生するリグレッションを修正しました( #36388 )。 Django 5.2 において、 process_request() をオーバーライドしている RemoteUserMiddleware のサブクラスがサポートされなくなっていたリグレッションを修正しました( #36390 )。 Django 5.2 において、 Aggregate 式の fi ... ... iv> elements. The breadcrumb for the current page is now marked with aria-current="page" . django.contrib.auth Under ASGI, RemoteUserMiddleware no longer prefixes HTTP_ when looking up custom values in request.META . For example, to send -H "AuthUser: ..." , the hea ... and django.contrib.postgres.aggregates.StringAgg are removed in favor of the order_by parameter. Support for subclasses of RemoteUserMiddleware that override process_request() without overriding aprocess_request() is removed. ... ... ようにしてください。 無限リダイレクトを防ぐために、ログインビューへの 認証されていないリクエストを許可してください 。 class RemoteUserMiddleware [ソース] Middleware for utilizing web server provided authentication. See REMOTE_USER で認証する for usage details, includ ... ing security considerations. class PersistentRemoteUserMiddleware [ソース] Middleware for utilizing web server provided authentication when enabled only on the login page. See ログインペー ... 後に、 CSRF_USE_SESSIONS を使用している場合。 CsrfViewMiddleware CSRF 攻撃が可能なすべての view ミドルウェアの前に置きます。 RemoteUserMiddleware の前、あるいはログインを実行し、CSRF トークンをローテートする可能性のある他の認証ミドルウェアの前、ミドルウェアチェインを呼 ... ... ASGI, it is a deployment misconfiguration (rather than any flaw in Django) for Django to be the direct HTTP endpoint when RemoteUserMiddleware is used. Request headers and URLs must be under 8K bytes To prevent denial-of-service (DoS) attacks, production-grade serv ... ... test equality for XML content at a semantic level, without caring for syntax differences (spaces, attribute order, etc.). RemoteUserMiddleware now forces logout when the REMOTE_USER header disappears during the same browser session. The cache-based session backend ... ... 代わりに order_by 引数を使用してください。 aprocess_request() をオーバーライドせずに process_request() をオーバーライドする RemoteUserMiddleware のサブクラスのサポートが非推奨となりました。 ... 2026年10月08日