AlkantarClanX12
Current Path : /proc/self/root/usr/lib64/python3.6/__pycache__/ |
Current File : //proc/self/root/usr/lib64/python3.6/__pycache__/imaplib.cpython-36.opt-1.pyc |
3 \/� � 2 @ s� d Z dZddlZddlZddlZddlZddlZddlZddlZddl Z ddl Z ddlmZmZm Z ddlmZ yddlZdZW n ek r� dZY nX dd d ddd gZdZdZdZdZdgZdZdhdidjdkdldmdndodpdqdrdsdtdudvdwdxdydzd{d|d}d~dd�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�d�)Zejd�Zejd�Zejd�Zejdej�Z ejd�Z!ejd�Z"ejd�Z#ejdej�Z$dZ%dZ&G d d� d�Z'e�r�G d!d"� d"e'�Z(ej)d"� G d#d � d e'�Z*G d$d%� d%�Z+d&j,d'�Z-d(d)� e.e-d*d� �D �Z/d+d � Z0d,d� Z1d-d� Z2d.d � Z3e4d/k�r�ddl5Z5ddl6Z6ye5j5ej7d*d� d0�\Z8Z9W n0 e5j:k �rr Z; zf f Z8Z9W Y ddZ;[;X nX dZ<x@e8D ]8\Z=Z;e=d1k�r�e>e;�Zne=d2k�r~e;Z<e9�s~e<fZ9�q~W e9�s�d�Z9e9d Z?e6j@� ZAe6j6d4eAe?�p�d5f �ZBd6eAd7d8� ZCd9eAeBffd�d�d�d@d?ddeCffd�d�d�d�d�dNf fdOf fdPf fdQf ffZDdDf fd�d�d�d@dddeCffdPf fdXf ffZEdYdZ� ZF�y&e<�r�e*e<�ZGne'e?�ZGeGjHdk�r�eDd*d� ZDeGjId[eGjJ � eGjId\eGjKf � xeDD ]\ZLZ9eFeLe9� �q�W xJeFdAd��D ]<ZMejNd_eM�ZOeO�reOjPd*�ZQneMj,� d� ZQeFd`eQf� �q�W x\eED ]T\ZLZ9eFeLe9�ZReLe9fd�k�rZ�q6eRd� j,� ZSeS�sp�q6eFdTdadbeSd� dcf� �q6W eTdd� W n. eTde� e�s�eTdfej7d � � Y nX dS )�z�IMAP4 client. Based on RFC 2060. Public class: IMAP4 Public variable: Debug Public functions: Internaldate2tuple Int2AP ParseFlags Time2Internaldate z2.58� N)�datetime�timezone� timedelta)�DEFAULT_BUFFER_SIZETF�IMAP4�IMAP4_stream�Internaldate2tuple�Int2AP� ParseFlags�Time2Internaldates � i� � IMAP4REV1i@B �AUTH�SELECTED�NONAUTH�LOGOUT))�APPEND�AUTHENTICATE� CAPABILITY�CHECK�CLOSE�COPY�CREATE�DELETE� DELETEACL�ENABLE�EXAMINE�EXPUNGE�FETCH�GETACL� GETANNOTATION�GETQUOTA�GETQUOTAROOT�MYRIGHTS�LIST�LOGINr �LSUBZMOVE� NAMESPACE�NOOP�PARTIAL� PROXYAUTH�RENAME�SEARCH�SELECT�SETACL� SETANNOTATION�SETQUOTA�SORT�STARTTLS�STATUS�STORE� SUBSCRIBE�THREAD�UID�UNSUBSCRIBEs \+( (?P<data>.*))?s .*FLAGS \((?P<flags>[^\)]*)\)s� .*INTERNALDATE "(?P<day>[ 0123][0-9])-(?P<mon>[A-Z][a-z][a-z])-(?P<year>[0-9][0-9][0-9][0-9]) (?P<hour>[0-9][0-9]):(?P<min>[0-9][0-9]):(?P<sec>[0-9][0-9]) (?P<zonen>[-+])(?P<zoneh>[0-9][0-9])(?P<zonem>[0-9][0-9])"s .*{(?P<size>\d+)}$s \r\n|\r|\ns% \[(?P<type>[A-Z-]+)( (?P<data>.*))?\]s$ \* (?P<type>[A-Z-]+)( (?P<data>.*))?s3 \* (?P<data>\d+) (?P<type>[A-Z-]+)( (?P<data2>.*))?c @ s� e Zd ZdZG dd� de�ZG dd� de�ZG dd� de�Zdefd d �Z dd� Z d d� Zdd� Zdd� Z dd� Zdd� Zdd� Zdefdd�Zdd� Zdd� Zdd � Zd!d"� Zd#d$� Zd%d&� Zd'd(� Zd)d*� Zd+d,� Zd-d.� Zd/d0� Zd1d2� Zd3d4� Zd5d6� Zd7d8� Z d9d:� Z!d;d<� Z"d=d>� Z#d?d@� Z$dAdB� Z%dCdD� Z&dEdF� Z'dGdH� Z(d�dKdL�Z)dMdN� Z*dOdP� Z+dQdR� Z,dSdT� Z-d�dUdV�Z.dWdX� Z/dYdZ� Z0d[d\� Z1d]d^� Z2d_d`� Z3dadb� Z4dcdd� Z5d�dgdh�Z6didj� Z7dkdl� Z8dmdn� Z9dodp� Z:d�drds�Z;dtdu� Z<dvdw� Z=dxdy� Z>dzd{� Z?d|d}� Z@d~d� ZAd�d�� ZBd�d�� ZCd�d�� ZDd�d�� ZEd�d�� ZFd�d�� ZGd�d�� ZHd�d�� ZId�d�� ZJd�d�� ZKd�d�� ZLd�d�� ZMd�d�� ZNd�d�� ZOdqS )�r a� IMAP4 client class. Instantiate with: IMAP4([host[, port]]) host - host's name (default: localhost); port - port number (default: standard IMAP4 port). All IMAP4rev1 commands are supported by methods of the same name (in lower-case). All arguments to commands are converted to strings, except for AUTHENTICATE, and the last argument to APPEND which is passed as an IMAP4 literal. If necessary (the string contains any non-printing characters or white-space and isn't enclosed with either parentheses or double quotes) each string is quoted. However, the 'password' argument to the LOGIN command is always quoted. If you want to avoid having an argument string quoted (eg: the 'flags' argument to STORE) then enclose the string in parentheses (eg: "(\Deleted)"). Each command returns a tuple: (type, [data, ...]) where 'type' is usually 'OK' or 'NO', and 'data' is either the text from the tagged response, or untagged results from command. Each 'data' is either a string, or a tuple. If a tuple, then the first part is the header of the response, and the second part contains the data (ie: 'literal' value). Errors raise the exception class <instance>.error("<reason>"). IMAP4 server errors raise <instance>.abort("<reason>"), which is a sub-class of 'error'. Mailbox status changes from READ-WRITE to READ-ONLY raise the exception class <instance>.readonly("<reason>"), which is a sub-class of 'abort'. "error" exceptions imply a program error. "abort" exceptions imply the connection should be reset, and the command re-tried. "readonly" exceptions imply the command should be re-tried. Note: to use this module, you must read the RFCs pertaining to the IMAP4 protocol, as the semantics of the arguments to each IMAP4 command are left to the invoker, not to mention the results. Also, most IMAP servers implement a sub-set of the commands available here. c @ s e Zd ZdS )zIMAP4.errorN)�__name__� __module__�__qualname__� r<