403Webshell
Server IP : 217.160.0.244  /  Your IP : 216.73.217.138
Web Server : Apache
System : Linux infong-eu155 4.4.400-icpu-108 #2 SMP Wed Feb 11 11:51:01 UTC 2026 x86_64
User : u100174116 ( 6746176)
PHP Version : 8.5.10
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : OFF  |  Pkexec : OFF
Directory :  /lib/python3/dist-packages/dulwich/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3/dist-packages/dulwich/__pycache__/protocol.cpython-313.pyc
�

mEdg�L��:�SrSSKJr SSKJr SSKJr SSKrSSKJ	r	J
r
 Sr/S	QrS
r
SrSrSrSrS
rSrS
rSrS
rSrSrSrSrSrSrSrSrSrSr Sr!Sr"Sr#Sr$Sr%Sr&Sr'Sr(S r)S!r*S"r+S#r,S$r-\ \$\%\'\/r.\/"/\.Q\&P\P\P\P\P\(P\#P\P\P\)P\*P\+P5r0\/"/\.Q\"P\P\!P\P5r1S%r2S&r3S'r4S(r5S)r6S*r7S+r8S,r9S-r:Sr;S.r<S/r=S0r>S1r?S2r@S3rAS4rBS5rCS6rD"S7S85rES9rF"S:S;\E5rGS<rHS=rIS>rJ"S?S@5rK"SASB5rLSCrMSHSDjrNSErOSFrPSISGjrQg)Jz<Generic functions for talking the git smart server protocol.�)�BytesIO)�SEEK_END)�OptionalN�)�GitProtocolError�HangupExceptioni�$)rr�r	s(0000000000000000000000000000000000000000�satomicsdeepen-sinces
deepen-notsdeepen-relativesdelete-refssinclude-tag�	multi_ack�multi_ack_detailedsno-donesno-progresss	ofs-deltasquiets
report-statussshallows	side-bands
side-band-64ks	thin-packsagentssymrefsallow-tip-sha1-in-wantsallow-reachable-sha1-in-wantsfetchsfilterscapabilities^{}i���sNAK
c��SSR[[[R55-RS5$)Nzdulwich/�.�ascii)�join�map�str�dulwich�__version__�encode���2/usr/lib/python3/dist-packages/dulwich/protocol.py�agent_stringr�s.������#�c�7�+>�+>�"?�@�@�H�H��Q�Qrc�*�[S-[5-$)N�=)�CAPABILITY_AGENTrrrr�capability_agentr�s���d�"�\�^�3�3rc�&�[S-U-S-U-$)Nr�:)�CAPABILITY_SYMREF)�from_ref�to_refs  r�capability_symrefr#�s���t�#�h�.��5��>�>rc�J�UVs1sHn[U5SiM sn$s snf�Nr)�parse_capability��capabilities�cs  r�extract_capability_namesr*�s%��,8�9�L�q��Q���"�L�9�9��9s� c�h�URSS5n[U5S:XaUSS4$[U5$)Nrrr)�split�len�tuple)�
capability�partss  rr&r&�s8�����T�1�%�E�
�5�z�Q���a��$�����<�rc�>�UVs/sHn[U6PM
 sn$s snf�N)r#)�symrefs�ks  r�symref_capabilitiesr5�s ��+2�3�7�a��q�!�7�3�3��3s�sdeepens	unshallowsdoneswantshavec�`�US-SRUVs/sHo"S-PM	 sn5-$s snf)N� r��r)�cmd�args�as   r�format_cmd_pktr=�s.����:����t�!<�t�!�u�9�t�!<�=�=�=��!<s�+
c�z�URS5nUSUXS-Sp2USSS:XdeX#SSRS54$)Nr7r���r8)�findr,)�line�	splice_atr:r;s    r�
parse_cmd_pktrC�sR���	�	�$��I��Z�i� �$�1�}��"7�����9������S�b�	����&�&�&rc�P�UcgS[U5S--RS5U-$)z�Wrap data in a pkt-line.

Args:
  data: The data to wrap, as a str or None.
Returns: The data prefixed with its length in pkt-line format; if data was
    None, returns the flush-pkt ('0000').
