403Webshell
Server IP : 121.121.20.254  /  Your IP : 216.73.217.51
Web Server : Microsoft-IIS/10.0
System : Windows NT WEB-SERVER 10.0 build 20348 (Windows Server 2022) AMD64
User : IUSR ( 0)
PHP Version : 8.3.28
Disable Function : NONE
MySQL : ON  |  cURL : ON  |  WGET : OFF  |  Perl : OFF  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  C:/Python315/Lib/idlelib/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : C:/Python315/Lib/idlelib/__pycache__/rpc.cpython-315.opt-1.pyc
R
>lqj�Tc�2�Qs]PHs]PHs]PHs]PHs]PHs]PHs]PHs]PH s]PH$s	]PH(s
]PH,s]PH0s]PH4s
]PH8s]PH<sQsQsQQksQQ\O&2sQ sQsQQ\
O.2s-s\O4]2s\O4]2sQ	Q
2sQQ2sQ
sQQ2s QQ\
OB\2s"QQ\2s#QQ2s$Qs%Qs&QQ2s'Qs(\)Q6Xc]QH�G+s+\+Q]Q5P!P!)!aRPC Implementation, originally written for the Python Idle IDE

For security reasons, GvR requested that Idle's Python execution server process
connect to the Idle process, which listens for the connection.  Since Idle has
only one client per server, this was not a limitation.

   +---------------------------------+ +-------------+
   | socketserver.BaseRequestHandler | | SocketIO    |
   +---------------------------------+ +-------------+
                   ^                   | register()  |
                   |                   | unregister()|
                   |                   +-------------+
                   |                      ^  ^
                   |                      |  |
                   | + -------------------+  |
                   | |                       |
   +-------------------------+        +-----------------+
   | RPCHandler              |        | RPCClient       |
   | [attribute of RPCServer]|        |                 |
   +-------------------------+        +-----------------+

The RPCServer handler class is expected to provide register/unregister methods.
RPCHandler inherits the mix-in class SocketIO, which provides these methods.

See the Idle run.main() docstring for further information on how this was
accomplished in Idle.

