Yohohohohohooho | Sanrei Aya
Sanrei Aya


Server : LiteSpeed
System : Linux barito.iixcp.rumahweb.net 5.14.0-611.49.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Tue Apr 21 16:39:08 EDT 2026 x86_64
User : elvh3918 ( 1528)
PHP Version : 8.2.31
Disable Function : mail
Directory :  /proc/self/root/usr/local/lib/python3.9/site-packages/kombu/utils/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Current File : //proc/self/root/usr/local/lib/python3.9/site-packages/kombu/utils/__pycache__/url.cpython-39.pyc
a

��ShE�@s�dZddlmZddlmZddlmZddlmZddl	m
Z
mZmZm
Z
zddlZdZWneyrd	ZYn0d
dlmZeedd
�Zee�ZGdd�de�Zdd�Zdd�ZeZddd�Zddd�Zddd�Zdd�ZdS) zURL Utilities.�)�annotations)�Mapping)�partial)�
NamedTuple)�	parse_qsl�quote�unquote�urlparseNTF�)�
get_logger�)�safec@sJeZdZUdZded<ded<ded<ded<ded<ded	<d
ed<dS)
�urlpartsz*Named tuple representing parts of the URL.�str�scheme�hostname�int�port�username�password�pathr�queryN)�__name__�
__module__�__qualname__�__doc__�__annotations__�rr�9/usr/local/lib/python3.9/site-packages/kombu/utils/url.pyrs
rc
	Cs�t|�\}}}}}}}|r�dd�|��D�}|D]v}	|	dkrR||	��dk||	<n.|	dkr�t||	�||	<||	dur�t�d�d|vr�i|d<||	|d|	<||	=q0tf||||||d	�|��S)
z%Parse URL into mapping of components.cSsg|]}|�d�r|�qS)�ssl_)�
startswith)�.0�keyrrr�
<listcomp>(�zparse_url.<locals>.<listcomp>Zssl_check_hostname�falseZ
ssl_cert_reqsNz%Defaulting to insecure SSL behaviour.�ssl)�	transportrrZuseridrZvirtual_host)�
_parse_url�keys�lower�parse_ssl_cert_reqs�logger�warning�dict)
�urlr�hostr�userrrrr)r"rrr�	parse_url#s(
��r2c
Cs�t|�j}|t|�dd�}td|�}|jp2d}|rP|ddkrP|dd�n|}t|t|jpbd�phd|jt|jpvd�p|dt|j	p�d�p�dt|p�d�p�dt
t|j���S)z5Parse URL into :class:`urlparts` tuple of components.�Nzhttp://rr�/�)
r	r�lenrrrrrrrr.rr)r/rZ
schemeless�partsrrrr�url_to_parts<s

 �r8�**c	
Cs�|�d�g}	|s|rd|r&|	�t|��|rZ|rH|	�|r>d|gndg�n|	�dt|�g�|	�d�|	�|rtt|�nd�|r�|	�d|g�|	�d|g�d�dd�|	D��S)z"Generate URL from component parts.�://�:�@rr4css|]}|rt|�VqdS)N)r)r!�partrrr�	<genexpr>er$zas_url.<locals>.<genexpr>)�append�	safequote�extend�join)
rr0rr1rrr�sanitize�maskr7rrr�as_urlSs
rEcCstt|�d|d��S)z)Return copy of URL with password removed.T)rCrD)rEr(�r/rDrrr�sanitize_urlhsrGcCs t|t�rd|vrt||�S|S)z-Sanitize url, or do nothing if url undefined.r:)�
isinstancerrGrFrrr�maybe_sanitize_urlns
rIcCs2tr*tjtjtjtjtjtjd�}||SdSdS)zMGiven the query parameter for ssl_cert_reqs, return the SSL constant or None.)�
CERT_REQUIRED�
CERT_OPTIONAL�	CERT_NONE�required�optional�noneN)�
ssl_availabler&rJrKrL)Zquery_valueZquery_value_to_constantrrrr+vs�r+)NNNNNNFr9)r9)r9)r�
__future__r�collections.abcr�	functoolsr�typingr�urllib.parserrrr	r&rP�ImportError�logrr@rr,rr2r8r(rErGrIr+rrrr�<module>s.
�




Yohohohohohooho | Sanrei Aya