403Webshell
Server IP : 23.254.227.96  /  Your IP : 216.73.216.46
Web Server : Apache/2.4.62 (Unix) OpenSSL/1.1.1k
System : Linux hwsrv-1277026.hostwindsdns.com 4.18.0-477.13.1.el8_8.x86_64 #1 SMP Tue May 30 14:53:41 EDT 2023 x86_64
User : viralblo ( 1001)
PHP Version : 8.1.31
Disable Function : NONE
MySQL : OFF  |  cURL : ON  |  WGET : ON  |  Perl : ON  |  Python : OFF  |  Sudo : ON  |  Pkexec : ON
Directory :  /lib/python3.6/site-packages/authres/__pycache__/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ Back ]     

Current File : /lib/python3.6/site-packages/authres/__pycache__/__init__.cpython-36.pyc
3

��E]3"�@s�dZdZdZdZdZddlZddlTGdd	�d	e�Zda	d
d�Z
dadd
�ZGdd�dej
j�Zddd�Zddd�Zdd�Zdd�ZdS)aT
Package for parsing ``Authentication-Results`` headers as defined in RFC
5451/7001/7601/8601.  Optional support for authentication methods defined in
RFCs 5617, 6008, 6212, 7281, and 8617.

Examples:
RFC 5451 B.2
>>> str(AuthenticationResultsHeader('test.example.org'))
'Authentication-Results: test.example.org; none'

RFC 5451 B.3
>>> str(AuthenticationResultsHeader(authserv_id = 'example.com',
... results = [SPFAuthenticationResult(result = 'pass',
... smtp_mailfrom = 'example.net')]))
'Authentication-Results: example.com; spf=pass smtp.mailfrom=example.net'

RFC 5451 B.4(1)
>>> str(AuthenticationResultsHeader(authserv_id = 'example.com',
... results = [SMTPAUTHAuthenticationResult(result = 'pass', result_comment = 'cram-md5',
... smtp_auth = 'sender@example.net'), SPFAuthenticationResult(result = 'pass',
... smtp_mailfrom = 'example.net')]))
'Authentication-Results: example.com; auth=pass (cram-md5) smtp.auth=sender@example.net; spf=pass smtp.mailfrom=example.net'

RFC 5451 B.4(2)
>>> str(AuthenticationResultsHeader(authserv_id = 'example.com',
... results = [SenderIDAuthenticationResult(result = 'pass',
... header_from = 'example.com')]))
'Authentication-Results: example.com; sender-id=pass header.from=example.com'

RFC 5451 B.5(1) # Note: RFC 5451 uses 'hardfail' instead of 'fail' for
SPF failures. Hardfail is deprecated.  See RFC 6577.
Examples here use the correct 'fail'. The authres module does not
validate result codes, so either will be processed.

>>> str(AuthenticationResultsHeader(authserv_id = 'example.com',
... results = [SenderIDAuthenticationResult(result = 'fail',
... header_from = 'example.com'), DKIMAuthenticationResult(result = 'pass',
... header_i = 'sender@example.com', result_comment = 'good signature')]))
'Authentication-Results: example.com; sender-id=fail header.from=example.com; dkim=pass (good signature) header.i=sender@example.com'

