| Server IP : 217.160.0.135 / Your IP : 216.73.217.85 Web Server : Apache System : Linux www 6.18.52-i1-ampere #1203 SMP Mon Sep 14 18:29:59 CEST 2026 aarch64 User : sws1074145052 ( 1074145052) PHP Version : 8.3.32 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /usr/lib/python3/dist-packages/django/views/decorators/__pycache__/ |
Upload File : |
�
�|�e � � � d dl mZ d dlmZmZ d dlmZ ee� � Zde_ de_ G d� de� � Z
ee
� � Zde_ d e_ G d
� de� � Z ee� � Z
de
_ d
e
_ d� ZdS )� )�wraps)�CsrfViewMiddleware� get_token)�decorator_from_middleware�csrf_protectz�
This decorator adds CSRF protection in exactly the same way as
CsrfViewMiddleware, but it can be used on a per view basis. Using both, or
using the decorator multiple times, is harmless and efficient.
c � � e Zd Zd� ZdS )�_EnsureCsrfTokenc � � d S �N� ��self�request�reasons �>/usr/lib/python3/dist-packages/django/views/decorators/csrf.py�_rejectz_EnsureCsrfToken._reject � � ��t� N)�__name__�
__module__�__qualname__r r r r r r s# � � � � � �� � � � r r �requires_csrf_tokenz�
Use this decorator on views that need a correct csrf_token available to
RequestContext, but without the CSRF protection that csrf_protect
enforces.
c �$ � � e Zd Zd� Z� fd�Z� xZS )�_EnsureCsrfCookiec � � d S r r r
s r r z_EnsureCsrfCookie._reject r r c �n �� t � � � ||||� � }t |� � |S r )�super�process_viewr )r r �callback�
callback_args�callback_kwargs�retval� __class__s �r r z_EnsureCsrfCookie.process_view"