s0000z%04x�r)r-r)�datas r�pkt_linerG�s/���|���c�$�i�!�m�$�,�,�W�5��<�<rc�z�SRUVs/sHn[U5PM sn5[S5-$s snf)zTWrap a sequence of data in pkt-lines.

Args:
  seq: An iterable of strings to wrap.
rN)rrG)�seq�ss  r�pkt_seqrK�s2���8�8�#�.�#�Q�X�a�[�#�.�/�(�4�.�@�@��.s�8c�^�UR5V^Vs0sH%umn[U4SjU55(dM"TU_M' snn$s snnf)zyFilter refs to only include those with a given prefix.

Args:
  refs: A list of refs.
  prefix: The prefix to filter by.
c3�F># �UHnTRU5v� M g7fr2)�
startswith)�.0�pr4s  �r�	<genexpr>�$filter_ref_prefix.<locals>.<genexpr>�s����0S�(�Q����a���(�s�!)�items�any)�refs�prefixesr4�vs  ` r�filter_ref_prefixrX�s:���"�Z�Z�\�T�\�T�Q��S�0S�(�0S�-S�D�A�q�D�\�T�T��Ts
�!A�Ac��\rSrSrSrSSSjjrSSjrSrSrS	r	S\
4S
jrSSjrSr
SS
jrSSjrSSjrSrSrg)�Protocol��a�Class for interacting with a remote git process over the wire.

Parts of the git wire protocol use 'pkt-lines' to communicate. A pkt-line
consists of the length of the line as a 4-byte hex string, followed by the
payload data. The length includes the 4-byte header. The special line
'0000' indicates the end of a section of input and is called a 'flush-pkt'.

For details on the pkt-line format, see the cgit distribution:
    Documentation/technical/protocol-common.txt
N�returnc�B�XlX lX0lX@lSUlgr2)�read�write�_close�report_activity�
_readahead)�selfr^r_�closeras     r�__init__�Protocol.__init__�s���	��
���.��-1��rc�H�UR(aUR5 ggr2)r`�rcs rrd�Protocol.close�s���;�;��K�K�M�rc��U$r2rrhs r�	__enter__�Protocol.__enter__�s���rc�$�UR5 gr2)rd)rc�exc_type�exc_val�exc_tbs    r�__exit__�Protocol.__exit__�s���
�
�rc�L�URc
URnOURRnSUlU"S5nU(d[e[US5nUS:XdUS:Xa$UR(aUR	SS5 gUR(aUR	US5 U"US-
5n[U5S-U:wa[
S[U5S-SS	US35eU$![an[UeSnAf[an[
[U55UeSnAff=f)
z�Reads a pkt-line from the remote git process.

This method may read from the readahead buffer; see unread_pkt_line.

Returns: The next string from the stream, without the length prefix, or
    None for a flush-pkt ('0000') or delim-pkt ('0001').
NrE�rrr^zLength of pkt read �04xz does not match length prefix )
rbr^r�intrar-r�ConnectionResetError�OSErrorr)rcr^�sizestr�size�pkt_contents�excs      r�
read_pkt_line�Protocol.read_pkt_line�s���?�?�"��9�9�D��?�?�'�'�D�"�D�O�	 ��1�g�G��%�%��w��#�D��q�y�D�A�I��'�'��(�(��F�3���#�#��$�$�T�6�2���q��>�L��<� �1�$��,�&�)�#�l�*;�a�*?��)D�Db�cg�hk�bl�m��� ���$�	+�!�s�*���	6�"�3�s�8�,�#�5��	6�s*�AC+�
.C+�+
D#�5C<�<
D#�	D�D#c�h�UR5nURU5 g![a gf=f)z�Test whether the protocol stream has reached EOF.

Note that this refers to the actual stream EOF and not just a
flush-pkt.

Returns: True if the stream is at EOF, False otherwise.
TF)r}r�unread_pkt_line)rc�	next_lines  r�eof�Protocol.eofs<��	��*�*�,�I�	
���Y�'����	��	�s�$�
1�1c�f�URb[S5e[[U55Ulg)aUnread a single line of data into the readahead buffer.

This method can be used to unread a single pkt-line into a fixed
readahead buffer.

Args:
  data: The data to unread, without the length prefix.

Raises:
  ValueError: If more than one pkt-line is unread.
Nz'Attempted to unread multiple pkt-lines.)rb�
ValueErrorrrG�rcrFs  rr��Protocol.unread_pkt_line"s*���?�?�&��F�G�G�!�(�4�.�1��rc#�v# �UR5nU(aUv� UR5nU(aMgg7f)z�Read a sequence of pkt-lines from the remote git process.

Returns: Yields each line of data up to but not including the next
    flush-pkt.
N)r})rc�pkts  r�read_pkt_seq�Protocol.read_pkt_seq2s2���� � �"����I��$�$�&�C��c�s�39�9c���[U5nURU5 UR(aUR[U5S5 gg![an[[
U55UeSnAff=f)z�Sends a pkt-line to the remote git process.

