AlkantarClanX12

Your IP : 3.137.169.56


Current Path : /proc/self/root/opt/alt/python33/lib64/python3.3/__pycache__/
Upload File :
Current File : //proc/self/root/opt/alt/python33/lib64/python3.3/__pycache__/smtpd.cpython-33.pyc

�
��f�uc!@sRdZddlZddlZddlZddlZddlZddlZddlZddlZddl	Z	ddl
mZddlm
Z
mZddddgZejdZd	ZGd
d�d�Ze�adZd
ZdZdZd
dd�ZGdd�dej�ZGdd�dej�ZGdd�de�ZGdd�de�ZGdd�de�Z Gdd�d�Z!dd�Z"e#dkrNe"�Z$e$j%Z%de%kre%j&d�Z'e(e%de'�e)�e*�d
g�Z+e%e'dd�Z%nddl,Z+e-e+e%�Z.e.e$j/e$j0fe$j1e$j2fe$j3�Z4e$j5r(yddl6Z6Wn2e7k
r�e8dd ej9�ej:d�YnXe6j;d!�d"Z<yej5e<�Wn]e=k
r$Z>z=e>jej?kr��ne8d#d ej9�ej:d�WYddZ>[>XnXnyej@�WneAk
rJYnXndS($uAn RFC 5321 smtp proxy.

Usage: %(program)s [options] [localhost:localport [remotehost:remoteport]]

Options:

    --nosetuid
    -n
        This program generally tries to setuid `nobody', unless this flag is
        set.  The setuid call will fail if this program is not run as root (in
        which case, use this flag).

    --version
    -V
        Print the version number and exit.

    --class classname
    -c classname
        Use `classname' as the concrete SMTP proxy class.  Uses `PureProxy' by
        default.

    --size limit
    -s limit
        Restrict the total size of the incoming message to "limit" number of
        bytes via the RFC 1870 SIZE extension.  Defaults to 33554432 bytes.

    --debug
    -d
        Turn on debugging prints.

    --help
    -h
        Print this message and exit.

Version: %(__version__)s

If localhost is not given then `localhost' is used, and if localport is not
given then 8025 is used.  If remotehost is not given then `localhost' is used,
and if remoteport is not given, then 25 is used.
iN(uwarn(u
get_addr_specuget_angle_addru
SMTPServeruDebuggingServeru	PureProxyuMailmanProxyuPython SMTP proxy version 0.3cBs,|EeZdZdd�Zdd�ZdS(uDevnullcCsdS(N((uselfumsg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuwrite_su
Devnull.writecCsdS(N((uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuflush`su
Devnull.flushN(u__name__u
__module__u__qualname__uwriteuflush(u
__locals__((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuDevnull^suDevnullu
uu, icCsGttt�dtj�|r6t|dtj�ntj|�dS(Nufile(uprintu__doc__uglobalsusysustderruexit(ucodeumsg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuusagejsuusagecBs�|EeZdZdZdZdZejedd��Zej	iedd6�e
ej��Ze
dd	�Zed
d��Zejdd��Zed
d��Zejdd��Zedd��Zejdd��Zedd��Zejdd��Zedd��Zejdd��Zedd��Zejdd��Zedd��Zejdd��Zedd ��Zejd!d ��Zed"d#��Zejd$d#��Zed%d&��Zejd'd&��Zed(d)��Zejd*d)��Zd+d,�Zd-d.�Zd/d0�Zd1d2�Zd3d4�Z d5d6�Z!d7d8�Z"d9d:�Z#d;d<�Z$d=d>�Z%d?d@�Z&dAdB�Z'dCdD�Z(dEdF�Z)dGdH�Z*dIdJ�Z+dKdL�Z,dMS(NuSMTPChanneliiicCs|S(N((ux((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu<lambda>vsuSMTPChannel.<lambda>iuMAILcCs@tjj||�||_||_||_||_g|_|j|_	d|_
d|_g|_
d|_tj�|_d|_y|j�|_WnRtjk
r�}z/|j�|jdtjkr��ndSWYdd}~XnXtdt|j�dt�|jd|jtf�|jd�d|_!dS(NuiuPeer:ufileu	220 %s %ss
F("uasynchatu
async_chatu__init__usmtp_serveruconnuaddrudata_size_limitureceived_linesuCOMMANDu
smtp_stateu
seen_greetinguNoneumailfromurcpttosu
received_datausocketugetfqdnufqdnu	num_bytesugetpeernameupeeruerrorucloseuargsuerrnouENOTCONNuprinturepruDEBUGSTREAMupushu__version__uset_terminatoruFalseu
extended_smtp(uselfuserveruconnuaddrudata_size_limituerr((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__init__|s0										

uSMTPChannel.__init__cCstdtd�|jS(NuTAccess to __server attribute on SMTPChannel is deprecated, use 'smtp_server' insteadi(uwarnuDeprecationWarningusmtp_server(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__server�s
uSMTPChannel.__servercCstdtd�||_dS(NuRSetting __server attribute on SMTPChannel is deprecated, set 'smtp_server' insteadi(uwarnuDeprecationWarningusmtp_server(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__server�s
cCstdtd�|jS(NuUAccess to __line attribute on SMTPChannel is deprecated, use 'received_lines' insteadi(uwarnuDeprecationWarningureceived_lines(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__line�s
uSMTPChannel.__linecCstdtd�||_dS(NuSSetting __line attribute on SMTPChannel is deprecated, set 'received_lines' insteadi(uwarnuDeprecationWarningureceived_lines(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__line�s
cCstdtd�|jS(NuRAccess to __state attribute on SMTPChannel is deprecated, use 'smtp_state' insteadi(uwarnuDeprecationWarningu
smtp_state(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__state�s
uSMTPChannel.__statecCstdtd�||_dS(NuPSetting __state attribute on SMTPChannel is deprecated, set 'smtp_state' insteadi(uwarnuDeprecationWarningu
smtp_state(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__state�s
cCstdtd�|jS(NuXAccess to __greeting attribute on SMTPChannel is deprecated, use 'seen_greeting' insteadi(uwarnuDeprecationWarningu
seen_greeting(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
__greeting�s
uSMTPChannel.__greetingcCstdtd�||_dS(NuVSetting __greeting attribute on SMTPChannel is deprecated, set 'seen_greeting' insteadi(uwarnuDeprecationWarningu
seen_greeting(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
__greeting�s
cCstdtd�|jS(NuSAccess to __mailfrom attribute on SMTPChannel is deprecated, use 'mailfrom' insteadi(uwarnuDeprecationWarningumailfrom(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
__mailfrom�s
uSMTPChannel.__mailfromcCstdtd�||_dS(NuQSetting __mailfrom attribute on SMTPChannel is deprecated, set 'mailfrom' insteadi(uwarnuDeprecationWarningumailfrom(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
__mailfrom�s
cCstdtd�|jS(NuQAccess to __rcpttos attribute on SMTPChannel is deprecated, use 'rcpttos' insteadi(uwarnuDeprecationWarningurcpttos(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	__rcpttos�s
uSMTPChannel.__rcpttoscCstdtd�||_dS(NuOSetting __rcpttos attribute on SMTPChannel is deprecated, set 'rcpttos' insteadi(uwarnuDeprecationWarningurcpttos(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	__rcpttos�s
cCstdtd�|jS(NuTAccess to __data attribute on SMTPChannel is deprecated, use 'received_data' insteadi(uwarnuDeprecationWarningu
received_data(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__data�s
uSMTPChannel.__datacCstdtd�||_dS(NuRSetting __data attribute on SMTPChannel is deprecated, set 'received_data' insteadi(uwarnuDeprecationWarningu
received_data(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__data�s
cCstdtd�|jS(NuKAccess to __fqdn attribute on SMTPChannel is deprecated, use 'fqdn' insteadi(uwarnuDeprecationWarningufqdn(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__fqdn�s
uSMTPChannel.__fqdncCstdtd�||_dS(NuISetting __fqdn attribute on SMTPChannel is deprecated, set 'fqdn' insteadi(uwarnuDeprecationWarningufqdn(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__fqdn�s
cCstdtd�|jS(NuKAccess to __peer attribute on SMTPChannel is deprecated, use 'peer' insteadi(uwarnuDeprecationWarningupeer(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__peer�s
uSMTPChannel.__peercCstdtd�||_dS(NuISetting __peer attribute on SMTPChannel is deprecated, set 'peer' insteadi(uwarnuDeprecationWarningupeer(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__peer�s
cCstdtd�|jS(NuKAccess to __conn attribute on SMTPChannel is deprecated, use 'conn' insteadi(uwarnuDeprecationWarninguconn(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__conn�s
uSMTPChannel.__conncCstdtd�||_dS(NuISetting __conn attribute on SMTPChannel is deprecated, set 'conn' insteadi(uwarnuDeprecationWarninguconn(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__conns
cCstdtd�|jS(NuKAccess to __addr attribute on SMTPChannel is deprecated, use 'addr' insteadi(uwarnuDeprecationWarninguaddr(uself((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__addrs
uSMTPChannel.__addrcCstdtd�||_dS(NuISetting __addr attribute on SMTPChannel is deprecated, set 'addr' insteadi(uwarnuDeprecationWarninguaddr(uselfuvalue((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__addrs
cCs$tjj|t|dd��dS(Nu
uascii(uasynchatu
async_chatupushubytes(uselfumsg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyupushsuSMTPChannel.pushcCs�d}|j|jkr$|j}n|j|jkrB|j}n|r[|j|kr[dS|ry|jt|�7_n|jj	t
|d��dS(Nuutf-8(uNoneu
smtp_stateuCOMMANDumax_command_size_limituDATAudata_size_limitu	num_bytesulenureceived_linesuappendustr(uselfudataulimit((u*/opt/alt/python33/lib64/python3.3/smtpd.pyucollect_incoming_datasu!SMTPChannel.collect_incoming_datacCs�tj|j�}tdt|�dt�g|_|j|jkrQ|jd}|_|sp|j	d�dSd}|jd�}|dkr�|j�}d}n0|d|�j�}||dd�j
�}|jr�|j|n|j}||kr|j	d�dSt|d|d�}|sC|j	d	|�dS||�dS|j|jkr}|j	d
�d|_dS|jr�|j|jkr�|j	d�d|_dSg}xT|jd�D]C}	|	r�|	dd
kr�|j|	dd��q�|j|	�q�Wtj|�|_|jj|j|j|j|j�}
g|_d|_|j|_d|_|jd�|
s�|j	d�n
|j	|
�dS(NuData:ufileiu500 Error: bad syntaxu iu500 Error: line too longusmtp_u&500 Error: command "%s" not recognizedu451 Internal confusionu552 Error: Too much mail datau
u.s
u250 OK(uEMPTYSTRINGujoinureceived_linesuprinturepruDEBUGSTREAMu
smtp_stateuCOMMANDu	num_bytesupushuNoneufinduupperustripu
extended_smtpucommand_size_limitsucommand_size_limitugetattruDATAudata_size_limitusplituappenduNEWLINEu
received_datausmtp_serveruprocess_messageupeerumailfromurcpttosuset_terminator(uselfulineuszumethoduiucommanduargumax_szudatautextustatus((u*/opt/alt/python33/lib64/python3.3/smtpd.pyufound_terminator$sf	
	


	
				
uSMTPChannel.found_terminatorcCsZ|s|jd�dS|jr0|jd�n&||_d|_|jd|j�dS(Nu501 Syntax: HELO hostnameu503 Duplicate HELO/EHLOu250 %sF(upushu
seen_greetinguFalseu
extended_smtpufqdn(uselfuarg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_HELOas
			uSMTPChannel.smtp_HELOcCs�|s|jd�dS|jr0|jd�nS||_d|_|jd|j�|jrv|jd|j�n|jd�dS(Nu501 Syntax: EHLO hostnameu503 Duplicate HELO/EHLOu250-%su250-SIZE %su250 HELPT(upushu
seen_greetinguTrueu
extended_smtpufqdnudata_size_limit(uselfuarg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_EHLOls
				uSMTPChannel.smtp_EHLOcCs'|r|jd�n
|jd�dS(Nu501 Syntax: NOOPu250 OK(upush(uselfuarg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_NOOPzsuSMTPChannel.smtp_NOOPcCs|jd�|j�dS(Nu221 Bye(upushuclose_when_done(uselfuarg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_QUIT�s
uSMTPChannel.smtp_QUITcCs@t|�}|d|�j�|kr<||d�j�SdS(Nu(ulenuupperustrip(uselfukeyworduargukeylen((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu_strip_command_keyword�su"SMTPChannel._strip_command_keywordcCsc|s
dS|j�jd�r4t|�\}}nt|�\}}|sV||fS|j|fS(Nuu<(uu(ulstripu
startswithuget_angle_addru
get_addr_specu	addr_spec(uselfuarguaddressurest((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu_getaddr�s
uSMTPChannel._getaddrcCs*dd�|j�D�}dd�|D�S(NcSs.g|]$}d|kr|jdd��qS(u=i(usplit(u.0uparam((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
<listcomp>�s	u*SMTPChannel._getparams.<locals>.<listcomp>cSs+i|]!\}}|j�r||�qS((uisalnum(u.0ukuv((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
<dictcomp>�s	u*SMTPChannel._getparams.<locals>.<dictcomp>(usplit(uselfuparams((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
_getparams�suSMTPChannel._getparamscCsm|r\d}|j�}|dkr4|jd�qi|dkrP|jd�qi|dkr�d}|jrx||7}n|j|�qi|dkr�d	}|jr�||7}n|j|�qi|d
kr�|jd�qi|dkr�|jd
�qi|dkr|jd�qi|dkr0|jd�qi|dkrL|jd�qi|jd�n
|jd�dS(Nu [SP <mail parameters]uEHLOu250 Syntax: EHLO hostnameuHELOu250 Syntax: HELO hostnameuMAILu 250 Syntax: MAIL FROM: <address>uRCPTu250 Syntax: RCPT TO: <address>uDATAu250 Syntax: DATAuRSETu250 Syntax: RSETuNOOPu250 Syntax: NOOPuQUITu250 Syntax: QUITuVRFYu250 Syntax: VRFY <address>uD501 Supported commands: EHLO HELO MAIL RCPT DATA RSET NOOP QUIT VRFYuD250 Supported commands: EHLO HELO MAIL RCPT DATA RSET NOOP QUIT VRFY(uupperupushu
extended_smtp(uselfuarguextendedulc_argumsg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_HELP�s:	
	
uSMTPChannel.smtp_HELPcCsV|rE|j|�\}}|r1|jd�qR|jd|�n
|jd�dS(NuB252 Cannot VRFY user, but will accept message and attempt deliveryu502 Could not VRFY %su501 Syntax: VRFY <address>(u_getaddrupush(uselfuarguaddressuparams((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_VRFY�suSMTPChannel.smtp_VRFYcCs�|js|jd�dStd|dt�d}|jrI|d7}n|dkrf|j|�dS|jd|�}|j|�\}}|s�|j|�dS|jr�|r�|j|�dS|s�|j|�dS|jr�|jd�dS|j	|j
��}|dkr(|j|�dS|jdd�}|r�|j�s]|j|�dS|j
r�t|�|j
kr�|jd	�dSnt|j��d
kr�|jd�dS||_td|jdt�|jd
�dS(Nu503 Error: send HELO firstu	===> MAILufileu 501 Syntax: MAIL FROM: <address>u [SP <mail-parameters>]uFROM:u503 Error: nested MAIL commanduSIZEu:552 Error: message size exceeds fixed maximum message sizeiu:555 MAIL FROM parameters not recognized or not implementedusender:u250 OK(u
seen_greetingupushuprintuDEBUGSTREAMu
extended_smtpuNoneu_strip_command_keywordu_getaddrumailfromu
_getparamsuupperupopuisdigitudata_size_limituintulenukeys(uselfuargu	syntaxerruaddressuparamsusize((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_MAIL�sT	
	




	




	uSMTPChannel.smtp_MAILcCs�|js|jd�dStd|dt�|jsG|jd�dSd}|jrc|d7}n|dkr�|j|�dS|jd|�}|j|�\}}|s�|j|�dS|r|jr|j	|j
��}|dkr|j|�dSq|j|�dSn|s-|j|�dS|r\t|j��dkr\|jd	�dS|ss|jd�dS|j
j|�td
|j
dt�|jd�dS(Nu503 Error: send HELO firstu	===> RCPTufileu503 Error: need MAIL commandu501 Syntax: RCPT TO: <address>u [SP <mail-parameters>]uTO:iu8555 RCPT TO parameters not recognized or not implementedurecips:u250 OK(u
seen_greetingupushuprintuDEBUGSTREAMumailfromu
extended_smtpuNoneu_strip_command_keywordu_getaddru
_getparamsuupperulenukeysurcpttosuappend(uselfuargu	syntaxerruaddressuparams((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_RCPT�sL	
	
	


	




uSMTPChannel.smtp_RCPTcCsO|r|jd�dSd|_g|_d|_|j|_|jd�dS(Nu501 Syntax: RSETuu250 OK(upushuNoneumailfromurcpttosu
received_datauCOMMANDu
smtp_state(uselfuarg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_RSET s
			uSMTPChannel.smtp_RSETcCsu|js|jd�dS|js4|jd�dS|rK|jd�dS|j|_|jd�|jd�dS(Nu503 Error: send HELO firstu503 Error: need RCPT commandu501 Syntax: DATAs
.
u#354 End data with <CR><LF>.<CR><LF>(u
seen_greetingupushurcpttosuDATAu
smtp_stateuset_terminator(uselfuarg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_DATA+s	
	


uSMTPChannel.smtp_DATAcCs|jd�dS(Nu502 EXPN not implemented(upush(uselfuarg((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	smtp_EXPN:suSMTPChannel.smtp_EXPNN(-u__name__u
__module__u__qualname__uCOMMANDuDATAucommand_size_limitucollectionsudefaultdictucommand_size_limitsuupdateumaxuvaluesumax_command_size_limituDATA_SIZE_DEFAULTu__init__upropertyu_SMTPChannel__serverusetteru_SMTPChannel__lineu_SMTPChannel__stateu_SMTPChannel__greetingu_SMTPChannel__mailfromu_SMTPChannel__rcpttosu_SMTPChannel__datau_SMTPChannel__fqdnu_SMTPChannel__peeru_SMTPChannel__connu_SMTPChannel__addrupushucollect_incoming_dataufound_terminatoru	smtp_HELOu	smtp_EHLOu	smtp_NOOPu	smtp_QUITu_strip_command_keywordu_getaddru
_getparamsu	smtp_HELPu	smtp_VRFYu	smtp_MAILu	smtp_RCPTu	smtp_RSETu	smtp_DATAu	smtp_EXPN(u
__locals__((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuSMTPChannelqs^	
=#,)uSMTPChannelcBsA|EeZdZeZedd�Zdd�Zdd�ZdS(u
SMTPServercCs�||_||_||_tjj|�y>|jtjtj	�|j
�|j|�|jd�Wn|j
��Yn6Xtd|jjtjtj��||fdt�dS(Niu0%s started at %s
	Local addr: %s
	Remote addr:%sufile(u
_localaddru_remoteaddrudata_size_limituasyncoreu
dispatcheru__init__u
create_socketusocketuAF_INETuSOCK_STREAMuset_reuse_addrubindulistenucloseuprintu	__class__u__name__utimeuctimeuDEBUGSTREAM(uselfu	localaddru
remoteaddrudata_size_limit((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu__init__Bs			


uSMTPServer.__init__cCs9tdt|�dt�|j||||j�}dS(NuIncoming connection from %sufile(uprinturepruDEBUGSTREAMu
channel_classudata_size_limit(uselfuconnuaddruchannel((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuhandle_acceptedVsuSMTPServer.handle_acceptedcCs
t�dS(uIOverride this abstract method to handle messages from the client.

        peer is a tuple containing (ipaddr, port) of the client that made the
        socket connection to our smtp port.

        mailfrom is the raw address the client claims the message is coming
        from.

        rcpttos is a list of raw addresses the client wishes to deliver the
        message to.

        data is a string containing the entire full text of the message,
        headers (if supplied) and all.  It has been `de-transparencied'
        according to RFC 821, Section 4.5.2.  In other words, a line
        containing a `.' followed by other text has had the leading dot
        removed.

        This function should return None, for a normal `250 Ok' response;
        otherwise it returns the desired response string in RFC 821 format.

        N(uNotImplementedError(uselfupeerumailfromurcpttosudata((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuprocess_message[suSMTPServer.process_messageN(	u__name__u
__module__u__qualname__uSMTPChannelu
channel_classuDATA_SIZE_DEFAULTu__init__uhandle_accepteduprocess_message(u
__locals__((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu
SMTPServer>scBs |EeZdZdd�ZdS(uDebuggingServercCsod}|jd�}td�x?|D]7}|rS|rStd|d�d}nt|�q&Wtd�dS(Niu
u%---------- MESSAGE FOLLOWS ----------uX-Peer:iu%------------ END MESSAGE ------------(usplituprint(uselfupeerumailfromurcpttosudatau	inheadersulinesuline((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuprocess_messagevs


	uDebuggingServer.process_messageN(u__name__u
__module__u__qualname__uprocess_message(u
__locals__((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuDebuggingServertscBs,|EeZdZdd�Zdd�ZdS(u	PureProxyc	Cs�|jd�}d}x"|D]}|s,Pn|d7}qW|j|d|d�tj|�}|j|||�}td|dt�dS(Nu
iiu
X-Peer: %suwe got some refusals:ufile(usplituinsertuNEWLINEujoinu_deliveruprintuDEBUGSTREAM(	uselfupeerumailfromurcpttosudataulinesuiulineurefused((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuprocess_message�s
uPureProxy.process_messagecCs:ddl}i}yU|j�}|j|jd|jd�z|j|||�}Wd|j�XWn�|jk
r�}ztddt�|j	}WYdd}~Xn�t
j|jfk
r5}z`td|j
dt�t|dd	�}t|dd�}	x|D]}
||	f||
<q	WWYdd}~XnX|S(
Niiugot SMTPRecipientsRefusedufileugotu	smtp_codeu
smtp_erroruignorei����(usmtplibuSMTPuconnectu_remoteaddrusendmailuquituSMTPRecipientsRefuseduprintuDEBUGSTREAMu
recipientsusocketuerroru
SMTPExceptionu	__class__ugetattr(uselfumailfromurcpttosudatausmtpliburefusedusueuerrcodeuerrmsgur((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu_deliver�s$
'uPureProxy._deliverN(u__name__u
__module__u__qualname__uprocess_messageu_deliver(u
__locals__((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	PureProxy�scBs |EeZdZdd�ZdS(uMailmanProxyc	Csddlm}ddlm}ddlm}ddlm}g}	x�|D]�}
|
j�jd�d}|jd�}t|�dkr�qMn|d}
t|�dkr�|d	}nd
}|j	|
�sM|d!kr�qMn|	j
|
|
|f�qMWx$|	D]\}
}
}|j|
�qWtddj
|�dt�|rr|j|||�}td|dt�ni}||�}|j|�}|jd�s�||d<n|jd�s�tjtj��|d<nx.|	D]&\}
}
}td|
dt�|j|
�}|s:|j|
dd�}|||
<n|d
kr\|j|dd	�q�|dkr~|j|dd	�q�|dkr�|j|dd	�q�|d
kr�|j|dd	�q�|d"kr�|dkr�d|d<n
d |d<|j|dd	�q�q�WdS(#Ni(uStringIO(uUtils(uMessage(uMailListu@u-iiuuadminuownerurequestujoinuleaveuforwarding recips:u ufileuwe got refusals:ufromuFromudateuDateusending message toulockutolistutoadminutoowneru	torequestu	subscribeuSubjectuunsubscribe(uuadminuownerurequestujoinuleave(ujoinuleave(uiouStringIOuMailmanuUtilsuMessageuMailListulowerusplitulenulist_existsuappenduremoveuprintujoinuDEBUGSTREAMu_deliverugetutimeuctimeuEnqueue(uselfupeerumailfromurcpttosudatauStringIOuUtilsuMessageuMailListu	listnamesurcptulocalupartsulistnameucommandurefusedumlistsusumsgumlist((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuprocess_message�sd


	



uMailmanProxy.process_messageN(u__name__u
__module__u__qualname__uprocess_message(u
__locals__((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuMailmanProxy�scBs&|EeZdZdZdZdZdS(uOptionsiu	PureProxyN(u__name__u
__module__u__qualname__usetuidu	classnameuNoneu
size_limit(u
__locals__((u*/opt/alt/python33/lib64/python3.3/smtpd.pyuOptions�suOptionsc
!Csy>tjtjdd�dddddddg�\}}Wn5tjk
ru}ztd|�WYdd}~XnXt�}x�|D]�\}}|d"kr�td�q�|d#kr�ttdtj�tj	d�q�|d$kr�d|_
q�|d%kr
||_q�|d&kr"tjaq�|d'kr�yt
|�}||_Wqytd|dtj�tj	d�YqyXq�q�Wt|�dkr�d}d}nht|�dkr�|d}d}nCt|�dkr�|d}|d}ntddtj|��|jd�}	|	dkr5tdd|�n|d|	�|_y!t
||	dd��|_Wn#tk
r�tdd|�YnX|jd�}	|	dkr�tdd |�n|d|	�|_y!t
||	dd��|_Wn#tk
rtdd!|�YnX|S((NiunVhc:s:duclass=unosetuiduversionuhelpusize=udebugu-hu--helpiu-Vu	--versionufileu-nu
--nosetuidu-cu--classu-du--debugu-su--sizeuInvalid size: ulocalhost:8025ulocalhost:25iiuInvalid arguments: %su:uBad local spec: %suBad local port: %suBad remote spec: %suBad remote port: %s(u-hu--help(u-Vu	--version(u-nu
--nosetuid(u-cu--class(u-du--debug(u-su--size(ugetoptusysuargvuerroruusageuOptionsuprintu__version__ustderruexitusetuidu	classnameuDEBUGSTREAMuintu
size_limitulenu
COMMASPACEujoinufindu	localhostu	localportu
ValueErroru
remotehostu
remoteport(
uoptsuargsueuoptionsuoptuarguint_sizeu	localspecu
remotespecui((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu	parseargs�sj% 	

	
	

!
!
u	parseargsu__main__u.iu7Cannot import module "pwd"; try running with -n option.ufileunobodyiu3Cannot setuid "nobody"; try running with -n option.(Bu__doc__usysuosuerrnougetoptutimeusocketuasyncoreuasynchatucollectionsuwarningsuwarnuemail._header_value_parseru
get_addr_specuget_angle_addru__all__uargvuprogramu__version__uDevnulluDEBUGSTREAMuNEWLINEuEMPTYSTRINGu
COMMASPACEuDATA_SIZE_DEFAULTuusageu
async_chatuSMTPChannelu
dispatcheru
SMTPServeruDebuggingServeru	PureProxyuMailmanProxyuOptionsu	parseargsu__name__uoptionsu	classnameurfindulastdotu
__import__uglobalsulocalsumodu__main__ugetattruclass_u	localhostu	localportu
remotehostu
remoteportu
size_limituproxyusetuidupwduImportErroruprintustderruexitugetpwnamunobodyuOSErrorueuEPERMuloopuKeyboardInterrupt(((u*/opt/alt/python33/lib64/python3.3/smtpd.pyu<module>)sv#
	��6(N?		(	
#