403Webshell
Server IP : 127.0.0.1  /  Your IP : 216.73.216.109
Web Server : Apache/2.4.54 (Win64) OpenSSL/1.1.1q PHP/8.1.10
System : Windows NT DESKTOP-E5T4RUN 10.0 build 19045 (Windows 10) AMD64
User : SERVERWEB ( 0)
PHP Version : 8.1.10
Disable Function : NONE
MySQL : OFF |  cURL : ON |  WGET : OFF |  Perl : OFF |  Python : OFF |  Sudo : OFF |  Pkexec : OFF
Directory :  C:/cygwin64/lib/python3.9/site-packages/_pytest/__pycache__/

Upload File :
current_dir [ Writeable] document_root [ Writeable]

 

Command :


[ Back ]     

Current File : C:/cygwin64/lib/python3.9/site-packages/_pytest/__pycache__/pastebin.cpython-39.pyc
a

05dm�@s�dZddlZddlmZddlmZddlmZddlZddlm	Z	ddlm
Z
ddlmZdd	l
mZdd
lmZeee�Zedd�dd
�Zejdd�e	dd�dd��Ze	dd�dd�Zeeefed�dd�Zedd�dd�ZdS)zASubmit failure or test session information to a pastebin service.�N)�StringIO)�IO)�Union)�Config)�create_terminal_writer)�Parser)�StashKey)�TerminalReporter)�parser�returnc	Cs*|�d�}|jdddddddgdd	�dS)
Nzterminal reportingz
--pastebin�mode�store�pastebin�failed�allz3Send failed|all info to bpaste.net pastebin service)�metavar�action�dest�default�choices�help)ZgetgroupZ
_addoption)r
�group�r�4/usr/lib/python3.9/site-packages/_pytest/pastebin.py�pytest_addoptions
�rT)Ztrylast)�configrcsR�jjdkrN�j�d�}|durNt�d��jt<|jj	���fdd�}||j_	dS)Nr�terminalreporterzw+bcs8�|fi|��t|t�r$|�d�}�jt�|�dS)N�utf-8)�
isinstance�str�encode�stash�pastebinfile_key�write)�s�kwargs�rZoldwriterr�	tee_write+s

z#pytest_configure.<locals>.tee_write)
�optionr�
pluginmanager�	getplugin�tempfileZ
TemporaryFiler!r"�_twr#)r�trr'rr&r�pytest_configuresr.cCsrt|jvrn|jt}|�d�|��}|��|jt=|j�d�}|jjd=|�	dd�t
|�}|�d|�dS)Nrrr#�=�$Sending information to Paste Servicezpastebin session-log: %s
)r"r!�seek�read�closer)r*r,�__dict__�	write_sep�create_new_paste�
write_line)rZpastebinfileZ
sessionlogr-�pastebinurlrrr�pytest_unconfigure4s



r9)�contentsrc	
Cs�ddl}ddlm}ddlm}|ddd�}d}z$||||��d	�d
����d�}Wn,ty�}zd|WYd}~Sd}~00|�	d
|�}|r�|�d|�
d���Sd|dSdS)z�Create a new paste using the bpaste.net service.

    :contents: Paste contents string.
    :returns: URL to the pasted contents, or an error message.
    rN)�urlopen)�	urlencode�textZ1week)�codeZlexerZexpiryzhttps://bpa.st�ascii)�datarzbad response: %szhref="/raw/(\w+)"z/show/�zbad response: invalid format ('z'))�reZurllib.requestr;�urllib.parser<r r2�decode�OSError�searchr)	r:rBr;r<�params�urlZresponse�exc_info�mrrrr6Es�r6)rrc	Cs�|jjjdkrdSd|jvr�|�dd�|jdD]�}z|jjjdj}Wnt	yf|�
|�}Yn0t�}t|j|�}|�
|�|��}t|�s�J�t|�}|�|�d|���q2dS)Nrr/r0���z --> )rr(rZstatsr5ZlongreprZ
reprtracebackZreprentriesZreprfileloc�AttributeErrorZ_getfailureheadlinerrZ
toterminal�getvalue�lenr6r7)rZrep�msg�fileZtwr$r8rrr�pytest_terminal_summary^s 

rQ)�__doc__r+�ior�typingrrZpytestZ_pytest.configrrZ_pytest.config.argparsingrZ
_pytest.stashrZ_pytest.terminalr	�bytesr"rZhookimplr.r9rr6rQrrrr�<module>s"


Youez - 2016 - github.com/yon3zu
LinuXploit