⚝
One Hat Cyber Team
⚝
Your IP:
3.145.106.159
Server IP:
97.74.87.16
Server:
Linux 16.87.74.97.host.secureserver.net 5.14.0-503.38.1.el9_5.x86_64 #1 SMP PREEMPT_DYNAMIC Fri Apr 18 08:52:10 EDT 2025 x86_64
Server Software:
Apache
PHP Version:
8.2.28
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
opt
/
python38
/
lib
/
python3.8
/
wsgiref
/
__pycache__
/
View File Name :
util.cpython-38.pyc
U ���q+���ͧ��������������������@���sv���d�Z�ddlZddddddgZG�d d��d�Zd d��Zdd��Zdd d�Zdd��Zdd��Zddddddddhj Z dd��ZdS�)z$Miscellaneous WSGI-related Utilities�����N�FileWrapper�guess_scheme�application_uri�request_uri�shift_path_info�setup_testing_defaultsc�������������������@���s2���e�Zd�ZdZddd�Zdd��Zdd��Zd d ��ZdS�) r���z1Wrapper to convert file-like objects to iterables�� ��c�����������������C���s"���||�_�||�_t|d�r|j|�_d�S�)N�close)�filelike�blksize�hasattrr ���)�selfr ���r�����r����+/opt/python38/lib/python3.8/wsgiref/util.py�__init__���s���� zFileWrapper.__init__c�����������������C���s6���dd�l�}|jdtdd��|�j�|�j�}|r.|S�t�d�S�)Nr���zXFileWrapper's __getitem__ method ignores 'key' parameter. Use iterator protocol instead.����)� stacklevel)�warnings�warn�DeprecationWarningr ����readr���� IndexError)r ����keyr����datar���r���r����__getitem__���s�����zFileWrapper.__getitem__c�����������������C���s���|�S��Nr���)r ���r���r���r����__iter__!���s����zFileWrapper.__iter__c�����������������C���s���|�j��|�j�}|r|S�t�d�S�r���)r ���r���r���� StopIteration)r ���r���r���r���r����__next__$���s����zFileWrapper.__next__N)r���)�__name__� __module__�__qualname__�__doc__r���r���r���r���r���r���r���r���r������s ��� c�����������������C���s���|���d�dkrdS�dS�dS�)zMReturn a guess for whether 'wsgi.url_scheme' should be 'http' or 'https' ZHTTPS)ZyesZon�1�https�httpN)�get)�environr���r���r���r���*���s����c�����������������C���s����|�d�d�}ddl�m}�|��d�r0||�d�7�}nR||�d�7�}|�d�dkrf|�d�d kr�|d |�d��7�}n|�d�dkr�|d |�d��7�}|||��d�p�d dd�7�}|S�)z@Return the application's base URI (no PATH_INFO or QUERY_STRING)�wsgi.url_schemez://r�����quote� HTTP_HOST�SERVER_NAMEr$����SERVER_PORT�443�:�80�SCRIPT_NAME�/�latin1)�encoding)�urllib.parser*���r&���)r'����urlr*���r���r���r���r���2���s���� Tc�����������������C���sp���t�|��}ddlm}�||��dd�ddd�}|��d�sF||d d ��7�}n||7�}|rl|��d�rl|d|�d��7�}|S�) zBReturn the full request URI, optionally including the query stringr���r)���� PATH_INFO��z/;=,r3���)Zsafer4���r1�������NZQUERY_STRING�?)r���r5���r*���r&���)r'���Z include_queryr6���r*���� path_infor���r���r���r���F���s���� c�����������������C���s����|���dd�}|sdS�|�d�}dd��|dd��D��|dd�<�|d�}|d=�|���d d�}t�|d�|��}|�d�r~|dd��}|s�|�d�s�|d7�}||�d <�d�|�|�d<�|d kr�d}|S�)aZ��Shift a name from PATH_INFO to SCRIPT_NAME, returning it If there are no remaining path segments in PATH_INFO, return None. Note: 'environ' is modified in-place; use a copy if you need to keep the original PATH_INFO or SCRIPT_NAME. Note: when PATH_INFO is just a '/', this returns '' and appends a trailing '/' to SCRIPT_NAME, even though empty path segments are normally ignored, and SCRIPT_NAME doesn't normally end in a '/'. This is intentional behavior, to ensure that an application can tell the difference between '/x' and '/x/' when traversing to objects. r7���r8���Nr2���c�����������������S���s���g�|�]}|r|d�kr|�qS�)�.r���)�.0�pr���r���r���� <listcomp>e���s�������z#shift_path_info.<locals>.<listcomp>r9������r1���r<���)r&����split� posixpath�normpath�endswith�join)r'���r;���� path_parts�nameZscript_namer���r���r���r���S���s$���� c�����������������C���s����|���dd��|���dd��|���d|�d���|���dd��d|�kr\d |�kr\|���dd ��|���d d��|���dd ��|���dd��|���dd��|���dd��ddlm}m}�|���d|����|���d|����|���dt|����|�d�dkr�|���dd��n|�d�dkr�|���dd��dS�)a:��Update 'environ' with trivial defaults for testing purposes This adds various parameters required for WSGI, including HTTP_HOST, SERVER_NAME, SERVER_PORT, REQUEST_METHOD, SCRIPT_NAME, PATH_INFO, and all of the wsgi.* variables. It only supplies default values, and does not replace any existing settings for these variables. This routine is intended to make it easier for unit tests of WSGI servers and applications to set up dummy environments. It should *not* be used by actual WSGI servers or applications, since the data is fake! r,���z 127.0.0.1ZSERVER_PROTOCOLzHTTP/1.0r+���ZREQUEST_METHOD�GETr1���r7���r8���r2���zwsgi.version)r9���r���z wsgi.run_oncer���zwsgi.multithreadzwsgi.multiprocess)�StringIO�BytesIOz wsgi.inputzwsgi.errorsr(���r%���r-���r0���r$���r.���N)� setdefault�iorI���rJ���r���)r'���rI���rJ���r���r���r���r���|���s&���� � connectionz keep-alivezproxy-authenticatezproxy-authorization�teZtrailersztransfer-encodingZupgradec�����������������C���s���t�|�����S�)z?Return true if 'header_name' is an HTTP/1.1 "Hop-by-Hop" header)�_hoppish�lower)Zheader_namer���r���r���� is_hop_by_hop����s����rQ���)T)r"���rB����__all__r���r���r���r���r���r����__contains__rO���rQ���r���r���r���r����<module>���s0�������� ))������