Args:
  line: A string containing the data to send, without the length
    prefix.
r_N)rGr_rar-rxrr)rcrAr|s   r�write_pkt_line�Protocol.write_pkt_line=s_��	6��D�>�D��J�J�t���#�#��$�$�S��Y��8�$���	6�"�3�s�8�,�#�5��	6�s�AA�
A0�A+�+A0c��U(a9UR[[U/55USS-5 USSnU(aM8gg)z�Write multiplexed data to the sideband.

Args:
  channel: An int specifying the channel to write to.
  blob: A blob of data (as a string) to send on this channel.
N��)r��bytes�	bytearray)rc�channel�blobs   r�write_sideband�Protocol.write_sidebandLs>�������i��	�&:� ;�d�6�E�l� J�K����<�D��drc�:�UR[U/UQ765 g)z�Send a command and some arguments to a git server.

Only used for the TCP git protocol (git://).

Args:
  cmd: The remote service to access.
  args: List of arguments to send to remove service.
N)r�r=)rcr:r;s   r�send_cmd�Protocol.send_cmdZs��	
���N�3�6��6�7rc�8�UR5n[U5$)z�Read a command and some arguments from the git client.

Only used for the TCP git protocol (git://).

Returns: A tuple of (command, [list of arguments]).
)r}rC)rcrAs  r�read_cmd�Protocol.read_cmdes���!�!�#���T�"�"r)r`rbr^rar_)NN�r\N)�__name__�
__module__�__qualname__�__firstlineno__�__doc__rerdrkrqr}�boolr�r�r�r�r�r�r��__static_attributes__rrrrZrZ�sK��	�2����# �J
�T�
�2� 	'�
6� �	8�#rrZi c�H^�\rSrSrSrSS\4SU4SjjjrSrSrSr	U=r
$)	�ReceivableProtocolisa�Variant of Protocol that allows reading up to a size without blocking.

This class has a recv() method that behaves like socket.recv() in addition
to a read() method.