c�4�[OU2oU!)z*Return code object from marshal string ms.)�marshal�loads)�ms�cos& � C:\Python315\\Lib\idlelib\rpc.py�
unpickle_coder-s��	���r�	�B�
�I�c�B�[OU2o[U11!)zBReturn unpickle function and tuple with marshalled co code object.)r�dumpsr)rrs& r�pickle_coder3s��
���r�	�B��2�%��rc��[O2o[V!2oUOU2UO	2!)z.Return pickled (or marshalled) string for obj.)�io�BytesIO�CodePickler�dump�getvalue)�obj�protocol�f�ps&&  rr
r
9s0��	�
�
��A��A� �A��F�F�3�K��:�:�<�rc�L�\sQs]Bs\O
\-\OAsQs	P!)r�)
�__name__�
__module__�__qualname__�__firstlineno__�types�CodeTyper�copyreg�dispatch_table�__static_attributes__rrrrrBs���n�n�k�L�W�5K�5K�L�Nrrz	127.0.0.1c�D`�\sQs]IsnQQksQsQsQsQsQs	Us
P!)�	RPCServerc�\�Ue[o[OOVU2P!�N)�
RPCHandler�socketserver�	TCPServer�__init__)�self�addr�handlerclasss&&&rr(�RPCServer.__init__Ks#����%�L����'�'��L�Arc��P!)z@Override TCPServer method, no bind() phase for connecting entityr�r)s&r�server_bind�RPCServer.server_bindP���rc�R�UOOUO2P!)z�Override TCPServer method, connect() instead of listen()

Due to the reversed connection, self.server_address is actually the
address of the Idle Client to which we are connecting.

)�socket�connect�server_addressr.s&r�server_activate�RPCServer.server_activateTs��	
�����D�/�/�0rc�4�UOUO1!)z:Override TCPServer method, return already connected socket)r3r5r.s&r�get_request�RPCServer.get_request]s���{�{�D�/�/�/�/rc��g[cg[Oo[QSQ5[QSQ5[Q[O
2O*SQ5[QX#Q5[Q[S2SQ5[OSQ5[QSQ5[QSQ5[O]2P!9h)	z�Override TCPServer method

Error message goes to __stderr__.  No error message if exiting
normally or socket raised EOF.  Other exceptions not handled in
server code will cause os._exit.

��filezUnhandled server exception!z
Thread: %szClient Address: z	Request: z#
*** Unrecoverable, server exiting!z(----------------------------------------z)
----------------------------------------)�
SystemExit�sys�
__stderr__�print�	threading�current_thread�name�repr�	traceback�	print_exc�os�_exit)r)�request�client_address�erfs&&& r�handle_error�RPCServer.handle_erroras���	����	��
	��.�.�C��-�c�*��/�c�:��,��!9�!9�!;�!@�!@�@�s�K��$�n�?��+�t�G�}�3�7����S�)��8�s�C��&�s�#��H�H�Q�K�s��	C�C	Crr$)rrrrr(r/r6r9rMr �__classdictcell__��
__classdict__s@rr"r"Is$����B�

�1�0��rr"c��`�\sQs]�sn]sQQksQsQsQsQs	Qs
QsQsQ	s
Q
sQsQsQ
sQsQsQsQsQsQsQsQs]s]sQsQsQsQsQs Qs!Qs"Qs#Us$P!)�SocketIOc��[O2UmUdV0mVmUe[
oV m-Um-UmP!r$)	rBrC�
sockthread�	debugging�sock�objecttable�objtable�	responses�cvars)r)rWrYrVs&&&&rr(�SocketIO.__init__�s@��#�2�2�4���� �&�N��	���"�H� �
������
rc�Z�UOoPUmUdUO2P!P!r$)rW�close)r)rWs& rr^�SocketIO.close�s&���y�y����	����J�J�L�rc�4�[O]2P!)z!override for specific exit action)rHrIr.s&r�exithook�SocketIO.exithook�s
��
����rc�,�UO%fP!UOQ*[[O2O
2*oSFDoUQ*[U2*oJ	[
U[OQ5P!)N� r<)	rV�location�strrBrCrDrAr?r@)r)�args�s�as&*  r�debug�SocketIO.debug�s_���~�~�~���M�M�C��#�i�&>�&>�&@�&E�&E�"F�F���A��C��#�a�&� �A��
�a�c�n�n�%rc�$�V OU$P!r$)rY)r)�oid�object_s&&&r�register�SocketIO.register�s��$�
�
�c�rc�H�UOUP![cP!h9hr$)rY�KeyError�r)rms&&r�
unregister�SocketIO.unregister�s%��	��
�
�c�"���	��	�s�
�	!�!�!c�8�UOQU2UvovqEqgV@O7c	QQU801!UOU*oUQ6Xc-o	[V�2QU	1!UQ6Xc-o
[	V�2QU
1![V�2%f	QQU801![
V�2oUQ6Xc/UU-U@o[U[2%c[U2oQU1!UQ6Xc[OVVg112Q!QQ	U*1![cQ
t!h9h[cg[cg[cg[co
Q
S
1tPo
=
!Po
=
hQo[!X�X�1*["O$Q5[&O(["O$Q5Qt!9h)z
localcall:�ERRORzUnknown object id: �__methods__�OK�__attributes__zUnsupported method name: �CALL�QUEUEzUnsupported message type: %s�CALLEXCzU*** Internal Error: rpc.py:SocketIO.localcall()

 Object: %s 
 Method: %s 
 Args: %s
r<)rwzBad request format)�QUEUEDN)�	EXCEPTIONN)rj�	TypeErrorrY�_getmethods�_getattributes�hasattr�getattr�
isinstance�RemoteObject�	remoteref�
request_queue�putr>�KeyboardInterrupt�OSError�	ExceptionrAr?r@rFrG)r)�seqrJ�howrm�
methodnamerg�kwargsr�methods�
attributes�method�ret�ex�msgs&&&            r�	localcall�SocketIO.localcall�s����
�
�<��)�	3�3:�0�C�0�#�4��m�m�#��2�3�'�:�;�;��m�m�C� ����&��G���%��'�?�"��)�)��J��3�+��*�%�%��s�'�'��8���G�H�H���)��	'��f�}��d�-�f�-���c�<�0�0�#�C�.�C��c�{�"�����!�!�3��(>�"?�@�&�&��!?�#�!E�F�F��5�	3�2�2�	3��6�	�� �	���	���	#��r�?�"��	'�<�C��#�f�+�+�#�.�.�A����S�^�^�4�&�&�sl�C>�D�$D�D�D�D�3
D�>	D�D�
D�	F�
F�&
F�1
F�<F�=E�F�AFc�n�UOQV2UOVV42oUOU2!)zremotecall:asynccall: )rj�	asynccall�asyncreturn�r)rmr�rgr�r�s&&&&& r�
remotecall�SocketIO.remotecall�s2���
�
�+�S�=��n�n�S�d�;������$�$rc�n�UOQV2UOVV42oUOU2!)zremotequeue:asyncqueue: )rj�
asyncqueuer�r�s&&&&& r�remotequeue�SocketIO.remotequeue�s2���
�
�-�s�?��o�o�c�t�<������$�$rc��QVV411oUO2o[O2UO6wc$[O2oVpO
U$UO
QU*VV42UOVe12U!)r{z
asynccall:%d:��newseqrBrCrU�	Conditionr[rj�
putmessage�r)rmr�rgr�rJr��cvars&&&&&   rr��SocketIO.asynccall�sr���C�T�:�;���k�k�m���#�#�%����8��&�&�(�D�"�J�J�s�O��
�
�O�c�)�C�T�J������'��
rc��QVV411oUO2o[O2UO6wc$[O2oVpO
U$UO
QU*VV42UOVe12U!)r|zasyncqueue:%d:r�r�s&&&&&   rr��SocketIO.asyncqueue�ss���S�d�;�<���k�k�m���#�#�%����8��&�&�(�D�"�J�J�s�O��
�
�$�s�*�S�d�K������'��
rc��UOQU*2UOUQQ5oUOQU*U2UOU2!)z#asyncreturn:%d:call getresponse(): 皙�����?)�waitzasyncreturn:%d:response: )rj�getresponse�decoderesponse)r)r��responses&& rr��SocketIO.asyncreturn�sN���
�
�8�3�>�?��#�#�C�d�#�3���
�
�/�#�5��A��"�"�8�,�,rc�L�Uvq#UQ6XcU!UQ6XcP!UQ6XcUOQ2P!UQ6Xc$UOQ2UO2P!UQ6XcUOQU2[U2gUQ6XcUOQ	U2Ug[V#2g)
ryr~rzdecoderesponse: EXCEPTION�EOFzdecoderesponse: EOFrwzdecoderesponse: Internal ERROR:r}zdecoderesponse: Call Exception:)rj�decode_interrupthook�RuntimeError�SystemError)r)r�r��whats&&  rr��SocketIO.decoderesponse�s����	���$�;��K��(�?���+���J�J�2�3���%�<��J�J�,�-��%�%�'���'�>��J�J�8�$�?��t�$�$��)���J�J�8�$�?��J��#�$�$rc��[g)�)�EOFErrorr.s&rr��SocketIO.decode_interrupthooks���rc�v�UOPQQ5P![cSOQ2P!h9h)z�Listen on socket until I/O not ready or EOF