# Missing parsing header comment.
#FIXME
>>> arobj = AuthenticationResultsHeader.parse('Authentication-Results: example.com; sender-id=fail header.from=example.com; dkim=pass (good signature) header.i=sender@example.com')
>>> str(arobj.authserv_id)
'example.com'
>>> str(arobj.results[0])
'sender-id=fail header.from=example.com'
>>> str(arobj.results[0].method)
'sender-id'
>>> str(arobj.results[0].result)
'fail'
>>> str(arobj.results[0].header_from)
'example.com'
>>> str(arobj.results[0].properties[0].type)
'header'
>>> str(arobj.results[0].properties[0].name)
'from'
>>> str(arobj.results[0].properties[0].value)
'example.com'
>>> str(arobj.results[1])
'dkim=pass header.i=sender@example.com'
>>> str(arobj.results[1].method)
'dkim'
>>> str(arobj.results[1].result)
'pass'
>>> str(arobj.results[1].header_i)
'sender@example.com'
>>> str(arobj.results[1].properties[0].type)
'header'
>>> str(arobj.results[1].properties[0].name)
'i'
>>> str(arobj.results[1].properties[0].value)
'sender@example.com'
�authreszJulian Mehnle, Scott Kittermanzjulian@mehnle.netz1.2.0�N)�*c@s<eZdZdZdd�Zdd�Zdd�Zd
d	d
�Zddd�ZdS)�FeatureContextu@
    Class representing a "feature context" for the ``authres`` package.
    A feature context is a collection of extension modules that may override
    the core AuthenticationResultsHeader class or result classes, or provide
    additional result classes for new authentication methods.

    To instantiate a feature context, import the desired ``authres.…`` extension
    modules and pass them to ``FeatureContext()``.

    A ``FeatureContext`` object provides ``parse``, ``parse_value``, ``header``,
    and ``result`` methods specific to the context's feature set.
    cGs�tjj|_i|_tjgt|�}xd|D]\}y|j|_Wntk
rJYnXy x|jD]}||j|j<qVWWq&tk
r�Yq&Xq&WdS)N)	r�core�AuthenticationResultsHeader�header_class�result_class_by_auth_method�list�AttributeErrorZRESULT_CLASSESZMETHOD)�self�modules�moduleZresult_class�r�/usr/lib/python3.6/__init__.py�__init__ys

zFeatureContext.__init__cCs|jj||�S)N)r�parse)r�stringrrrr�szFeatureContext.parsecCs|jj||�S)N)r�parse_value)rrrrrr�szFeatureContext.parse_valueNcCs|j||||||�S)N)r)r�authserv_id�authserv_id_comment�version�version_comment�resultsrrr�header�szFeatureContext.headercCsFy|j|||||||�Stk
r@tjj|||||||�SXdS)N)r�KeyErrorrrZAuthenticationResult)r�methodr�result�result_comment�reason�reason_comment�
propertiesrrrr�s

zFeatureContext.result)NNNNN)NNNNNN)	�__name__�
__module__�__qualname__�__doc__rrrrrrrrrrks
rcCsts
t�atS)zFReturns default feature context providing only RFC 5451 core features.)�_core_featuresrrrrr�
core_features�sr&cCsbts^ddl}ddl}ddl}ddl}ddl}ddl}ddl}t|j	|j
|j|j|j
|j|j�atS)zj
    Returns default feature context providing all features shipped with the
    ``authres`` package.
    rN)�
_all_featuresZauthres.dkim_bZauthres.dkim_adspZauthres.vbrZ
authres.dmarcZ
authres.smimeZauthres.rrvsZauthres.arcrZdkim_bZ	dkim_adspZvbrZdmarcZsmimeZrrvsZarc)rrrr�all_features�s"r(c@s.eZdZedd��Zedd��Zddd�ZdS)	rcCstjjjt�|�S)N)rrrrr&)rrrrrr�sz!AuthenticationResultsHeader.parsecCstjjjt�|�S)N)rrrrr&)rrrrrr�sz'AuthenticationResultsHeader.parse_valueNcCs tjjj|t�|||||�dS)N)rrrrr&)rrrrrrrrrr�s
z$AuthenticationResultsHeader.__init__)NNNNN)r!r"r#�classmethodrrrrrrrr�s
rcCst�j|||||||�S)N)r&r)rrrrrrr rrrr�s
rcCst�j|||||�S)N)r&r)rrrrrrrrr�srcCst�j|�S)N)r&r)rrrrr�srcCst�j|�S)N)r&r)rrrrr�sr)NNNNNN)NNNNN)r$ZMODULE�
__author__Z	__email__�__version__Zauthres.corer�objectrr%r&r'r(rrrrrrrrrr�<module>[s*;



Youez - 2016 - github.com/yon3zu
LinuXploit