If you want to read n bytes from the wire and block until exactly n bytes
(or EOF) are read, use read(n). If you want to read at most n bytes from
the wire but don't care if you get less, use recv(n). Note that recv(n)
will still block until at least one byte is read.
Nc�n>�[TU]URX#US9 Xl[	5UlXPlg)N)rdra)�superrer^�_recvr�_rbuf�	_rbufsize)rc�recvr_rdra�rbufsize�	__class__s      �rre�ReceivableProtocol.__init__s0���	������E���X��
��Y��
�!�rc���US:�deURnUR5nURS[5 UR5U-
nXA:�awURU5 UR	U5n[5UlURR
UR	55 URRS5 U$[5UlX-
nURU5nU(dO\[U5nX�:Xa	U(dU$X�:XaUR
U5 AO+X�::dSUSUS35eUR
U5 XH-
nAMyURU5 UR	5$)Nrz_recv(z) returned z bytes)	r��tell�seekrr^rr_r�r-)	rcrz�buf�start�buf_len�rv�leftrF�ns	         rr^�ReceivableProtocol.read�s=���a�x��x�
�j�j�����
������H���(�(�*�u�$���?��H�H�U�O����$��B� ��D�J��J�J���S�X�X�Z�(��J�J�O�O�A���I��Y��
���>�D��:�:�d�#�D����D�	�A��y�����y��	�	�$�����9�A��t�f�K��s�&�A�A�9��I�I�d�O��L�G��3�6	������x�x�z�rc��US:�deURnUR5nURS[5 UR5nURU5 XC-
nU(d_UR	UR
5n[
U5U:XaU$[5nURU5 URS5 AX lURU5$r%)
r�r�r�rr�r�r-rr_r^)rcrzr�r�r�r�rFs       rr��ReceivableProtocol.recv�s����a�x��x��j�j�����
������H���(�(�*������������:�:�d�n�n�-�D��4�y�D� ����)�C��I�I�d�O��H�H�Q�K���J��x�x��~�r)r�r�r�r�)r�r�r�r�r��	_RBUFSIZErer^r�r��
__classcell__)r�s@rr�r�ss3���	�"&�t�i�"�	
�"�"�;�z�rr�c��SU;aU/4$UR5RS5upXR5RS54$)z�Extract a capabilities list from a string, if present.

Args:
  text: String to extract from
Returns: Tuple with text with capabilities removed and list of capabilities
r8r7)�rstripr,�strip)�textr(s  r�extract_capabilitiesr��sK��
�D���R�x������,�,�U�3��D��$�$�&�,�,�T�2�3�3rc��UR5RS5n[U5S:aU/4$SRUSS5USS4$)a\Extract a capabilities list from a want line, if present.

Note that want lines have capabilities separated from the rest of the line
by a space instead of a null byte. Thus want lines have the form:

    want obj-id cap1 cap2 ...

Args:
  text: Want line to extract from
Returns: Tuple with text with capabilities removed and list of capabilities
r7r
Nr	)r�r,r-r)r��
split_texts  r�extract_want_line_capabilitiesr��sO������$�$�T�*�J�
�:�����R�x���I�I�j��!�n�%�z�!�"�~�6�6rc�>�SU;a[$SU;a[$[$)z.Extract the ack type from a capabilities list.rr)�MULTI_ACK_DETAILED�	MULTI_ACK�
SINGLE_ACK)r(s r�ack_typer��s$����,�!�!�	��	%����rc�:�\rSrSrSrSS	SjjrS	SjrS	SjrSrg)
�BufferedPktLineWriteriaWriter that wraps its data in pkt-lines and has an independent buffer.

Consecutive calls to write() wrap the data in a pkt-line and then buffers
it until enough lines have been written such that their total length
(including length prefix) reach the buffer size.
Nc�H�XlX l[5UlSUlg)z�Initialize the BufferedPktLineWriter.

Args:
  write: A write callback for the underlying writer.
  bufsize: The internal buffer size, including length prefixes.
rN)�_write�_bufsizer�_wbuf�_buflen)rcr_�bufsizes   rre�BufferedPktLineWriter.__init__s�����
��Y��
���rc�X�[U5n[U5nURU-UR-
nUS:�a3X4-
nURRUSU5 UR
5 OSnX%SnURRU5 U=R[U5-
slg)z&Write data, wrapping it in a pkt-line.rN)rGr-r�r�r�r_�flush)rcrFrA�line_len�overr��saveds       rr_�BufferedPktLineWriter.writes�����~���t�9���|�|�h�&����6���1�9��O�E��J�J���T�&�5�\�*��J�J�L��E��V����
�
���������E�
�"�rc��URR5nU(aURU5 SUl[	5Ulg)zFlush all data from the buffer.rN)r��getvaluer��_lenrr�s  rr��BufferedPktLineWriter.flush's3���z�z�"�"�$����K�K�����	��Y��
r)r�r�r�r�r�)r�r�)	r�r�r�r�r�rer_r�r�rrrr�r�s���
�
#�rr�c�2�\rSrSrSrSSjrSSjrSrSrg)	�
PktLineParseri0zBPacket line parser that hands completed packets off to a callback.Nc�.�Xl[5Ulgr2)�
handle_pktrrb)rcr�s  rre�PktLineParser.__init__3s��$��!�)��rc���URRU5 URR5n[U5S:ag[U5S:�af[	USSS5nUS:XaURS5 USSnO)U[U5::aURUSU5 X#SnOO[U5S:�aMf[
5UlURRU5 g)zAParse a fragment of data and call back for any completed packets.rENrtr)rbr_r�r-rvr�r)rcrFr�rzs    r�parse�PktLineParser.parse7s��������d�#��o�o�&�&�(���s�8�a�<���#�h�!�m��s�2�A�w��#�D��q�y�����%��!�"�g����S��!�����A�d��,��%�j����#�h�!�m�"�)��������c�"rc�6�URR5$)zRead back any unused data.)rbr�rhs r�get_tail�PktLineParser.get_tailJs�����'�'�)�)r)rbr�r�)	r�r�r�r�r�rer�r�r�rrrr�r�0s��L�$�#�&*rr�c�V�SRUVs/sHnSU-PM
 sn5$s snf)Nrr7r9r's  r�format_capability_liner�Os'���8�8�|�4�|�!�T�A�X�|�4�5�5��4s�&c�R�UcUS-U-S-$US-U-S-[U5-S-$)Nr7�
