⚝
One Hat Cyber Team
⚝
Your IP:
216.73.216.166
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 :
~
/
var
/
opt
/
nydus
/
ops
/
mysql
/
connector
/
__pycache__
/
View File Name :
network.cpython-39.pyc
a ��Rh�m � @ sJ d Z ddlZddlZddlZddlZddlmZmZ ddlm Z ddl mZmZm Z mZmZmZ z2ddlZejejejejd�Zeed�o�ejZW n ey� dZdZY n0 d d lmZmZmZmZ dZ dZ!d Z"dZ#e$e%d�dd�Z&G dd� de�Z'G dd� de'�Z(G dd� de(�Z)G dd� de�Z*G dd� de*�Z+G dd� de*�Z,dS )zGModule implementing low-level socket communication with MySQL servers. � N)�ABC�abstractmethod)�deque)�Any�Deque�List�Optional�Tuple�Union)�TLSv1�TLSv1.1�TLSv1.2�TLSv1.3�HAS_TLSv1_3F� )�InterfaceError�NotSupportedError�OperationalError�ProgrammingError�2 i��� � � )�err�returnc C s | j st| �S | j � d| j� �S )z`Reformat the IOError error message. This function reformats the IOError error message. � )�errno�str�strerror)r � r �J/opt/nydus/tmp/pip-target-o2llkf2b/lib64/python/mysql/connector/network.py�_strioerrorE s r c @ sP e Zd ZdZed ejeeee ee dd�dd��Z eejeed�dd��ZdS ) � NetworkBrokeraP Broker class interface. The network object is a broker used as a delegate by a socket object. Whenever the socket wants to deliver or get packets to or from the MySQL server it needs to rely on its network broker (netbroker). The netbroker sends `payloads` and receives `packets`. A packet is a bytes sequence, it has a header and body (referred to as payload). The first `PACKET_HEADER_LENGTH` or `COMPRESSED_PACKET_HEADER_LENGTH` (as appropriate) bytes correspond to the `header`, the remaining ones represent the `payload`. The maximum payload length allowed to be sent per packet to the server is `MAX_PAYLOAD_LENGTH`. When `send` is called with a payload whose length is greater than `MAX_PAYLOAD_LENGTH` the netbroker breaks it down into packets, so the caller of `send` can provide payloads of arbitrary length. Finally, data received by the netbroker comes directly from the server, expect to get a packet for each call to `recv`. The received packet contains a header and payload, the latter respecting `MAX_PAYLOAD_LENGTH`. N��sock�address�payload� packet_number�compressed_packet_numberr c C s dS )a� Send `payload` to the MySQL server. If provided a payload whose length is greater than `MAX_PAYLOAD_LENGTH`, it is broken down into packets. Args: sock: Object holding the socket connection. address: Socket's location. payload: Packet's body to send. packet_number: Sequence id (packet ID) to attach to the header when sending plain packets. compressed_packet_number: Same as `packet_number` but used when sending compressed packets. Raises: :class:`OperationalError`: If something goes wrong while sending packets to the MySQL server. Nr )�selfr# r$ r% r&