403Webshell
Server IP : 121.121.20.254  /  Your IP : 216.73.216.202
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/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : C:/Python315/Lib/__pycache__/mailbox.cpython-315.opt-1.pyc
R
>lqj�Gc��Qs]PHs]PHs]PHs]PHs]PHs]PHs]PHs]PH s]PH$s]PH(s]PH,s]PH0s]QH4Gs]PH>s,Q5Ns\O$O'Q2sQQ2sQQ\2sQQ\2sQQ\2sQQ\2sQQ\2sQQ\2sQQ\2sQQ\O8O:2sQQ	\2sQ Q!\2sQ"Q
\2s Q#Q\2s!Q$Q\2s"Q%Q
\2s#Q&Q'2s$Q(Q)\$2s%Q6Q*ks&Q+s'Q,s(Q-s)Q.s*Q/s+Q0Q\,2s-Q1Q\-2s.Q2Q\-2s/Q3Q\-2s0Q4Q\-2s1P!\cPsCKEh9h)7zDRead/write support for Maildir, mbox, MH, Babyl, and MMDF mailboxes.)�GenericAlias�Mailbox�Maildir�mbox�MH�Babyl�MMDF�Message�MaildirMessage�mboxMessage�	MHMessage�BabylMessage�MMDFMessage�Error�NoSuchMailboxError�
NotEmptyError�ExternalClashError�FormatError�asciic�`�\sQs]"snQsQ$QksQsQsQsQs	Qs
QsQ	sQ%Q
ks
QsQsQ
sQsQsQsQsQsQsQsQsQsQsQsQsQ%QksQsQ%QksQs Qs!Qs"Q s#Q!s$P
s%Q&Q"ks&\'\(2s)Q#s*Us+P!)'rz*A group of messages in a particular place.c��[OO[OOU22UmV mP!)zInitialize a Mailbox instance.)�os�path�abspath�
expanduser�_path�_factory��selfr�factory�creates&&&&�C:\Python315\\Lib\mailbox.py�__init__�Mailbox.__init__%s*���W�W�_�_�R�W�W�%7�%7��%=�>��
��
�c�(�UO2U!�N)�lock�rs&r �	__enter__�Mailbox.__enter__*s���	�	���r#c�(�UO2P!r%��close)r�type�value�	tracebacks&&&&r �__exit__�Mailbox.__exit__.����
�
�r#c��[Q2g)�$Add message and return assigned key.�&Method must be implemented by subclass��NotImplementedError�r�messages&&r �add�Mailbox.add1���!�"J�K�Kr#c��[Q2g)�=Remove the keyed message; raise KeyError if it doesn't exist.r5r6�r�keys&&r �remove�Mailbox.remove5r<r#c�*�UOU2P!r%)rAr?s&&r �__delitem__�Mailbox.__delitem__9s�����C�r#c�P�UOU2P![cP!h9h�z'If the keyed message exists, remove it.)rA�KeyErrorr?s&&r �discard�Mailbox.discard<s%��	��K�K�����	��	�s��	%�%�%c��[Q2g)�>Replace the keyed message; raise KeyError if it doesn't exist.r5r6�rr@r9s&&&r �__setitem__�Mailbox.__setitem__Cr<r#c�N�UOU2![cSt!h9h)z9Return the keyed message, or default if it doesn't exist.)�__getitem__rH)rr@�defaults&&&r �get�Mailbox.getGs,��	��#�#�C�(�(���	��N�	�s��	$�$�$c��UO%fUOU2![OUO	U229^tt^2oUOU2ttPPP2!)%fhP!9h)z=Return the keyed message; raise KeyError if it doesn't exist.)r�get_message�
contextlib�closing�get_file)rr@�files&& r rQ�Mailbox.__getitem__NsS���}�}�}��#�#�C�(�(��#�#�D�M�M�#�$6�7�7�4��}�}�T�*�8�7�7�7�s�A.�.A?	�7A?	c��[Q2g)�4Return a Message representation or raise a KeyError.r5r6r?s&&r rV�Mailbox.get_messageVr<r#c�j�[OUOU22O2!)z�Return a string representation or raise a KeyError.

Uses email.message.Message to create a 7bit clean string
representation of the message.��email�message_from_bytes�	get_bytes�	as_stringr?s&&r �
get_string�Mailbox.get_stringZs'��
�'�'����s�(;�<�F�F�H�Hr#c��[Q2g)z8Return a byte string representation or raise a KeyError.r5r6r?s&&r rc�Mailbox.get_bytesar<r#c��[Q2g)�6Return a file-like representation or raise a KeyError.r5r6r?s&&r rY�Mailbox.get_fileer<r#c��[Q2g)�Return an iterator over keys.r5r6r's&r �iterkeys�Mailbox.iterkeysir<r#c�6�[UO22!)zReturn a list of keys.)�listrnr's&r �keys�Mailbox.keysms���D�M�M�O�$�$r#c#� �UO2FDoV*oUw�	J	P![cJ%h9h3h)z%Return an iterator over all messages.�rnrH�rr@r.s&  r �
itervalues�Mailbox.itervaluesqs;����=�=�?�C�
��	���K�#���
��
�s �>�,�>�	;�;�>�;�>c�$�UO2!r%)rwr's&r �__iter__�Mailbox.__iter__zs����� � r#c�6�[UO22!)z,Return a list of messages. Memory intensive.)rqrwr's&r �values�Mailbox.values}s���D�O�O�%�&�&r#c#� �UO2FDoV*oV1w�	J	P![cJ&h9h3h)z.Return an iterator over (key, message) tuples.rurvs&  r �	iteritems�Mailbox.iteritems�s>����=�=�?�C�
��	���,��#���
��
�s �?�-�?�	<�<�?�<�?c�6�[UO22!)z9Return a list of (key, message) tuples. Memory intensive.)rqr�r's&r �items�
Mailbox.items�s���D�N�N�$�%�%r#c��[Q2g)�9Return True if the keyed message exists, False otherwise.r5r6r?s&&r �__contains__�Mailbox.__contains__�r<r#c��[Q2g)�*Return a count of messages in the mailbox.r5r6r's&r �__len__�Mailbox.__len__�r<r#c�Z�UO2FDoUOU2J	P!)zDelete all messages.)rrrIr?s& r �clear�
Mailbox.clear�s���9�9�;�C��L�L���r#c�b�V*oUOU2U![cSt!h9h)z3Delete the keyed message and return it, or default.)rHrI)rr@rR�results&&& r �pop�Mailbox.pop�s7��	��Y�F�	
���S���
���	��N�	�s��	.�.�.c�p�UO2FDoVOU21t!	[Q2g)z6Delete an arbitrary (key, message) pair and return it.zNo messages in mailbox)rnr�rHr?s& r �popitem�Mailbox.popitem�s1���=�=�?�C����#��'�'�#��3�4�4r#c��[UQ2%cUO2oL%[UQ2%cUO2oLSoP
oSFD
vqEVPU$J	U%c[Q2gP![cP	oJ3h9h)z4Change the messages that correspond to certain keys.r�r�zNo message with key(s))�hasattrr�r�rH)r�arg�source�bad_keyr@r9s&&    r �update�Mailbox.update�s����3��$�$��]�]�_�F�
�S�'�
"�
"��Y�Y�[�F��F���"�L�C�
�#�S�	�#�
��3�4�4����
���
�s�A2�2	B�<B�Bc��[Q2g)�&Write any pending changes to the disk.r5r6r's&r �flush�
Mailbox.flush�r<r#c��[Q2g)�Lock the mailbox.r5r6r's&r r&�Mailbox.lock�r<r#c��[Q2g)�#Unlock the mailbox if it is locked.r5r6r's&r �unlock�Mailbox.unlock�r<r#c��[Q2g)�Flush and close the mailbox.r5r6r's&r r,�
Mailbox.close�r<r#c�\�UOQ2![c
[Q2gh9h)rz?String input must be ASCII-only; use bytes or a Message instead)�encode�UnicodeError�
ValueErrorr8s&&r �_string_to_bytes�Mailbox._string_to_bytes�s7��	2��>�>�'�*�*���	2��1�2�
2�	2�s��	+�
+c�@�[U[OO2%c�[O
2o[OOVC]2oUOU2UO]2UO2oUOQ[2oUOU2UO%c5UO[2%fUO[2P!P!P![U[ ["[O$12%c�[U[O$2%c-[&O(Q[*]2UO-2o[U[ 2%cUO/U2oU%cUOQQ2oUOQ[2oUOU2UO%c5UO[2%fUO[2P!P!P![1UQ2%CcJ[1UQ2%c)[&O(Q[*]2UO2oPoUO52oUOQ2%cUPQQ*oL#UOQ	2%c
UPPQ*oU%fLZU%c(UO7Q
2%cQUQ**oUOQ[2oUOU2SoJ�UO%c?U%c5UO[2%fUO[2P!P!P!P![9Q
[;U2*2g)z%Dump message contents to target file.�
�8Use of StringIO input is deprecated, use BytesIO insteads
From s
>From �read�buffer�DUse of text mode files is deprecated, use a binary mode file instead�
�
�From s>From ��NN�Invalid message type: %s���)�
isinstancerar9r�io�BytesIO�	generator�BytesGenerator�flatten�seekr��replace�linesep�write�_append_newline�endswith�str�bytes�StringIO�warnings�warn�DeprecationWarning�getvaluer�r�r��readline�
startswith�	TypeErrorr-)	rr9�target�mangle_from_r��gen�data�lastline�lines	&&&&     r �
_dump_message�Mailbox._dump_message�s����g�u�}�}�4�4�5�5��Z�Z�\�F��/�/�0�0��q�I�C��K�K�� ��K�K��N��;�;�=�D��<�<��w�/�D��L�L����#�#�#�D�M�M�'�,B�,B����W�%�-C�#���#�u�b�k�k�!:�
;�
;��'�2�;�;�/�/��
�
�*�+=�q�B�!�*�*�,���'�3�'�'��/�/��8���!�/�/�*�k�B���o�o�e�W�5�G��L�L��!��#�#�#�G�,<�,<�W�,E�,E����W�%�-F�#��W�f�
%�
%��w��)�)��
�
�5�6H�!�M�!�.�.���H���'�'�)���=�=��)�)����9�u�,�D��]�]�5�)�)����9�u�,�D����D�O�O�H�$=�$=�$�t�B�x�/�D��|�|�E�7�3�����T�"����#�#�#���9J�9J�7�9S�9S����W�%�:T��#��6��g��F�G�Gr#)rr�NTr%�F),�__name__�
__module__�__qualname__�__firstlineno__�__doc__r!r(r0r:rArDrIrNrSrQrVrercrYrnrrrwrzr}r�r�r�r�r�r�r�r�r�r&r�r,r�r�r��classmethodr�__class_getitem__�__static_attributes__�__classdictcell__��
__classdict__s@r rr"s�����4� �
��L�L���L��+�L�I�L�L�L�%��!�'��&�L�L��
�5�5�"L�L�L�L�2��O�4H�l$�L�1�r#c�`�\sQsQsnQsQsQ'QksQsQsQs	Qs
Q	sQ
sQs
QsU1Q
kQksQsU1QkQksU1QkQksU1QkQksQsQsQsQsQsQsQsQsQsQsQ sQ!s]s Q"s!Q#s"Q$s#Q%s$Q&s%Us&P!)(r�zA qmail-style Maildir mailbox.�:c	���[OVV#2Q[OO	UO
Q2Q[OO	UO
Q2Q[OO	UO
Q2-Um[OOUO
2%fyU%c\[OUO
Q2UOO2FDo[OUQ2J	L[UO
2g-UmQ]Q]-Um]Um
QUmP!)zInitialize a Maildir instance.�tmp�new�cur�g�������?)rr!rr�joinr�_paths�exists�mkdirr}r�_toc�_toc_mtimes�
_last_read�_skewfactor)r�dirnamerrrs&&&& r r!�Maildir.__init__s��������8��2�7�7�<�<��
�
�E�2��2�7�7�<�<��
�
�E�2��2�7�7�<�<��
�
�E�2����
�w�w�~�~�d�j�j�)�)��������U�+� �K�K�.�.�0�D��H�H�T�5�)�1�)����4�4���	�!�1�e�Q�/��������r#c�0�UO2oUOV2[U2[U[2%cEUO2oUOUO2*oV@O6XcPoLQoPo[OOUO2OUO2]*o[OO!UO"V5U*2o[U[2%cY[O$UO[OO'UO2UO)212[O*UOU2[O
UO2U![c3SO2[O
SO2gh9h[,[.1c&[O0SOS2S!h9h[2cXo[O
SO2SO4[4O66Xc[9QS*2ggPo=hh9h)r4r�z$Name clash with existing message: %s)�_create_tmpr��
BaseExceptionr,rrA�name�_sync_closer�r	�
get_subdir�colon�get_infor�basename�splitr�r�utime�getatime�get_date�link�AttributeError�PermissionError�rename�OSError�errno�EEXISTr)rr9�tmp_file�subdir�suffix�uniq�dest�es&&      r r:�Maildir.add+s����#�#�%��	����w�1�
	�H���g�~�.�.��'�'�)�F��Z�Z�'�"2�"2�"4�4�F����#�����F��F��w�w����
�
�.�4�4�T�Z�Z�@��C���w�w�|�|�D�J�J��v�
�>���g�~�.�.��H�H�X�]�]��g�g�&�&�x�}�}�5�w�7G�7G�7I�J�
L�

	�
)�����
�
�t�,��	�	�(�-�-�(����G�	��N�N���I�I�h�m�m�$��	��0#�O�4�
/��	�	�(�-�-��.���
/���	��I�I�h�m�m�$��w�w�%�,�,�&�(�)O�+/�*0�1�1���
	�sY�F:�7!G:� H3�:	G7�3G7�:H0�
"H0�,H3�/H0�0H3�3	J�=J�>>J�=J�Jc��[O[OOUOUOU222P!�r>)rrArr�r�_lookupr?s&&r rA�Maildir.removeUs*��
�	�	�"�'�'�,�,�t�z�z�4�<�<��+<�=�>r#c�\�UOU2P![[1cP!h9hrG)rArH�FileNotFoundErrorr?s&&r rI�Maildir.discardYs+��	��K�K�����+�,�	��	�s��+�+�+c�(�UOU2oUOU2oUOU2o[U[2%cSoLSo[O
O
U2oUOU7c5UOUOUO2P**oLPoUOU2[O
OUOU2o	[O
OUOVqU*2o
[U[2%cE[OU	[O
OU	2UO212[OV�2P!�rL)rr:r�r	rrr�rrrIr�rrrrr)rr@r9�old_subpath�temp_key�temp_subpath�dominant_subpathrr�tmp_path�new_paths&&&        r rN�Maildir.__setitem__as���l�l�3�'���8�8�G�$���|�|�H�-���g�~�.�.�+�� +�������!1�2���:�:�)�)��Z�Z�"2�"8�"8����"D�R�"H�H�F��F����S���7�7�<�<��
�
�L�9���7�7�<�<��
�
�F�&�L�A���g�~�.�.��H�H�X��g�g�&�&�x�0�'�2B�2B�2D�E�
G�
	�	�	�(�%r#c���UOU2o[[OO	UO
U2Q29^tt^2oUO%cUO
U2oL[U2oPPP2[OOU2vqVWOU2UOU7c2UOUOUO2P*2UO[OO[OO	UO
U222U!)%fhK�9h)r]�rb)r�openrrr�rrr	r�
set_subdirr�set_info�set_date�getmtime)rr@�subpath�f�msgrr�s&&     r rV�Maildir.get_message|s����,�,�s�#��
�"�'�'�,�,�t�z�z�7�3�T�
:�
:�a��}�}�}��m�m�A�&��$�Q�'��	;�
�w�w�}�}�W�-������v���:�:����L�L����D�J�J�/��3�4����R�W�W�%�%�b�g�g�l�l�4�:�:�w�&G�H�I��
�;�
:�s�E�"E�E#	�E#	c� �[[OOUOUOU22Q29^tt^2oUO
2O[Q2ttPPP2!)%fhP!9h)�2Return a bytes representation or raise a KeyError.r(r�)	r)rrr�rrr�r�r��rr@r/s&& r rc�Maildir.get_bytes�sS��
�"�'�'�,�,�t�z�z�4�<�<��+<�=�t�
D�
D���6�6�8�#�#�G�U�3�E�
D�
D�
D�s�
$A<�<B
	�B
	c��[[OOUOUOU22Q2o[
U2!)rjr()r)rrr�rr�
_ProxyFiler4s&& r rY�Maildir.get_file�s4��������d�j�j�$�,�,�s�*;�<�d�C���!�}�r#c��UOU2oUOU7c#UOUO2P*!P!)z+Get the keyed message's "info" as a string.)rrr)rr@r.s&& r r�Maildir.get_info�s7���,�,�s�#���:�:�� ��=�=����,�R�0�0�r#c�":�U]6�cPgQRZ-!)��info�r�)�formatr�s"�r �__annotate__�Maildir.set_info.__annotate__�s���
%�
%�#�
%r#c�
�[U[2%f[Q[U202gUO	U2oUOUO2]*oU%cV@OU**
oVC6XcP![OOUOU2o[OOUOU2o[OVV2V@OU$P!)z&Set the keyed message's "info" string.zinfo must be a string: )
r�r�r�r-rrrrrr�rrr�)rr@r=r �new_subpath�old_pathr%s&&&    r r+�Maildir.set_info�s����$��$�$��5�d�4�j�\�B�C�C��l�l�3�'��!�'�'��
�
�3�A�6����:�:��,�,�K��%���7�7�<�<��
�
�K�8���7�7�<�<��
�
�K�8��
�	�	�(�%�$�	�	�#�r#c�j�UOU2oUOQ2%c
UQ*!P!)zHReturn as a string the standard flags that are set on the keyed message.�2,�r<NN)rr�)rr@r=s&& r �	get_flags�Maildir.get_flags�s+���}�}�S�!���?�?�4� � ���8�O�r#c�":�U]6�cPgQRZ-!)r<�flagsr>)r?r�s"�r r@�Maildir.set_flags.__annotate__�s���?�?�C�?r#c���[U[2%f[Q[U202gUO	UQPO[
[U222*2P!)z>Set the given flags and unset all others on the keyed message.zflags must be a string: rG)r�r�r�r-r+r��sorted�set)rr@rLs&&&r �	set_flags�Maildir.set_flags�sK���%��%�%��6�t�E�{�m�D�E�E��
�
�c�4�"�'�'�&��U��*<�"=�=�>r#c�":�U]6�cPgQRZ-!�r<�flagr>)r?r�s"�r r@�Maildir.add_flag.__annotate__�s���K�K�#�Kr#c
���[U[2%f[Q[U202gUO	UPO[
UOU22[
U2*22P!)zCSet the given flag(s) without changing others on the keyed message.�flag must be a string: )r�r�r�r-rQr�rPrI�rr@rUs&&&r �add_flag�Maildir.add_flag�sT���$��$�$��5�d�4�j�\�B�C�C����s�B�G�G�C����s�(;�$<�s�4�y�$H�I�Jr#c�":�U]6�cPgQRZ-!rTr>)r?r�s"�r r@� Maildir.remove_flag.__annotate__�s���O�O�S�Or#c
�&�[U[2%f[Q[U202gUO	U2%cLUOUPO
[UO	U22[U2*
22P!P!)zLUnset the given string flag(s) without changing others on the keyed message.rX)r�r�r�r-rIrQr�rPrYs&&&r �remove_flag�Maildir.remove_flag�sh���$��$�$��5�d�4�j�\�B�C�C��>�>�#����N�N�3�����D�N�N�3�,?�(@�3�t�9�(L� M�N�r#c#� �UO2UOFDoUOU2Uw�	J	P![cJ.h9h3h�rm)�_refreshr�rrHr?s& r rn�Maildir.iterkeys�sG����
�
���9�9�C�
����S�!��I����
��
�s-�"A�A�A�	A�A�A�A�Ac�@�UO2VO7!�r�)rcr�r?s&&r r��Maildir.__contains__�s���
�
���i�i��r#c�N�UO2[UO2!�r�)rc�lenr�r's&r r��Maildir.__len__�s���
�
���4�9�9�~�r#c��P!)�"Write any pending changes to disk.�r's&r r��
Maildir.flush�s��	
r#c��P!�r�rnr's&r r&�Maildir.lock����r#c��P!�r�rnr's&r r��Maildir.unlock�rsr#c��P!�r�rnr's&r r,�
Maildir.close�rsr#c�n�,o[OUO2FD�o[U2]6�fJU]*Q6XfJ%[OO[OO
UOU22%fJtUOUQ*2J�	U!)�Return a list of folder names.�.��NN)r�listdirrrjr�isdirr��append�rr��entrys&  r �list_folders�Maildir.list_folders�sp�����Z�Z��
�
�+�E��5�z�A�~�%��(�c�/��w�w�}�}�R�W�W�\�\�$�*�*�e�<�=�=��
�
�e�B�i�(�,��
r#c��[[OOUOQU*2UO
P
Q5!)z/Return a Maildir instance for the named folder.r|�rr)rrrr�rr�r�folders&&r �
get_folder�Maildir.get_folder�s2���r�w�w�|�|�D�J�J��f��=�#�}�}�#�%�	%r#c��[OOUOQU*2o[	V O
Q5o[OOUQ2o[OO
U2%fP[O[OU[O[O*Q22U!)z>Create a folder and return a Maildir instance representing it.r|�r�
maildirfolder�)rrr�rrrr�r,r)�O_CREAT�O_WRONLY)rr�rr��maildirfolder_paths&&   r �
add_folder�Maildir.add_folder�s����w�w�|�|�D�J�J��f��5����}�}�5���W�W�\�\�$��@���w�w�~�~�0�1�1��H�H�R�W�W�/����b�k�k�1I���
��
r#c
�6�[OOUOQU*2o[O[OOUQ22[O[OOUQ22*FD3o[U2]6fU]*Q6wfJ#[
QU*2g	[OU2FDsoUQ6wfJUQ6wfJUQ6wfJ[OO[OOV#22%fJb[
QU8QU802g	[OUP
Q5FD�vqEoSFD6o[O[OOVC22J8	SFD6o[O[OOVC22J8	J�	[OU2P!)	�-Delete the named folder, which must be empty.r|r�r�zFolder contains message(s): %sr�zFolder contains subdirectory 'z': )�topdown)rrr�rrrjrr��walkrA�rmdir)rr�rr��root�dirs�filess&&     r �
remove_folder�Maildir.remove_folders\���w�w�|�|�D�J�J��f��5���Z�Z������T�5� 9�:��Z�Z������T�5� 9�:�;�;�E��5�z�A�~��q��S��#�$D�v�$M�N�N�;��Z�Z��%�E���~�%�5�.�U�e�^��w�w�}�}�R�W�W�\�\�$�6�7�7�#�%+�U�%4�5�5�&�
"$����u�!=�!=��D�����	�	�"�'�'�,�,�t�3�4������������d�2�3��">�
	����r#c��[O2o[O[OO	UO
Q22FDqo[OO	UO
QU2oU[OO
U2*
Q6�fJ[[OU2Js	P!)zDelete old files in "tmp".r�i@�)�timerrrr�rrrA)r�nowr�rs&   r �clean�
Maildir.cleansu���i�i�k���Z�Z������T�Z�Z�� ?�@�E��7�7�<�<��
�
�E�5�9�D��R�W�W�%�%�d�+�+�f�4��	�	�$��Ar#c	��[O2o[O2oQU7cUOQQ2oQU7cUOQQ2o[	U28Q[	U]*Q*28Q[
O28Q[O8Q	U80	o[
OOUOQ
U2o[
OU2[!QU*2g[c?[9O]*
tm[S2t![cKVh9hh9h)z=Create a file in the tmp subdirectory and open and return it.�/z\057r�z\072z.Mg��.A�P�Qr|r�z&Name clash prevented file creation: %s)r��socket�gethostnamer��intr�getpidr�_countrr�r�statr�_create_carefully�FileExistsErrorr)rr��hostnamerrs&    r r��Maildir._create_tmp#s���i�i�k���%�%�'���(�?��'�'��W�5�H��(�?��'�'��W�5�H�$'��H�c�#��'�C�-�.@�"�)�)�+�$+�N�N�H�>���w�w�|�|�D�J�J��t�4��	��G�G�D�M�!�!I�!%�"&�'�	'��!�	��N�N�a��N�
�(��.�.��"�
��
��		�s<� D�	E�E�1
D>�;E�>	E
�E
�	E�E
�
Ec��[O2UO*
]UO*6�cxP
oUOFDZo[O
O
UOU*2oV0OU*6�cP	oV0OU$J\	U%fP!-UmUOFD�oUOU*o[OU2FD�oUOQ2%cJ[O
OVE2o[O
OU2%cJbUOUO2]*o[O
OV%2UOU$J�	J�	[O2UmP!)z!Update table of contents mapping.r|)r�r�r�r�rrr-r�r�rr�r�r�rr)r�refreshr�mtimerr��prs&       r rc�Maildir._refresh;s8���9�9�;����(�1�t�/?�/?�+?�?��G��*�*�����(�(����V�)<�=���+�+�F�3�3�"�G�+0� � ��(�	+�
����	��&�&�F��;�;�v�&�D����D�)���#�#�C�(�(���G�G�L�L��-���7�7�=�=��#�#���{�{�4�:�:�.�q�1��"$�'�'�,�,�v�"=��	�	�$��*�'��)�)�+��r#c��[OO[OOUOUO
U*22%cUO
U*!UO2UO
U*![cK1h9h[c[
QS*2Pgh9h)z=Use TOC to return subpath for given key, or raise a KeyError.�No message with key: %s)rrr�r�rr�rHrcr?s&&r r�Maildir._lookupas���	��w�w�~�~�b�g�g�l�l�4�:�:�t�y�y��~�F�G�G��y�y��~�%�H�	
�
�
��	F��9�9�S�>�!��	�	��	��
�	F��4�s�:�;��E�	F�s0�AB�!B�B*�	B'�#B'�&B'�*	C	�4C	c���[UQ2%fUO2UmU[UO2*![cP![
cJ9h9h)z0Return the next message in a one-time iteration.�
_onetime_keys)r�rnr��next�
StopIterationrHr's&r r��Maildir.nextosX���t�_�-�-�!%����D���
��D��!3�!3�4�5�5�� �
���
��
�s#�A�	A#�A#�A#�A#�"A#)r�r�r�r�r�r�r�)'r�r�r�r�r�rr!r:rArIrNrVrcrYrr+rIrQrZr_rnr�r�r�r&r�r,r�r�r�r�r�r�r�rcrr�r�r�r�s@r rrs�����(��E��((�T?��&�6
�4�
�
�
%�
%��?�?�K�K�O�O�� �
�

�����%���& ��F�'�0$&�LF�
�
r#c�`�\sQsQsnQsQQksQsQsQsQs	Qs
Q	sQ
sQs
QsQ
sQsQsQsQQksQsQsUsP!)�_singlefileMailbox�|zA single-file mailbox.c�,�[OVV#2[UOQ2oV@m
PUm]UmP
Um
P
UmP
UmPUmP![c�oSO
[
O6Xc9S%c[SOQ2oPo=K[SO2gSO
[
O[
O17c[SOQ2oPo=K�gPo=hh9h)z!Initialize a single-file mailbox.�rb+zwb+r()rr!r)rr
r�ENOENTr�EACCES�EROFS�_filer��	_next_key�_pending�
_pending_sync�_locked�_file_length)rrrrr/rs&&&&  r r!�_singlefileMailbox.__init__s�������W�5�	��T�Z�Z��'�A��
���	������
�"������ ����!�		��w�w�%�,�,�&���T�Z�Z��/�A�,�T�Z�Z�8�8����U�\�\�5�;�;�7�7�����T�*����		�s<�A!�!	D�+D�,D�D�D�.AD�2D�
D�Dc���UO2UOU2UOUO$U9O]*
tmP	UmUO]*
!�r4)r�_append_messager�r�r�r8s&&r r:�_singlefileMailbox.add�sO������$(�$8�$8��$A��	�	�$�.�.�!����!���"����~�~��!�!r#c�R�UOU2UOUP	UmP!r)rr�r�r?s&&r rA�_singlefileMailbox.remove�s �����S���I�I�c�N���
r#c�t�UOU2UOU2UOU$P	UmP!r)rr�r�r�rMs&&&r rN�_singlefileMailbox.__setitem__�s-�����S���-�-�g�6��	�	�#����
r#c#�| �UO2UOO2FPiw�K
P!K3hrb)rr�rrr's&r rn�_singlefileMailbox.iterkeys�s"��������9�9�>�>�#�#�#�s�0<�:�<c�@�UO2VO7!rf)rr�r?s&&r r��_singlefileMailbox.__contains__�s�������i�i��r#c�N�UO2[UO2!ri)rrjr�r's&r r��_singlefileMailbox.__len__�s�������4�9�9�~�r#c�h�UO%f[UO2P	UmP!P!rq)r��
_lock_filer�r's&r r&�_singlefileMailbox.lock�s#���|�|�|��t�z�z�"��D�L�r#c�h�UO%c[UO2P
UmP!P!ru)r��_unlock_filer�r's&r r��_singlefileMailbox.unlock�s#���<�<�<�����$� �D�L�r#c
�~�UO%f1UO%c[UO2P
UmP!UOO	]]2UOO2oVO6wc[QUOU1*2g[UO2o-oUOU2[UOO22FD�oUOU*vqVUOO	U2UOU2UO2oUOO[!QV`OO2*
22oU%fLUO#U2J`VrO21V4$UO%U2J�	UO2Um[/U2UOO'2[(O0UO2o	[(O2UO,U	O42[(O6UO,U	O8U	O:2[(O@UO,UO2[EUOQ2UmV0mP
UmP
UmUOF%c[IUOP
Q5P!P!SO'2[(O*SO,2g9h[<[>1cK�h9h[BcP[(O*SO2[(O@SO,SO2CKh9h)rmz4Size of mailbox file changed (expected %i, found %i)�r�)�dotlock)%r�r��_sync_flushr�r��tellr�r�_create_temporaryr�_pre_mailbox_hookrOr�rr�_pre_message_hookr��minr��_post_message_hookr,rrAr�rr��chmod�st_mode�chown�st_uid�st_gidr
r
rr�r)r�r�)
r�cur_len�new_file�new_tocr@�start�stop�	new_startr�r=s
&         r r��_singlefileMailbox.flush�s����}�}�}��!�!�!��D�J�J�'�%*��"��	
�
�
����1���*�*�/�/�#���'�'�'�$�&?�&*�&7�&7��%A�&B�C�
C�%�T�Z�Z�0��	��G��"�"�8�,��d�i�i�n�n�.�/��"�i�i��n����
�
����&��&�&�x�0�$�M�M�O�	��!�Z�Z�_�_�S��15�
�
���8I�1I�.K�L�F�!���N�N�6�*� )�=�=�?�;����'�'��1�0�!)�
�
��D��
	�H���
�
�����w�w�t�z�z�"��
���������-�	��H�H�X�]�]�D�K�K����=�	1��I�I�h�m�m�T�Z�Z�0��$�*�*�e�,��
��	���
�"����<�<�<��t�z�z�5�1���/	��N�N���I�I�h�m�m�$�����(�	��	���	1��I�I�d�j�j�!��I�I�h�m�m�T�Z�Z�0�	1�sE�>CL�AL�6M�+M"�3M�M�M�M�"	N<�,AN<�;N<c��P!)�,Called before writing the mailbox to file f.rn�rr/s&&r r��$_singlefileMailbox._pre_mailbox_hookrsr#c��P!)�-Called before writing each message to file f.rnr�s&&r r��$_singlefileMailbox._pre_message_hookrsr#c��P!��,Called after writing each message to file f.rnr�s&&r r��%_singlefileMailbox._post_message_hookrsr#c��UO2UO%cUO2UOO	2P!SOO	2h9hSO%cSO2SOO	2hSOO	2h9h9hrx)r�r�r�r�r,r's&r r,�_singlefileMailbox.closes���	#��J�J�L�
#��<�<�<��K�K�M��
�
� � �"���
�
� � �"��	
#��<�<�<��K�K�M��
�
� � �"���
�
� � �"�s9�A1�A�A�A.�1C�3B0�B0�C�0C�Cc��UOeUO2UdUOU*!P![c[QS*2Pgh9h)z'Return (start, stop) or raise KeyError.r�)r��
_generate_tocrHr?s&&r r�_singlefileMailbox._lookup"s\���9�9����� ��?�
J��y�y��~�%����
J��8�3�>�?�T�I�
J�s�:�	A�Ac�Z�UOO]]2UOO2o[UO2]6Xc.UO
%fUO
UO2UOUO2UOU2oUOUO2UOO2UOO2Um
U![cSOOS2gh9h)z;Append message to mailbox and return (start, stop) offsets.)r�r�r�rjr�r�r�r��_install_messager�r��truncater�r�)rr9�before�offsetss&&  r r��"_singlefileMailbox._append_message,s����
�
����1�������"���t�y�y�>�Q��t�}�}�}�

�"�"�4�:�:�.�	��"�"�4�:�:�.��+�+�G�4�G��#�#�D�J�J�/�	
�
�
���� �J�J�O�O�-�������	��J�J����'��	�s�AD�	D*�D*)r�r�r�r�r�r�r�r�r%)r�r�r�r�r�r!r:rArNrnr�r�r&r�r�r�r�r�r,rr�r�r�r�s@r r�r�|s`���� �!�."���$�
 �
�
 �!�B2�H���	#�J��r#r�c�T`�\sQsQsnQsP	sQsQ	QksQ	QksQ	Qks	Qs
QsUsP!)
�	_mboxMMDF�CzAn mbox or MMDF mailbox.c���UOU2vq#UOOU2UOO2O	[
Q2O
Q2oUOOV0OO2*
2oUOUO	[
Q22oUOU2UOUQ*2U!)r]r#rr�r�)rr�r�r�r�r��decoder�r��_message_factory�set_unixfrom�set_from)rr@r�r��	from_line�stringr0s&&     r rV�_mboxMMDF.get_messageHs����l�l�3�'����
�
������J�J�'�'�)�1�1�'�3�?�F�F�w�O�	�������
�
���(9�!9�:���#�#�F�N�N�7�E�$B�C������#����Y�r�]�#��
r#c�n�[OUOV22OUQ5!)�3Return a string representation or raise a KeyError.)�unixfromr`)rr@�from_s&&&r re�_mboxMMDF.get_stringSs.���'�'��N�N�3�&�(�(1�	�5�	�(A�	Br#c�B�UOU2vq4UOOU2U%fUOO2UOO	V@OO2*
2oUO
[Q2!)rr�)rr�r�r�r�r�r�r�)rr@rr�r�rs&&&   r rc�_mboxMMDF.get_bytesXsf���l�l�3�'����
�
�������J�J���!�������
�
���(9�!9�:���~�~�g�u�-�-r#c��UOU2vq4UOOU2U%fUOO2[	UOUOO2U2!)rj)rr�r�r��_PartialFiler�)rr@rr�r�s&&&  r rY�_mboxMMDF.get_fileasS���l�l�3�'����
�
�������J�J���!��D�J�J��
�
���(9�4�@�@r#c��Po[U[2%cUOU2o[U[2%cFUO	Q2%c/UOQ2oUP6wcUPUoV]*PoL�SoQoL�[U[2%c*UO2OQ2oQU*oLO[U[OO2%c&UO2oUdUOQ2oUe?Q[O[O22O2*oUO O#2oUO O%U[&*2UO)VO UO*2UO O#2oVV1!)z1Format a message and blindly write to self._file.r�r�r#rsFrom MAILER-DAEMON )r�r�r�r�r��find�_mboxMMDFMessage�get_fromr�rar9r�get_unixfromr��asctime�gmtimer�r�r�r�r��
_mangle_from_)rr9r�newline�authorr�r�s&&     r r	�_mboxMMDF._install_messageisg���	��g�s�#�#��+�+�G�4�G��g�u�%�%�'�*<�*<�X�*F�*F��l�l�5�)�G��"�}�#�H�W�-�	�!�A�+�,�/��#�	���
��!1�
2�
2��%�%�'�.�.�w�7�F� �6�)�I�
�����!6�!6�
7�
7��,�,�.�I��$�%�,�,�W�5�	���.����d�k�k�m�1L�1S�1S�1U�U�I��
�
���!���
�
����W�,�-����7�J�J��0B�0B�C��z�z��� ���}�r#rnr�)
r�r�r�r�r�r*rVrercrYr	r�r�r�s@r rrCs-����"��M�	�B�
.�A��r#rc�D`�\sQsQsnQsP	sP	sQQksQsQs	Qs
UsP!)r�zA classic mbox mailbox.c�J�[Um[OVV#2P!)zInitialize an mbox mailbox.)r
rrr!rs&&&&r r!�
mbox.__init__���� +������4�w�7r#c�2�UO[2P!r�r�r�r�s&&r r��mbox._post_message_hook�s��	����r#c�*�,,q!P
oUOO]2UOO2oUOO2oUO	Q2%cn[U2[U26c@U%c'UO
U[[2*
2LUO
U2UO
U2P
oJ�U%fAU%c'UO
U[[2*
2LUO
U2LU[6XcP	oCJP
oCJ[[[V222Um[UO2UmUOO2Um
P!)�0Generate key-to-(start, stop) table of contents.r�)r�r�r�r�r�rjr�r��dict�	enumerate�zipr�r�r�)r�starts�stops�last_was_empty�line_posr�s&     r r�mbox._generate_toc�s���B�����
�
�������z�z���(�H��:�:�&�&�(�D����x�(�(��u�:��F��+�%����X��G��%<�=�
���X�.��
�
�h�'�!&���!��L�L��C��L�!8�9��L�L��*�����!%��!&����3�v�#5�6�7��	��T�Y�Y���� �J�J�O�O�-��r#�r�rr�r�r�)r�r�r�r�r�r*r�r!r�rr�r�r�s@r rr�s(����!��M��O�8�
�.�.r#c�B`�\sQsQsnQsQQksQsQsQsQs	Us
P!)	r�zAn MMDF mailbox.c�J�[Um[OVV#2P!)zInitialize an MMDF mailbox.)r
rrr!rs&&&&r r!�
MMDF.__init__�r2r#c�@�UOQ[*2P!)r��r4r�s&&r r��MMDF._pre_message_hook�s��	���#�g�-�.r#c�V�UO[Q*[*2P!)rrFr4r�s&&r r��MMDF._post_message_hook�s��	����-�-��7�8r#c�<�,,q!UOO]2]oSoUOO2oUOO2oUO	Q[
*2%c�UO
U2SoUOO2oUOO2oUQ[
*6Xc(UO
U[[
2*
2J�U%cJzUO
U2J�U%cCJ[[[V222Um[UO2UmUOO]]2UOO2Um
P!)r7rF)r�r�r�r�r�r�r�rjr8r9r:r�r�r�)rr;r<�next_posr>r�s&     r r�MMDF._generate_toc�s���B���
�
���������H��:�:�&�&�(�D��z�z���(�H����2�W�<�=�=��
�
�h�'��'�H��:�:�.�.�0�D�#�z�z���0�H��2�W�<�<����X��G��%<�=��!�T����X�.���T����3�v�#5�6�7��	��T�Y�Y�����
�
����1�� �J�J�O�O�-��r#r@r�)r�r�r�r�r�r!r�r�rr�r�r�s@r rr�s!�����8�
/�9�.�.r#c�`�\sQsQsnQsQQksQsQsQsQs	Qs
Q	sQ
sQs
QsQ
sQsQsQsQsQsQsQsQsQsQsQsQsQsUsP!)r��zAn MH mailbox.c�6�[OVV#2[OO	UO
2%f�U%c�[OUO
Q2[O[O[OOUO
Q2[O[O*[O*Q22L[UO
2gP
UmP!)zInitialize an MH instance.r��
.mh_sequences�)rr!rrr�rr�r,r)r�r��O_EXCLr�rr�rs&&&&r r!�MH.__init__�s�������W�5��w�w�~�~�d�j�j�)�)��������U�+������������d�j�j�/�!J�!#���b�i�i�!7�"�+�+�!E�u�N�O�)����4�4���r#c��UO2o[U2]6Xc]oL[U2]*o[OOUO[U22o[U2oP
oUO%c[U2UOV2[!U["2%cUO%V2UO%c[U2U%f[U2U![cCSO%c[S2[S2P	o[OS2gh9hSO%c
[S2hh9hS%f
[S2hh9hr�)rrrj�maxrrr�rr�r�r�r�r�r�r�rrAr�r�_dump_sequences)rr9rr�new_keyr%r/�closeds&&     r r:�MH.add�s$���y�y�{���t�9��>��G��$�i�!�m�G��7�7�<�<��
�
�C��L�9���h�'����	��|�|�|��1�
�
$�	��&�&�w�2��g�y�1�1��(�(��:��<�<�<� ��O���A�����!%���|�|�|�$�Q����N�!�F��I�I�h�'�����<�<�<� ��O� ����A���s`�8E4�
E4�D�(E�>E�E4�!E4�	E�E�0E�E�E1�$
E1�1E4�4F
�=
F
c�^�[OOUO[	U22o[UQ2oUO
2[OU2P![c8oSO[O6Xc[QS*2ggPo=hh9h)r>r�r�)rrr�rr�r)r,rAr
rr�rH)rr@rr/rs&&   r rA�	MH.removes{���w�w�|�|�D�J�J��C��1��		��T�5�!�A�
�G�G�I��I�I�d�O���	��w�w�%�,�,�&��8�3�>�?�?���		�s#�A*�*	B,�4B,�5B'�B'�'B,c��[OOUO[	U22o[UQ2oUO%c[U2[O[O
U[O[O*22UOV$2[!U["2%cUO%V!2UO%c['U2[)U2P![c8oSO[O6Xc[QS*2ggPo=hh9hSO%c
['S2hh9h[)S2h9h)rLr�r�)rrr�rr�r)r
rr�rHr�r�r,r��O_TRUNCr�r�rrVr�r)rr@r9rr/rs&&&   r rN�MH.__setitem__&s���w�w�|�|�D�J�J��C��1��	��T�5�!�A�	��|�|�|��1�
�
$��������r�{�{�R�Z�Z�'?�@�A��"�"�7�.��g�y�1�1��(�(��6��<�<�<� ��O���N��#�	��w�w�%�,�,�&��8�3�>�?�?���		���<�<�<� ��O� ��
��N�s`�D�E9�E9�!A4E�E�'E9�9E9�	E�E�E�;E�E�E6�)
E6�6E9�9
Fc�P�UO%c?[[OO	UO
[
U22Q2oL>[[OO	UO
[
U22Q2oS9^tt^2UO%c[U2[U2oUO%c[U2PPP2UO2O2FDvqVV7fJ
WO!U2J 	W![c8oSO[O6Xc[QS*2ggPo=hh9hSO%c
[S2hh9h)%fhK�9h)r]r�r(r�)r�r)rrr�rr�r
rr�rHr�rr��
get_sequencesr��add_sequence)rr@r/rr0r��key_lists&&     r rV�MH.get_message>s ��		��|�|�|�������d�j�j�#�c�(�;�U�C��������d�j�j�#�c�(�;�T�B���Q��|�|�|��1�
�
$���l���<�<�<� ��O��#�0�0�2�8�8�:�N�D���� � ��&�;��
��!�	��w�w�%�,�,�&��8�3�>�?�?���		���<�<�<� ��O� ��
�Q�sj�D-�=D-�=D-�F�.F�:E2�F�F�-	E/�7E/�8E*�E*�*E/�2F�
F�F�F%	�F%	c��UO%c?[[OO	UO
[
U22Q2oL>[[OO	UO
[
U22Q2oS9^tt^2UO%c[U2UO2O[Q2UO%c[U2ttPPP2![c8oSO[O6Xc[QS*2ggPo=hh9hSO%c
[S2hh9h)%fhP!9h)r3r�r(r�r�)r�r)rrr�rr�r
rr�rHr�r�r�r�r��rr@r/rs&&  r rc�MH.get_bytesWs���		��|�|�|�������d�j�j�#�c�(�;�U�C��������d�j�j�#�c�(�;�T�B���Q��|�|�|��1�
�
$��v�v�x�'�'���7��<�<�<� ��O��Q���	��w�w�%�,�,�&��8�3�>�?�?���		���<�<�<� ��O� ��
�Q�Q�sj�D�=D�=D�E-�.E-�:#E
�E-�/E-�	E�E�E�/E�E�
E*�
E*�*E-�-E>	�6E>	c� �[[OOUO[U22Q2o[U2![c8oSO[O6Xc[QS*2ggPo=hh9h)rjr(r�)r)rrr�rr�r
rr�rHr7res&&  r rY�MH.get_filelsl��	��R�W�W�\�\�$�*�*�c�#�h�7��>�A��!�}����	��w�w�%�,�,�&��8�3�>�?�?���		�s#�=A�	B
�B
�B�5B�B
c�t�[[Q[OUO2222!)rmc3�t�SF �D)oUO2%fJ[U2w�	J+	P!3hr%)�isdigitr�)�.0r�s& r �	<genexpr>�MH.iterkeys.<locals>.<genexpr>ys'��3I���3I�%�).����&�3�u�:�:�3I�s�8�8)�iterrOrrrr's&r rn�MH.iterkeysws/���F�:�2�:�:�d�j�j�3I�:�:�;�	;r#c��[OO[OOUO[U222!rf)rrr�r�rr�r?s&&r r��MH.__contains__|s,���w�w�~�~�b�g�g�l�l�4�:�:�s�3�x�@�A�Ar#c�H�[[UO222!ri)rjrqrnr's&r r��
MH.__len__�s���4��
�
��(�)�)r#c�,�U%cPLQoU%cQQ-L-o[OOUOQ2o[	UQU*1-U@![
cLh9h[	SQS*1-S@![cJLh9h)��b�encoding�ASCIIrPzr+zx+)rrr�rr)rr�)r�text�mode�kwargsrs&&   r �_open_mh_sequences_file�MH._open_mh_sequences_file�s����r�s��*.�*�g�&�B���w�w�|�|�D�J�J��8���
��D�$��+�8��8�8��$�
��
��
��D�$��+�8��8�8��"�
��
�s0�A�	A+�'A+�*A+�/B�	B�B�Bc��UO%f6UOP
Q5Um[UO2P	UmP!P!)r��rz)r�r}r�r�r's&r r&�MH.lock�s8���|�|�|��5�5�5�5�A�D�J��t�z�z�"��D�L�r#c��UO%c6[UO2[UO2U;P
UmP!P!ru)r�r�r�rr's&r r��	MH.unlock�s4���<�<�<�����$���
�
�#��
� �D�L�	r#c��P!)r�rnr's&r r��MH.flush�rsr#c�P�UO%cUO2P!P!rx)r�r�r's&r r,�MH.close�s���<�<�<��K�K�M�r#c��,o[OUO2FDco[OO	[OOUOU22%fJRUO
U2Je	U!)r{)rrrrr�r�r�r�s&  r r��MH.list_folders�sW�����Z�Z��
�
�+�E��w�w�}�}�R�W�W�\�\�$�*�*�e�<�=�=��
�
�e�$�,��
r#c��[[OOUOU2UO
P
Q5!)z+Return an MH instance for the named folder.r��rrrr�rrr�s&&r r��
MH.get_folder�s-���"�'�'�,�,�t�z�z�6�2��-�-��7�	7r#c��[[OOUOU2UO
Q5!)z:Create a folder and return an MH instance representing it.r�r�r�s&&r r��
MH.add_folder�s+���"�'�'�,�,�t�z�z�6�2��-�-�)�	)r#c�v�[OOUOU2o[OU2oUQ,6Xc6[O
[OOUQ22L$U,6XcL[
QUO*2g[OU2P!)r�rPzFolder not empty: %s)rrr�rrrArr�)rr�r�entriess&&  r r��MH.remove_folder�sx���w�w�|�|�D�J�J��/���*�*�T�"����'�'��I�I�b�g�g�l�l�4��9�:�
��]��� 6���� C�D�D�
����r#c
�`�-o[[OOUOQ2QQQ5oS9^tt^2[
UO22oSFD�oUOQ2vqV[
2oUO2FDooUO2%cUO[U22J5QUOQ22vq�UO[V�]*22Jq	[U2Tt,tFD
oV�7fJUMJ	toV$[V*2]6XcVJ�J�	PPP2U![
cSt!h9httoh[ c"[#QSO%2*2gh9h)%fhS!9h)	z=Return a name-to-key-list dictionary to define each sequence.rP�rry)rxr�c3�D�SF �Do[U2w�	J	P!3hr%)r�)rl�xs& r rm�#MH.get_sequences.<locals>.<genexpr>�s��?���?�a�3�q�6�6�?�s� �-z"Invalid sequence specification: %s)r)rrr�rrrPrrrrkr:r�r��rangerOrjr�r�rstrip)r�resultsr/�all_keysr�r��contentsrr�specr�r�r@s&           r r`�MH.get_sequences�se����	��R�W�W�\�\�$�*�*�o�>��g�V�A��Q��4�9�9�;�'�H���5�%)�Z�Z��_�N�D��5�D� (��� 0���<�<�>�>� �H�H�S��Y�/�*K�4�:�:�c�?�*K�K�E� �K�K��e�A�X�(>�?�!1�5;�4�L�%=�L�S�,/�O�&)�S�L�%=�G�M��7�=�)�Q�.�#�M�/���&���+!�	��N�	��%=��"�5�%�&J�&*�k�k�m�'4�5�5�5��!�Q�&��sm�6E� F�&AE-�-A&E-�
E(�"E(�(E-�E-�F�	E%�E%�$E%�(E-�-	F�7"F�F�F-	�%F-	c	�"�UOP	Q5o[O[OUO[O
[O*22UO2FD�vq4[U2]6XcJUOUQ*2PoP
o[[U22FDjoU]*
U6XcU%fP	oUOQ2L;U%cP
oUOU8QU802LUOQU*2SoJl	U%c$UO[U2Q*2J�UOQ2J�	[U2P![S2h9h)z:Set sequences using the given name-to-key-list dictionary.r�r�r�� z %s�
)r}rr,r)r�r�r]r�rjr�rOrPr�r)r�	sequencesr/r�rr�prev�
completingr@s&&      r �
set_sequences�MH.set_sequences�s���(�(�d�(�3��	��H�H�R�W�W�Q�V�V�R�[�[�2�:�:�%=�>�?�'�o�o�/�
���t�9��>������s�
�#���"�
�!�#�d�)�,�C��Q�w�$��)�)-�J��G�G�C�L��#�%*�
����4�� 5�6�������,��D�-���G�G�C��I��,�-��G�G�D�M�)0�,
��N��K��N�s,�A=F�AF�F�F�;AF�<8F�
Fc
�d�UO2o]o,oUO2FD�oU]*
U6wc�UOVB]*12[O[O
O
UO[U22[O
O
UO[U]*222[O[O
O
UO[U222U]*
oJ�	U]*Um
[U2]6XcP!UO2FD,vqVSFD vqxVv7fJ
V�UO!U2$J"	J.	UO#U2P![[1c�[O[O
O
SO[S22[O
O
SO[S]*222CKh9h)z?Re-name messages to eliminate numbering gaps. Invalidates keys.)r`rnr�rr	rr�rr��unlinkr
rrr�rjr��indexr�)	rr�r��changesr@r�rb�oldr�s	&        r �pack�MH.packs|���&�&�(�	������=�=�?�C��Q�w�$������A�X��/�B��G�G�B�G�G�L�L����S��X�>��G�G�L�L����S����]�C�E��I�I�b�g�g�l�l�4�:�:�s�3�x�@�A��A�I�D�#�������w�<�1���'�o�o�/�N�D�#����?�47�X�^�^�C�0�1�$�0�	
���9�%��'��8�G��I�I�b�g�g�l�l�4�:�:�s�3�x�@� �g�g�l�l�4�:�:�s�4�!�8�}�E�G�G�s�BF�H/�*BH/�.H/c�0�UO2oUO2oUO2FD7vqVVS7cUOU2JV&7fJ&VfOU2J9	SFDoVt7fJU,VG$J	UO	U2P!)z;Inspect a new MHMessage and update sequences appropriately.)r`r�r�r�r�)rr9r@�pending_sequences�
all_sequencesr�rb�sequences&&&     r rV�MH._dump_sequencess���#�1�1�3���*�*�,�
�+�1�1�3�N�D��(�����$����^�^�C�0�1�	4�
*�H��,�+.�%�
�'�*�	
���=�)r#)r�r�r�r�)r�r�r�r�r�r!r:rArNrVrcrYrnr�r�r}r&r�r�r,r�r�r�r�r`r�r�rVr�r�r�s@r rr�s������
� �D��0�2$�*	�;�
B�*�� �!���
�7�
)�

��8�:&�4*�*r#c�`�\sQsQsnQs\.Ql2sQQksQsQs	Qs
QsQsQ	s
Q
sQsQsQ
sQsQsQsUsP!)ri*zAn Rmail-style Babyl mailbox.c�B�[OVV#2-UmP!)zInitialize a Babyl mailbox.)r�r!�_labelsrs&&&&r r!�Babyl.__init__0s���#�#�D��@���r#c��[OV2o[U[2%cUO	2UO
U$U!r�)r�r:r�r�
get_labelsr�)rr9r@s&& r r:�	Babyl.add5s;�� �$�$�T�3���g�|�,�,� '� 2� 2� 4�D�L�L����
r#c�p�[OV2VO7cUOUP!P!r)r�rAr�r?s&&r rA�Babyl.remove<s+���!�!�$�,��,�,�����S�!�r#c��[OVU2[U[2%c UO	2UO
U$P!P!r)r�rNr�rr�r�rMs&&&r rN�Babyl.__setitem__Bs;���&�&�t�'�:��g�|�,�,� '� 2� 2� 4�D�L�L���-r#c���UOU2vq#UOOU2UOO2[O
2oUOO2oUQ[*6Xf	U%fL'UOUO[Q22J][O
2oUOO2oU[6Xf	U%fL'UOUO[Q22JVV0OO2*
oUOOU2oUO[Q2o[UO2U*2o	U	OUO22VO7c#U	OUOU*2U	!)r]�*** EOOH ***r�)rr�r�r�r�r�r�r�r�r�r�rr��set_visibler��
set_labels)
rr@r�r��original_headersr��visible_headers�n�bodyr0s
&&        r rV�Babyl.get_messageHsJ���l�l�3�'����
�
������
�
�����:�:�<����:�:�&�&�(�D����0�0����"�"�4�<�<���#?�@��*�*�,����:�:�&�&�(�D��w��d���!�!�$�,�,�w��">�?��:�:�?�?�$�$���z�z���q�!���|�|�G�U�+���+�4�4�6��=�>������0�0�2�3��,�,���N�N�4�<�<��,�-��
r#c��UOU2vq#UOOU2UOO2[O
2oUOO2oUQ[*6Xf	U%fL'UOUO[Q22J]UOO2oU[6XfU%cJ0UO2oV0OO2*
oUOOU2oUO[Q2oVh*!)rr�r�)rr�r�r�r�r�r�r�r�r�r�r�)	rr@r�r�r�r��headersr�r�s	&&       r rc�Babyl.get_bytesds����l�l�3�'����
�
������
�
�����:�:�<����:�:�&�&�(�D����0�0����"�"�4�<�<���#?�@���:�:�&�&�(�D��w��d�d��"�+�+�-���:�:�?�?�$�$���z�z���q�!���|�|�G�U�+���~�r#c�v�[OUOU2OQ[22!)rjr�)r�r�rcr�r�r?s&&r rY�Babyl.get_filezs'���z�z�$�.�.��-�5�5�e�W�E�F�Fr#c���UO2[2oUOO2FDoUO	U2J	UOUO2[U2!)z4Return a list of user-defined labels in the mailbox.)rrPr�r}r��difference_update�_special_labelsrq)r�labels�
label_lists&  r r��Babyl.get_labels~sS����������,�,�-�-�/�J��M�M�*�%�0�� � ��!5�!5�6��F�|�r#c��,,q!UOO]2]o,oSoUOO2oUOO2oUQ[*6Xc�[U2[U26c&UO
U[[2*
2UO
U2UOO2Q*OQ2Tt,tFD+oUO2%fJUO2MJ-	ooUO
U2CJUQ6XfUQ[*6XcE[U2[U26c)UO
U[[2*
2CJlCJoU%cCJzUO
U[[2*
2[[[V222Um[[U22Um
[UO2UmUOO]]2UOO2UmP!ttoh)r7sr}�,�)r�r�r�r�r�rjr�r�stripr8r9r:r�r�r�r�)	rr;r<rK�label_listsr>r��labelr�s	&        r r�Babyl._generate_toc�s����B���
�
�����������H��:�:�&�&�(�D��z�z���(�H��{�W�,�,��u�:��F��+��L�L��C��L�!8�9��
�
�h�'�+/�:�:�+>�+>�+@��+D�+J�+J�4�+P�:�+P�-2�+0�;�;�=�(�%�+�+�-�+P��:��"�"�6�*����D�G�g�,=�$=��u�:��F��+��L�L��C��L�!8�9�,��T����X��G��4�5����3�v�#5�6�7��	��I�k�2�3����T�Y�Y�����
�
����1�� �J�J�O�O�-����:s�-I�Ic��Q[*oUQ[**
oUO2oQU2oUQQOU2*[**
oUQ*
oUOU2P!)r�sBABYL OPTIONS:s
Version: 5c3�L�SF �DpO2w�	J	P!3hr%)r�)rlr�s& r rm�*Babyl._pre_mailbox_hook.<locals>.<genexpr>�s��f���f�U�,�,�.�.�f�s�$sLabels:r�r�)r�r�r�r�)rr/�babylr�s&&  r r��Babyl._pre_mailbox_hook�sc��!�G�+��
���(�(�����"��5�f�5��
��d�i�i��/�/�'�9�9��
����	����r#c�@�UOQ[*2P!)r��r4r�s&&r r��Babyl._pre_message_hook�s��	����'�!�"r#c�@�UO[Q*2P!)rr�r4r�s&&r r��Babyl._post_message_hook�s��	����'�!�"r#c���UOO2o[U[2%Cc",o,oUO	2FD7oVPO
7cUO
U2J&UO
U2J9	UOOQ2SFD3oUOOQUO2*2J5	UOOQ2SFD:oUOOQUO2*Q*2J<	UOO[2L&UOOQ[*2[U[OO2%Cc>[O2o[OO!UP
]2oUO#U2UO%]2UO'2oUOOUO)Q[22UQ6XfU%cJQUOOQ[*2[U[2%c�[O2o	[OO!U	P
]2o
U
O#UO+22U	O'2oUOOUO)Q[22UQ6XfU%cJQLcUO%]2UO'2oUOOUO)Q[22UQ6XfU%cJQUO-Q	2oU%fCLUOOUO)Q[22JM[U[.[0[O212%Cc�[U[O22%c-[4O6Q
[8]2UO;2o[U[02%cUO=U2oUO?Q2]*oU]*
P6wc�UOOUPUO)Q[22UOOQ[*2UOOUPUO)Q[22UOOVPO)Q[22CLfUOOQ[*[*2UOOUO)Q[22CL[AUQ2%Cc�[AUQ
2%c)[4O6Q[8]2UOBoUO2o
P	oUO'2oUOEQ2%cUPQQ*oL#UOEQ2%c
UPPQ*oUOOUO)Q[22UQ6XfU%cJ�U%c<P
oUOOQ[*2UO%U
2J�UO'2oU%fL�UOEQ2%cUPQ[*oLOUOEQ2%cUPP[*oL'UOEQ2%cUPP[*oUOOU2J�[GQ[IU2*2gUOO2oV/1!)z0Write message contents and return (start, stop).�1s, s,,� r�s1,,r�r�r�r�s

r�r�r�r�r�r�r�)%r�r�r�rr�r�r�r�r�r�rar9rr�r�r�r�r�r�r�r��get_visibler�r�r�r�r�r�r�r�r�r$r�r�r�r�r-)rr9r��special_labelsr�r��orig_buffer�orig_generatorr��
vis_buffer�
vis_generatorr��
body_start�original_pos�
first_passr�s&&              r r	�Babyl._install_message�s����
�
���!���g�|�,�,��N��F� �+�+�-���0�0�0�"�)�)�%�0��M�M�%�(�	.�

�J�J���T�"�'���
�
� � ������!7�8�(��J�J���U�#����
�
� � ������!6��!=�>� ��J�J���W�%��J�J���V�g�-�.��g�u�}�}�4�4�5�5��*�*�,�K�"�_�_�;�;�K��PQ�R�N��"�"�7�+����Q���"�+�+�-���
�
� � ����e�W�!=�>��5�=�����J�J���_�w�6�7��'�<�0�0��Z�Z�\�
� %��� >� >�z�5�RS� T�
��%�%�g�&9�&9�&;�<��%�.�.�0�D��J�J�$�$�T�\�\�%��%A�B��u�}�D�D��� � ��#��&�/�/�1�D��J�J�$�$�T�\�\�%��%A�B��u�}�D�D���$�)�)�$�/�����
�
� � �����w�!?�@�
��%��b�k�k�!:�
;�
;��'�2�;�;�/�/��
�
�*�+=�q�B�!�*�*�,���'�3�'�'��/�/��8�� ���g�.��2�J��A�~��#��
�
� � ���*�!5�!=�!=�e�W�!M�N��
�
� � ��7�!:�;��
�
� � ���*�!5�!=�!=�e�W�!M�N��
�
� � ���!5�!=�!=�e�W�!M�N��
�
� � ��7�!:�W�!D�E��
�
� � ������!@�A�
�W�j�
)�
)��w��)�)��
�
�5�6H�!�M�!�.�.��"�<�<�>�L��J���'�'�)���=�=��)�)����9�u�,�D��]�]�5�)�)����9�u�,�D��
�
� � ����e�W�!=�>��5�=���!�%*�
��
�
�(�(��7�)B�C����\�2����'�'�)�����=�=��)�)����9�w�.�D��]�]�5�)�)����9�w�.�D��]�]�5�)�)����9�w�.�D��
�
� � ��&��6��g��F�G�G��z�z��� ���}�r#)r�r�r�r�>�filed�edited�resent�unseen�deleted�answered�	forwardedr�)r�r�r�r�r��	frozensetr�r!r:rArNrVrcrYr�rr�r�r�r	r�r�r�s@r rr*sb����'��!B�C�O��
�"�5��8�,G��.�<�#�#�i�ir#c�<`�\sQsQsnQsQQksQsQsQsUs	P!)ri#z0Message with mailbox-format-specific properties.c��[U[OO2%cQUO	[
OU22[U[2%cUOU2P!P![U[2%c(UO	[OU22P![U[2%c(UO	[OU22P![U[O2%c(UO	[OU22P![UQ2%c(UO	[O U22P!Ue,[OOO#U2P![%Q['U2*2g)zInitialize a Message instance.r�r�)r�rar9r�_become_message�copy�deepcopy�_explain_tor�rbr��message_from_stringr��
TextIOWrapper�message_from_filer��message_from_binary_filer!r�r-r8s&&r r!�Message.__init__&s ���g�u�}�}�4�4�5�5�� � ����w�!7�8��'�7�+�+��#�#�D�)�,�
���
'�
'�� � ��!9�!9�'�!B�C�
���
%�
%�� � ��!:�!:�7�!C�D�
���!1�!1�
2�
2�� � ��!8�!8��!A�B�
�W�f�
%�
%�� � ��!?�!?��!H�I�
�_��M�M�!�!�*�*�4�0��6��g��F�G�Gr#c��[UQ,2oUOFD+oV27fJUOU*UOU$J-	P!)z0Assume the non-format-specific state of message.�_type_specific_attributes)�getattr�__dict__)rr9�
type_specificr�s&&  r r��Message._become_message9s@����)D�b�I�
��$�$�D��(�&-�&6�&6�t�&<��
�
�d�#�%r#c�J�[U[2%cP![Q2g)z:Copy format-specific state to message insofar as possible.z Cannot convert to specified type)r�rr�r8s&&r r��Message._explain_to@s���g�w�'�'���>�?�?r#rnr%)
r�r�r�r�r�r!r�r�r�r�r�s@r rr#s����:�H�&=�@�@r#c�z`�\sQsQsnQs,QNsQQksQsQsQs	Qs
QsQ	sQ
s
QsQsQ
sQsQsUsP!)r	iHz)Message with Maildir-specific properties.c��QUmPUm[O2Um[OV2P!)z%Initialize a MaildirMessage instance.r�)�_subdir�_infor��_daterr!r8s&&r r!�MaildirMessage.__init__Ms+�������
��Y�Y�[��
�����'r#c��UO!)zReturn 'new' or 'cur'.)r
r's&r r�MaildirMessage.get_subdirTs���|�|�r#c�T�UQ6XfUQ6Xc	VmP![QU*2g)zSet subdir to 'new' or 'cur'.r�r�z!subdir must be 'new' or 'cur': %s)r
r�)rrs&&r r*�MaildirMessage.set_subdirXs%���U�?�f��o�!�L��@�6�I�J�Jr#c�p�UOOQ2%cUOQ*!P!)�*Return as a string the flags that are set.rGrH)rr�r's&r rI�MaildirMessage.get_flags_s(���:�:� � ��&�&��:�:�b�>�!�r#c�T�QPO[U22*UmP!)�)Set the given flags and unset all others.rG)r�rOr)rrLs&&r rQ�MaildirMessage.set_flagsfs���B�G�G�F�5�M�2�2��
r#c��UOPO[UO22[U2*22P!�z.Set the given flag(s) without changing others.�rQr�rPrI�rrUs&&r rZ�MaildirMessage.add_flagj�,�����r�w�w�s�4�>�>�#3�4�s�4�y�@�A�Br#c���UO2%cJUOPO[UO22[U2*
22P!P!)�7Unset the given string flag(s) without changing others.)rIrQr�rPrs&&r r_�MaildirMessage.remove_flagns>���>�>����N�N�2�7�7�3�t�~�~�'7�#8�3�t�9�#D�E�F�r#c��UO!)z<Return delivery date of message, in seconds since the epoch.)rr's&r r�MaildirMessage.get_dates����z�z�r#c�n�[U2UmP![c[QS*2Pgh9h)z9Set delivery date of message, in seconds since the epoch.zcan't convert to float: %s)�floatrr�r�)r�dates&&r r,�MaildirMessage.set_datews7��	K��t��D�J���	K��8�4�?�@�d�J�	K�s��	4�4c��UO!)z%Get the message's "info" as a string.)rr's&r r�MaildirMessage.get_info~r&r#c�v�[U[2%c	VmP![Q[	U2*2g)z Set the message's "info" string.zinfo must be a string: %s)r�r�rr�r-)rr=s&&r r+�MaildirMessage.set_info�s)���d�C� � ��J��7�$�t�*�D�E�Er#c�F�[U[2%c`UOUO22UO	UO22UO
UO22P![U[2%c�[UO22oQU7cUOQ2UO2Q6XcUOQ2QU7cUOQ2QU7cUOQ2QU7cUOQ2UOQ	[OUO222P![U[2%cf[UO22oQU7cUOQ
2QU7cUOQ2QU7cUOQ2P!P![U[ 2%c~[UO22oQU7cUO#Q
2QU7cUO#Q
2QU7cUO#Q2QU7cUO#Q2P!P![U[$2%cP!['Q[)U2*2g)z;Copy Maildir-specific state to message insofar as possible.�S�Rr��O�T�D�F�A�
MAILER-DAEMONr��replied�flaggedr�r�r�r��$Cannot convert to specified type: %s)r�r	rQrIr*rr,rr%rPrZrr�r)rrar�	add_labelrr�r-)rr9rLs&& r r��MaildirMessage._explain_to�s���g�~�.�.����d�n�n�.�/����t���0�1����T�]�]�_�-�
��!1�
2�
2�����(�)�E��e�|�� � ��%���� �E�)�� � ��%��e�|�� � ��%��e�|�� � ��%��e�|�� � ��%����_�d�k�k�$�-�-�/�.J�K�
���
+�
+�����(�)�E��%���$�$�X�.��e�|��$�$�Y�/��e�|��$�$�Y�/��
���
.�
.�����(�)�E��%���!�!�(�+��e�|��!�!�)�,��e�|��!�!�*�-��e�|��!�!�+�.��
���
)�
)���B� ��M�*�+�
+r#)rrr
)r
rrr%)r�r�r�r�r�rr!rr*rIrQrZr_rr,rr+r�r�r�r�s@r r	r	HsT����3� =��(��K��3�C�G�
�K��F�)+�)+r#c�d`�\sQsQsnQsQ,sQ
QksQsQ
QksQs	Qs
Q	sQ
sQs
QsUsP!)r%i�z/Message with mbox- or MMDF-specific properties.�_fromc�0�UOQP	2[U[OO2%cDUO2oUd0UO
Q2%cUOUQ*2[OV2P!)z'Initialize an mboxMMDFMessage instance.r7zFrom r�)rr�rar9rr'r�r!)rr9rs&& r r!�_mboxMMDFMessage.__init__�si���
�
�o�t�,��g�u�}�}�4�4�5�5��+�+�-�H��#��(;�(;�G�(D�(D��
�
�h�r�l�+�����'r#c��UO!)z Return contents of "From " line.�r>r's&r r&�_mboxMMDFMessage.get_from�r&r#c��Ud@UP	Ic[O2oUQ[OU2**
oVmP!)z>Set "From " line, formatting and appending time_ if specified.r�)r�r)r(r>)rr�time_s&&&r r�_mboxMMDFMessage.set_from�s7������}����
���S�4�<�<��.�.�.�E��
r#c�V�UOQP2UOQP2*!)r�Status�X-Status)rSr's&r rI�_mboxMMDFMessage.get_flags�s#���x�x��"�%�����R�(@�@�@r#c���[U2oPPq2QFD$oVA7fJV$*
oUOU2J&	QFD$oVA7fJV4*
oUOU2J&	UPO[U22*
oUO	QU2UO	QU2P![
cSO
QS2K4h9h[
cSO
QS2P!h9h)rrHrI)r1r2)r4r5r6)rPrAr�rO�replace_headerrH�
add_header)rrL�status_flags�
xstatus_flagsrUs&&   r rQ�_mboxMMDFMessage.set_flags�s����E�
��&(�"�m��D��}��$�����T�"��$�D��}��%�
����T�"�$�	�������/�/�
�	4�����,�7�	7����
�M�:���	4��O�O�H�l�3�	4���	7��O�O�J�
�6�	7�s0�B/�C�/	C�9C�C�	C3�C3�2C3c��UOPO[UO22[U2*22P!rrrs&&r rZ�_mboxMMDFMessage.add_flag�r r#c��QU7fQU7cJUOPO[UO22[U2*
22P!P!)r"rHrIrrs&&r r_�_mboxMMDFMessage.remove_flag�s@���t��z�T�1��N�N�2�7�7�3�t�~�~�'7�#8�3�t�9�#D�E�F� 2r#c�x�[U[2%Cc[UO22oQU7cUO	Q2QU7cUOQ2QU7cUOQ2QU7cUOQ2QU7cUOQ2UQ	UQ
QO
UO2O2QP2oUO[O[OUQ222P![U[ 2%cAUO#UO22UO%UO22P![U[&2%cj[UO22oQU7cUO)Q
2QU7cUO)Q2QU7cUO)Q2UQ	UQ
P![U[*2%cj[UO22oQU7cUO-Q
2QU7cUO-Q2QU7cUO-Q2UQ	UQ
P![U[.2%cP![1Q[3U2*2g[[1cP!h9h)zACopy mbox- or MMDF-specific state to message insofar as possible.r2r�r5r6r1r0r4r3�statuszx-statusr�z%a %b %d %H:%M:%S %Yr�r8r9r�r�r:���)r�r	rPrIr*rZr�r&rr,�calendar�timegmr��strptimer��
OverflowErrorr%rQrrrarr;rr�r-)rr9rL�
maybe_dates&&  r r��_mboxMMDFMessage._explain_to�sH���g�~�.�.�����(�)�E��e�|��"�"�5�)��e�|�� � ��%��e�|�� � ��%��e�|�� � ��%��e�|�� � ��%���!��
�#����$�-�-�/�"7�"7�"9�"�#�">�?�J�
�� � �������z�6L�2N�"O�P���!1�
2�
2����d�n�n�.�/����T�]�]�_�-�
���
+�
+�����(�)�E��%���$�$�X�.��e�|��$�$�Y�/��e�|��$�$�Y�/���!��
�#�
���
.�
.�����(�)�E��%���!�!�(�+��e�|��!�!�)�,��e�|��!�!�*�-���!��
�#�
���
)�
)���B� ��M�*�+�
+��9�
�.�
��
�s�!:J$�$J9�4J9�8J9rBr%)r�r�r�r�r�rr!r&rrIrQrZr_r�r�r�r�s@r r%r%�s@����9�!(�	��(���A�7�,C�G�
1+�1+r#r%c��\sQsQsQsQsP!)r
i&z&Message with mbox-specific properties.rn�r�r�r�r�r�r�rnr#r r
r
&���0r#c�T`�\sQsQsnQsQ,sQQksQsQsQs	Qs
Q	sQ
sUs
P!)ri*z$Message with MH-specific properties.�
_sequencesc�@�,Um[OV2P!)z!Initialize an MHMessage instance.)rbrr!r8s&&r r!�MHMessage.__init__/s���������'r#c�*�UOQ*!)z4Return a list of sequences that include the message.�NNN�rbr's&r r`�MHMessage.get_sequences4s�����q�!�!r#c�(�[U2UmP!)z3Set the list of sequences that include the message.)rqrb)rr�s&&r r��MHMessage.set_sequences8s
���y�/��r#c���[U[2%c0VO7fUOOU2P!P![	Q[U2*2g)z8Add sequence to list of sequences including the message.zsequence type must be str: %s)r�r�rbr�r�r-�rr�s&&r ra�MHMessage.add_sequence<sG���h��$�$����.����&�&�x�0�/��;�d�8�n�L�M�Mr#c�d�UOOU2P![cP!h9h)zARemove sequence from the list of sequences including the message.)rbrAr�rls&&r �remove_sequence�MHMessage.remove_sequenceDs+��	��O�O�"�"�8�,���	��	��� �	/�/�/c��[U[2%c�[UO22oQU7cUO	Q2L"UO	Q2UOQ2QU7cUOQ2QU7cUOQ2P!P![U[2%cx[UO22oQU7cUOQ2LUOQ	2QU7cUOQ2QU7cUOQ
2P!P![U[2%c,UO2FDoUOU2J	P![U[2%cN[UO22oQU7cUOQ2QU7cUOQ2P!P![U[2%cP![Q[U2*2g)
z6Copy MH-specific state to message insofar as possible.r�r�r0r9r5r8r1�ROr2r6r�r:)r�r	rPr`r*rZr%rrarr;rr�r-)rr9r�r�s&&  r r��MHMessage._explain_toKs����g�~�.�.��D�.�.�0�1�I��9�$��"�"�5�)��"�"�5�)�� � ��%��I�%�� � ��%��I�%�� � ��%�&�
��!1�
2�
2��D�.�.�0�1�I��y�(�� � ��&�� � ��%��I�%�� � ��%��I�%�� � ��%�&�
���
+�
+� �.�.�0���$�$�X�.�1�
���
.�
.��D�.�.�0�1�I��9�$��!�!�(�+��I�%��!�!�*�-�&�
���
)�
)���B� ��M�*�+�
+r#rgr%)r�r�r�r�r�rr!r`r�raror�r�r�r�s@r rr*s4����.�!-���(�
"�*�N��$+�$+r#c�h`�\sQsQsnQsQQ,sQQksQsQsQs	Q	s
Q
sQsQs
Q
sQsUsP!)rirz'Message with Babyl-specific properties.r��_visiblec�^�,Um[2Um[OV2P!)z#Initialize a BabylMessage instance.)r�rrvr!r8s&&r r!�BabylMessage.__init__ws ������	��
�����'r#c�*�UOQ*!)z'Return a list of labels on the message.rf)r�r's&r r��BabylMessage.get_labels}s���|�|�A��r#c�(�[U2UmP!)z&Set the list of labels on the message.)rqr�)rr�s&&r r��BabylMessage.set_labels�s
���F�|��r#c���[U[2%c0VO7cUOOU2P!P![	Q[U2*2g)z+Add label to list of labels on the message.zlabel must be a string: %s)r�r�r�r�r�r-�rr�s&&r r;�BabylMessage.add_label�sG���e�S�!�!��L�L�(����#�#�E�*�)��8�4��;�F�G�Gr#c�d�UOOU2P![cP!h9h)z4Remove label from the list of labels on the message.)r�rAr�r~s&&r �remove_label�BabylMessage.remove_label�s+��	��L�L����&���	��	�rqc�.�[UO2!)z3Return a Message representation of visible headers.�rrvr's&r r��BabylMessage.get_visible�s���t�}�}�%�%r#c�(�[U2UmP!)z2Set the Message representation of visible headers.r�)r�visibles&&r r��BabylMessage.set_visible�s����(��
r#c�,�UOO2FD:oV7c%UOOVU*2J-UOUJ<	QFD2oV7fJVO7fJV*UOU$J4	P!)z9Update and/or sensibly generate a set of visible headers.)�Date�FromzReply-To�To�CC�Subject)rvrrrL)r�headers& r �update_visible�BabylMessage.update_visible�sl���m�m�(�(�*�F��~��
�
�,�,�V�&�\�B��M�M�&�)�	+�
J�F��~�&�
�
�"=�(,���
�
�f�%�Jr#c��[U[2%c�[UO22oQU7cUO	Q2L"UO	Q2UOQ2QU7fQU7cUOQ2QU7cUOQ2Q	U7cUOQ
2P!P![U[2%cx[UO22oQU7cUOQ2LUOQ2Q	U7cUOQ
2QU7cUOQ2P!P![U[2%cN[UO22oQU7cUOQ2QU7cUOQ2P!P![U[2%cKUOUO22UO2FDoUOU2J	P![U[2%cP![Q[U2*2g)z9Copy Babyl-specific state to message insofar as possible.r�r�r0r�r�r�r�r1r�r3rsr2r4r6r8r:)r�r	rPr�r*rZr%rrarr�r�r;rr�r-)rr9r�r�s&&  r r��BabylMessage._explain_to�s����g�~�.�.�����*�+�F��6�!��"�"�5�)��"�"�5�)�� � ��%��f�$��F�(:�� � ��%��V�#�� � ��%��F�"�� � ��%�#�
��!1�
2�
2�����*�+�F��v�%�� � ��&�� � ��%��F�"�� � ��%��V�#�� � ��%�$�
���
+�
+�����*�+�F��6�!��$�$�X�.��V�#��$�$�Y�/�$�
���
.�
.����� 0� 0� 2�3����*���!�!�%�(�+�
���
)�
)���B� ��M�*�+�
+r#)r�rvr%)r�r�r�r�r�rr!r�r�r;r�r�r�r�r�r�r�r�s@r rrrsF����1�!*�J� 7��(��$�H��&�)�	5�'+�'+r#c��\sQsQsQsQsP!)r
i�z&Message with MMDF-specific properties.rnr_rnr#r r
r
�r`r#c�`�\sQsQsnQsQQksQQksQQksQQksQQks	Qs
Q	sQQ
ksQs
QsQ
sQsQsQsQsQs\Q2sQsUsP!)r7i�zA read-only wrapper of a file.c�V�VmUeUO2UmP!V mP!)zInitialize a _ProxyFile.)r�r��_pos)rr/�poss&&&r r!�_ProxyFile.__init__�s���
��;�����D�I��Ir#c�N�UOVOO2!�zRead bytes.)�_readr�r��r�sizes&&r r��_ProxyFile.read�s���z�z�$�
�
���0�0r#c�N�UOVOO2!r�)r�r��read1r�s&&r r��_ProxyFile.read1�s���z�z�$�
�
� 0� 0�1�1r#c�N�UOVOO2!)zRead a line.)r�r�r�r�s&&r r��_ProxyFile.readline�s���z�z�$�
�
� 3� 3�4�4r#c��,oSFD7oUOU2UeJU[U2*oU]6:fJ5U!	U!)zRead multiple lines.)r�rj)r�sizehintr�r�s&&  r �	readlines�_ProxyFile.readlines�sG�����D��M�M�$���#��C��I�%���q�=���
�
��
r#c#�N �UO29o%cUw�	JP!3h)zIterate over lines.)r�)rr�s& r rz�_ProxyFile.__iter__�s ����m�m�o�%�d�%��J�&�s�%�	%c��UO!)zReturn the position.)r�r's&r r��_ProxyFile.tell�s���y�y�r#c���U]6Xc&UOOUO2UOOV2UOO2UmP!)zChange position.�r�r�r�r��r�offset�whences&&&r r��_ProxyFile.seeks?���Q�;��J�J�O�O�D�I�I�&��
�
����'��J�J�O�O�%��	r#c��[UQ2%c<[UOQ2%cUOO2U;P!P!S;h9h)zClose the file.r�r,)r�r�r,r's&r r,�_ProxyFile.closesH���4��!�!�
��4�:�:�w�/�/��J�J�$�$�&��J�"��
�J�s�A�A�Ac��UePoUOOUO2UU2oUOO2UmU!)z"Read size bytes using read_method.r�)rr��read_methodr�s&&& r r��_ProxyFile._readsA���<��D��
�
����	�	�"��T�"���J�J�O�O�%��	��
r#c��U!)z$Context management protocol support.rnr's&r r(�_ProxyFile.__enter__s���r#c�(�UO2P!r%r+)r�excs&*r r0�_ProxyFile.__exit__r2r#c�8�UOO2!r%)r��readabler's&r r��_ProxyFile.readable ����z�z�"�"�$�$r#c�8�UOO2!r%)r��writabler's&r r��_ProxyFile.writable#r�r#c�8�UOO2!r%)r��seekabler's&r r��_ProxyFile.seekable&r�r#c�8�UOO2!r%)r�r�r's&r r��_ProxyFile.flush)s���z�z���!�!r#c��[UQ2%fP	![UOQ2%fP
!UOO!)r�rX)r�r�rXr's&r rX�_ProxyFile.closed,s6���t�W�%�%���t�z�z�8�,�,���z�z� � � r#)r�r�r%��)r�r�r�r�r�r!r�r�r�r�rzr�r�r,r�r(r0r�r�r�r��propertyrXr�r�r�s@r r7r7�sl����(��1�2�5�	��
�&�����%�%�%�"��!��!r#r7c�L`�\sQsQsnQsQ	QksQsQ
QksQsQs	Qs
UsP!)r!i5z&A read-only wrapper of part of a file.c�L�[OVU2V mV0mP!)zInitialize a _PartialFile.)r7r!�_start�_stop)rr/r�r�s&&&&r r!�_PartialFile.__init__8s�����D�U�+����
r#c�P�[OU2UO*
!)z*Return the position with respect to start.)r7r�r�r's&r r��_PartialFile.tell>s�����t�$�t�{�{�2�2r#c��U]6XcUOUm]oLU]6XcUOUm]o[O	VU2P!)z8Change position, possibly with respect to start or stop.)r�r�r�r7r�r�s&&&r r��_PartialFile.seekBs>���Q�;����D�I��F�
�q�[��
�
�D�I��F�����f�-r#c��UOUO*
oU]6:cQ!UdU]6fV6�cSo[OVU2!)z;Read size bytes using read_method, honoring start and stop.r#)r�r�r7r�)rr�r��	remainings&&& r r��_PartialFile._readLsF���J�J����*�	���>���<�4�!�8�t�'7��D�����K�8�8r#c�4�[UQ2%cU;P!P!)r�)r�r�r's&r r,�_PartialFile.closeUs���4��!�!��
�"r#)r�r�r�)NNr�)r�r�r�r�r�r!r�r�r�r,r�r�r�s@r r!r!5s&����0��3�.�9��r#r!c��P
o[%c<[OU[O[O*2U%c�[UOQ*2oUO2[OUOUOQ*2P	o[OUO2P!P![caoSO
[
O[
O[
O17c[QSO*2ggPo=hh9h[c<oSO
[
O[
O17cPo=P!gPo=hh9h[ ["1c9[O$SOSOQ*2P	oP!h9h[&c>[O(SO2[QSO*2gh9h[%c&[OS[O*2S%c([O(SOQ*2g9h)z(Lock file f using lockf and dot locking.zlockf: lock unavailable: %s�.lockzdot lock unavailable: %s)�fcntl�lockf�LOCK_EX�LOCK_NBr
r�EAGAINr�r�rr�r�r,rr	r�r
rrr�rA�LOCK_UN)r/r��dotlock_doner�pre_locks&&   r r�r�\s����L�%��5�
����A�u�}�}�u�}�}�<�=��
�,�Q�V�V�g�-=�>����� �
1�-��G�G�H�M�M�1�6�6�G�+;�<�#'�L�
�I�I�h�m�m�,�#��
�
��7�7�u�|�|�U�\�\�5�;�;�G�G�,�-J�-.�V�V�.4�5�5���
���
��7�7�u�|�|�U�[�[�9�9����	
��'��8�(��I�I�h�m�m�Q�V�V�g�-=�>�#'�L�(��
#�
1��	�	�(�-�-�(�(�)C�)*���*0�1�1�
1����5��K�K��5�=�=�)���I�I�a�f�f�w�&�'�
�s��H)�:C�H)�,E	�4F�7 G�	E�%E�&=E�$E�E�H)�		F�F�.F
�H)�	F
�
F�H)�G�"5G�G�G�G�	H&�(>H&�&H)�)
J�7,J�$(Jc�(�[%c&[OU[O2[OOUOQ*2%c*[OUOQ*2P!P!)z*Unlock file f using lockf and dot locking.r�)r�r�r�rrr�r�rA�r/s&r r�r��sO���u�
���A�u�}�}�%�	�w�w�~�~�a�f�f�w�&�'�'�
�	�	�!�&�&�7�"�#�(r#c��[UQ2!)zCCreate a file if it doesn't exist and open for reading and writing.zxb+)r)�rs&r r�r��s����e��r#c
��[U8Q[[O228Q[O28Q[
O2802!)zBCreate a temp file based on path and open for reading and writing.r|)r�r�r�r�r�rr�r�s&r r�r��s8���d�C��	�	��4D�.4�.@�.@�.B�.0�i�i�k�;�<�<r#c��UO2[[Q2%c'[OUO	22P!P!)z0Ensure changes to file f are physically on disk.�fsync)r�r�rr��filenor�s&r r�r��s/���G�G�I��r�7���
��������r#c�>�[U2UO2P!)z:Close file f, ensuring all changes are physically on disk.)r�r,r�s&r rr�s����N��G�G�Ir#c��\sQsQsQsQsP!)ri�z"Raised for module-specific errors.rnr_rnr#r rr�s��,r#c��\sQsQsQsQsP!)ri�z:The specified mailbox does not exist and won't be created.rnr_rnr#r rr�s��Dr#c��\sQsQsQsQsP!)ri�z>The specified mailbox is not empty and deletion was requested.rnr_rnr#r rr�s��Hr#c��\sQsQsQsQsP!)ri�z)Another process caused an action to fail.rnr_rnr#r rr����3r#c��\sQsQsQsQsP!)ri�z)A file appears to have an invalid format.rnr_rnr#r rr�r�r#)rrrrrrrr	r
rrr
rrrrr)T)2r�rr�rXr�rr�r�ra�
email.message�email.generatorr�rW�typesrr��ImportError�__all__r�r�rrr�rrrrrr9rr	r%r
rrr
r7r!r�r�r�r�r�r�	Exceptionrrrrrrnr#r �<module>r�s���J�
���
�������	�����A��

�*�*�
�
�G�
$��m2�m2�`g�g�g�TC��C�N@�"�@�F1.�9�1.�h*.�9�*.�Z@*��@*�F
v��v�r"@�e�m�m�#�#�"@�Jj+�W�j+�Zn+�w�n+�b1�"�1�E+��E+�P\+�7�\+�~1�"�1�]!�]!�@$�:�$�N(�T$��<���-�I�-�E��E�I�E�I�4��4�4�%�4��oD���E��s�E8�8F�>F�F

Youez - 2016 - github.com/yon3zu
LinuXploit