r8)r�)�ref�shar(s   r�format_ref_liner�SsA�����T�z�C��%�'�'��T�z�C��%�'�*@��*N�N�QV�V�Vrc��[S-U-$�Nr7)�COMMAND_SHALLOW�r�s r�format_shallow_liner�Zs���T�!�C�'�'rc��[S-U-$r�)�COMMAND_UNSHALLOWr�s r�format_unshallow_liner�^s���t�#�c�)�)rc�0�U(aSU-nSU-U-S-$)Nr7sACK r�r)r�r�s  r�format_ack_liner�bs"����(�?���S�=�8�#�e�+�+rr2)r)Rr��ior�osr�typingrr�errorsrr�TCP_GIT_PORT�GIT_PROTOCOL_VERSIONS�"DEFAULT_GIT_PROTOCOL_VERSION_FETCH�!DEFAULT_GIT_PROTOCOL_VERSION_SEND�ZERO_SHAr�r�r��SIDE_BAND_CHANNEL_DATA�SIDE_BAND_CHANNEL_PROGRESS�SIDE_BAND_CHANNEL_FATAL�CAPABILITY_ATOMIC�CAPABILITY_DEEPEN_SINCE�CAPABILITY_DEEPEN_NOT�CAPABILITY_DEEPEN_RELATIVE�CAPABILITY_DELETE_REFS�CAPABILITY_INCLUDE_TAG�CAPABILITY_MULTI_ACK�CAPABILITY_MULTI_ACK_DETAILED�CAPABILITY_NO_DONE�CAPABILITY_NO_PROGRESS�CAPABILITY_OFS_DELTA�CAPABILITY_QUIET�CAPABILITY_REPORT_STATUS�CAPABILITY_SHALLOW�CAPABILITY_SIDE_BAND�CAPABILITY_SIDE_BAND_64K�CAPABILITY_THIN_PACKrr �!CAPABILITY_ALLOW_TIP_SHA1_IN_WANT�'CAPABILITY_ALLOW_REACHABLE_SHA1_IN_WANT�CAPABILITY_FETCH�CAPABILITY_FILTER�CAPABILITIES_REF�COMMON_CAPABILITIES�set�KNOWN_UPLOAD_CAPABILITIES�KNOWN_RECEIVE_CAPABILITIES�DEPTH_INFINITE�NAK_LINErrr#r*r&r5�COMMAND_DEEPENr�r��COMMAND_DONE�COMMAND_WANT�COMMAND_HAVEr=rCrGrKrXrZr�r�r�r�r�r�r�r�r�r�r�r�rrr�<module>r&s���.C�����5���"��%&�"�$%�!���
�
�
�	�����������)��%��/��'��'��#�� 5����'��#����+����#��+��#������$=�!�*I�'�����&��������� ��	����	��	&�	�
	��	 �
�	��	��	��	#��	*��	0��	����"!��	�� ��	��	�	�
	��������R�4�?�:��4����� ��������>�'�
=�A�U�\#�\#�~
�	�f��f�R
4�7�$�)�)�X*�*�>6�W�(�*�,r

Youez - 2016 - github.com/yon3zu
LinuXploit