pollresponse() will loop looking for seq number None, which
never comes, and exit on EOFError.

r�)�myseqr�zmainloop:return)r�r�rjr.s&r�mainloop�SocketIO.mainloops9��	����4�d��3���	��J�J�(�)��	�s��	8�8�8c�l�UOV2oUdUvqEUQ6XcV@OU21oU!)Nry)�_getresponse�_proxify)r)r�r�r�r�r�s&&&   rr��SocketIO.getresponse"s<���$�$�U�1���� �I�C��d�{��
�
�d� 3�3���rc���[U[2%c[VO2![U[2%c [	[UOU22!U!r$)r��RemoteProxy�RPCProxyrm�list�mapr�)r)rs&&rr��SocketIO._proxify*sF���c�;�'�'��D�'�'�*�*��c�4� � ���D�M�M�3�/�0�0��
rc���UOQU2[O2UOIcUO	V2oUeJU!UO
U*oUO
2VO7cUO2J"UOU*oUOQU8QU802UOUUO
UUO2U!)z_getresponse:myseq:z
_getresponse:z: thread woke up: response: )
rjrBrCrU�pollresponser[�acquirerZr��release)r)r�r�r�r�s&&&  rr��SocketIO._getresponse2s����
�
�(�%�0��#�#�%����8���,�,�U�9���'�#�O��:�:�e�$�D��L�L�N��~�~�-��	�	���~�~�e�,�H��J�J��x�)�
*����u�%��
�
�5�!��L�L�N��Orc�<�UO]*9UmoU!)�)�nextseq)r)r�s& rr��SocketIO.newseqHs��!�\�\�A�-�-���s��
rc�(�UOQU]**2[U2o[OQ[U22U*o[U2]6�cP[O,UO,,2vq4oUOOUP[2oV&PoJ_P![Oc([	Q[S2[OQ5gh9h[[ 1c
[#Q2gh9h)zputmessage:%d:zCannot pickle:r<�<izsocket no longer exists)rjr
�pickle�
PicklingErrorrArEr?r@�struct�pack�len�selectrW�send�BUFSIZE�AttributeErrorr�r�)r)�messagerh�r�w�x�ns&&     rr��SocketIO.putmessageLs����
�
�#�g�a�j�0�1�	��g��A�
�K�K��c�!�f�%��)���!�f�q�j�
9� �-�-��T�Y�Y�K��<���a��I�I�N�N�1�X�g�;�/���"��A�
��	�#�#�	��"�D��M����G��	��#�I�.�
9��7�8�8�
9�s$�B5�%AC4�5C1�	(C1�4D�
Drc��UO2[UO2UO6c�[OUO
O
2,,,U2vq#o[U2]6XcP!UO
O[2o[U2]6Xc[gU9OU*
tmUO2UO2![c[gh9h)�)�_stage0r��buff�bufneedr�rW�fileno�recvr�r�r��_stage1)r)r�r�r�r�rhs&&    r�
pollpacket�SocketIO.pollpacket`s��������t�y�y�>�D�L�L�(��m�m�T�Y�Y�%5�%5�%7�$8�"�b�$�G�G�A�!��1�v��{��
��I�I�N�N�7�+���1�v��{����I�I��N�I��L�L�N��|�|�~���
�
���
�s�>C,�,	C>�6C>c��UO]6Xct[UO2]6�cXUOQ*oUOQ*Um[OQU2]*Um]UmP!P!P!)r�:N�N:r�NNr�)�bufstater�r�r��unpackr�)r)rhs& rr��SocketIO._stage0ps_���=�=�A��#�d�i�i�.�A�"5��	�	�"�
�A��	�	�"�
�D�I�!�=�=��q�1�!�4�D�L��D�M�	#6�rc��UO]6Xcn[UO2UO6�cHUOPUOoUOUOPUm]Um]UmU!P!P!��)r�r�r�r�)r)�packets& rr��SocketIO._stage1wsg���=�=�A��#�d�i�i�.�D�L�L�"@��Y�Y�}����-�F��	�	�$�,�,�-�0�D�I��D�L��D�M��M�#A�rc��UOU2oUeP![OU2oU![Oc�[	Q[
OQ5[	Q[S2[
OQ5[O[
OQ5[	Q[
OQ5gh9h)Nz-----------------------r<zcannot unpickle packet:)
r�r�r�UnpicklingErrorrAr?r@rErF�print_stack)r)r�r�r�s&&  r�pollmessage�SocketIO.pollmessages�������&���>��	��l�l�6�*�G����
�%�%�	��+�#�.�.�A��+�T�&�\����O��!�!�s�~�~�6��+�#�.�.�A��	�s�2�C	�BC	c�(�[O]2oUvqEUQU11oUOU2UOU2oUeP!UvqGU]*oUOQVA1*2UQ7cgUOQU*2UOVG2oUOQVE1*2UQ6XcUOVE12LUQ6XcJ�VA6XcU!UOOUP2o	U	d?U	O2VpOU$U	O2U	O2CJG[OcCK-h9h[cSO2P![cP!h9h)a�Handle messages received on the socket.

Some messages received may be asynchronous 'call' or 'queue' requests,
and some may be responses for other threads.

'call' requests are passed to self.localcall() with the expectation of
immediate execution, during which time the socket is not serviced.

'queue' requests are used for tasks (which may block or hang) to be
processed in a different thread.  These requests are fed into
request_queue by self.localcall().  Responses to queued requests are
taken from response_queue and sent across the link with the associated
sequence numbers.  Messages in the queues are (sequence_number,
request/response) tuples and code using this module removing messages
from the request_queue is responsible for returning the correct
sequence number in the response_queue.

pollresponse() will loop until a response message with the myseq
sequence number is received, and will save other responses in
self.responses and notify the owning thread.

ryzpollresponse:%d:myseq:%sr{r|zpollresponse:%d:localcall:call:z%pollresponse:%d:localcall:response:%s)r{r|)�response_queue�getr��queue�Emptyr�r��
handle_EOFr�rjr�r[r�rZ�notifyr�)
r)r�r��qmsgr�r�r��resqr��cvs
&&&       rr��SocketIO.pollresponse�s~��.�
)�%�)�)�!�,��!%�
����x� 0�1������(�
��*�*�4�0���?��#� �I�C��q�'�C��J�J�1�S�L�@�A��'�'��
�
�<�s�B�C��>�>�#�4���
�
�B�!�_�-�.��&�=��O�O�S�O�4��G�^��������Z�Z�^�^�C��.���>��J�J�L�*.�N�N�3�'��I�I�K��J�J�L���Y�;�;�
��
���
����!��!�
��
�s:�E	�E%�	E"�E"�!E"�%	F�/F�F�F�Fc�6�UO2UOQ2UOFDUoUOU*oUO2QUOU$UO2UO
2JW	UO2P!)z+action taken upon link being closed by peerr)r�N)�EOFhookrjr[r�rZrr�ra)r)�keyr	s&  rr�SocketIO.handle_EOF�sf�������
�
�<� ��:�:�C����C��B��J�J�L�"/�D�N�N�3���I�I�K��J�J�L��	
�
�
�rc��P!)zBClasses using rpc client/server can override to augment EOF actionrr.s&rr�SocketIO.EOFhook�r1r)
r�r�r�r[rVr�rYrZrWrU)NN)%rrrrr�r(r^rarjrortr�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�r�rrr rOrPs@rrSrS�s������G�	���&�%��,'�\%�
%�
��-�%�*�����,�� �D��G��H�� ���G�R�
�
rrSc��\sQsQsQsP!)r���r)rrrrr rrrr�r��s��rr�c�B�[U2oU[U$[U2!r$)�idrXr�)rrms& rr�r��s ��
�S�'�C��K����s��rc�(`�\sQsQsnQsQsUsP!)r���c��VmP!r$�rmrss&&rr(�RemoteProxy.__init__�s���rr)rrrrr(r rOrPs@rr�r��s�����rr�c�<`�\sQsQsnP
sQsQsQsQsQs	Us
P!)r%�z#Sc�~�Vm[OV2[OOVV#2P!r$)�current_handlerrSr(r&�BaseRequestHandler)r)rWr*�svrs&&&&rr(�RPCHandler.__init__�s,��"�����$�%��'�'�0�0��T�Grc�(�UO2P!)z(handle() method required by socketserver)r�r.s&r�handle�RPCHandler.handles���
�
�rc��[V2!r$�r�rss&&r�get_remote_proxy�RPCHandler.get_remote_proxy�
����"�"rr)rrrrrVrer(r"r&r rOrPs@rr%r%�s$�����I��H�H�
�#�#rr%c�p`�\sQsQsnP
sQs]s\O\O1Qks
QsQsQs
UsP!)�	RPCClient�z#Cc��[OV#2UmUOOU2UOO]2P!r�)r3�listening_sock�bind�listen)r)�address�family�types&&&&rr(�RPCClient.__init__s;��$�m�m�F�9������ � ��)����"�"�1�%rc�.�UOO2vqUO%c[QU[O
Q5U]*[6Xc[OV2P![QU[O
Q5[g)z****** Connection request from r<z** Invalid host: )
r-�acceptrVrAr?r@�	LOCALHOSTrSr(r�)r)�working_sockr0s&  rr5�RPCClient.acceptsc�� $� 3� 3� :� :� <����>�>�>��3�W�3�>�>�R��1�:��"����d�1��%�w�S�^�^�D��Mrc��[V2!r$r%rss&&rr&�RPCClient.get_remote_proxy"r(r)r-)rrrrrVrer�r3�AF_INET�SOCK_STREAMr(r5r&r rOrPs@rr*r*s7�����I��H��G�'-�~�~�F�<N�<N�&�
�#�#rr*c�B`�\sQsQsnPsPsQsQsQsQs	Qs
UsP!)r��&c� �VmV mP!r$)�sockiorm)r)r@rms&&&rr(�RPCProxy.__init__+s�����rc��UOeUO2UOOU2%c"[UOUO
U2!UOeUO2VO7c,UOOUO
QU1-2oU![U2g)N�__getattribute__)
�_RPCProxy__methods�_RPCProxy__getmethodsr�MethodProxyr@rm�_RPCProxy__attributes�_RPCProxy__getattributesr�r�)r)rD�values&& r�__getattr__�RPCProxy.__getattr__/s����>�>�!������>�>���d�#�#��t�{�{�D�H�H�d�;�;����$�� � �"��$�$�$��K�K�*�*�4�8�8�5G�,0�7�B�8�E��L� ��&�&rc�b�UOOUOQQ-2UmP!)rzr)r@r�rmrGr.s&r�__getattributes�RPCProxy.__getattributes=s'�� �K�K�2�2�4�8�8�0@�"�b�J��rc�b�UOOUOQQ-2UmP!)rxr)r@r�rmrDr.s&r�__getmethods�RPCProxy.__getmethodsAs&�����/�/����0=�r�2�G��r)�__attributes�	__methodsrmr@)rrrrrDrGr(rJrHrEr rOrPs@rr�r�&s+�����I��L��'�J�G�Grr�c���[U2FD%o[V2o[U2%fJ!]V$J'	[U[2%c"UO
FDo[
VA2J	P!P!r�)�dirr��callabler�r2�	__bases__r�)rr�rD�attr�supers&&   rr�r�EsV���C����s�!���D�>�>��G�M���#�t����]�]�E���'�#�rc�r�[U2FD%o[V2o[U2%cJ!]V$J'	P!r�)rUr�rV)rr�rDrXs&&  rr�r�Ps+���C����s�!����~�~� �J��rc�.`�\sQsQsnQsQsQsUsP!)rF�Wc�,�VmV mV0mP!r$)r@rmrD)r)r@rmrDs&&&&rr(�MethodProxy.__init__Ys�������	rc�j�UOOUOUOV2oU!r$)r@r�rmrD)r)rgr�rIs"*, r�__call__�MethodProxy.__call__^s'�����&�&�t�x�x����D�I���r)rDrmr@)rrrrr(r`r rOrPs@rrFrFWs�����
�rrFc��UeP!P[m[U2o[OOU2[OOQ2U[mP![cIQoSOSQ2oSOSQ2o[OOS2K~h9h)z9Override standard display hook to use non-locale encoding�ascii�backslashreplace�strict�
)	�builtins�_rEr?�stdout�write�UnicodeEncodeError�encode�decode)rI�text�encoding�bytess&   r�displayhookrqfs����}���H�J���;�D���
�
������J�J���T���H�J���������H�&8�9���|�|�H�h�/���
�
������s�A*�*	B=�4AB=�<B=�__main__)�mainzidlelib.idle_test.test_rpc)�	verbosityr$i ),�__doc__rgrr
rrHr�rr�r3r&r�r?rBrFrrrr
�Picklerrr�r6r'r"rX�Queuer�rrSr�r�r�rr%r*r�r�r�rFrqr�unittestrsrrr�<module>rys"���8��	��	�
��
�
��
�
����� ��M�&�.�.�M����	�.��&�&�.�d�����A��
����Q���e
�e
�R	�	�
���#��0�0�(�#�$#��#�4G�G�>	(�!�	�	��&�z����	%��4�r

Youez - 2016 - github.com/yon3zu
LinuXploit