HEX
Server: Apache/2.4.52 (Ubuntu)
System: Linux mail.btech-izolacje.pl 5.15.0-140-generic #150-Ubuntu SMP Sat Apr 12 06:00:09 UTC 2025 x86_64
User: pewna6876 (1017)
PHP: 8.2.28
Disabled: NONE
Upload Files
File: //lib/python3/dist-packages/twisted/runner/__pycache__/inetd.cpython-310.pyc
o

�b��@szdZddlZddlmZmZmZddlmZmZddl	m
Z
e
je
je
j
e
je
jd�ZGdd�de�ZGd	d
�d
e�ZdS)z�
Twisted inetd.

Maintainer: Andrew Bennetts

Future Plans: Bugfixes.  Specifically for UDP and Sun-RPC, which don't work
correctly yet.
�N)�fdesc�process�reactor)�Protocol�
ServerFactory)�wire)�echo�chargen�discard�daytime�timec@seZdZdZdd�ZdS)�
InetdProtocolzDForks a child process on connectionMade, passing the socket as fd 0.cCs�|j��}||d�}|jjr|jj��|d<t�|�d|vr&t�|d�|jj}|j}|j}|t	�
�kr8d}|t	��kr@d}t�
d|j|jt	jdd|||�	t�|j�t�|j�dS)N)r��)�	transport�fileno�factory�
stderrFiler�setBlocking�service�user�group�os�getuid�getgidr�Process�program�programArgs�environr�removeReader�removeWriter)�self�sockFD�childFDsr�uid�gid�r&�6/usr/lib/python3/dist-packages/twisted/runner/inetd.py�connectionMade#s6


�zInetdProtocol.connectionMadeN)�__name__�
__module__�__qualname__�__doc__r(r&r&r&r'r
 sr
c@seZdZeZdZdd�ZdS)�InetdFactoryNcCs
||_dS)N)r)r!rr&r&r'�__init__Os
zInetdFactory.__init__)r)r*r+r
�protocolrr.r&r&r&r'r-Ksr-)r,r�twisted.internetrrr�twisted.internet.protocolrr�twisted.protocolsr�Echo�Chargen�Discard�Daytime�Time�internalProtocolsr
r-r&r&r&r'�<module>s	�	+