Spade
Mini Shell
| Directory:~$ /lib/python2.7/site-packages/requests_toolbelt/adapters/ |
| [Home] [System Details] [Kill Me] |
�
ӵ Yc@s@dZddlmZddlmZdefd��YZdS(s�Submodule
containing the implementation for the FingerprintAdapter.
This file contains an implementation of a Transport Adapter that validates
the fingerprints of SSL certificates presented upon connection.
i����(tHTTPAdapteri(tpoolmanagertFingerprintAdaptercBs3eZdZejdgZd�Zed�ZRS(s>
A HTTPS Adapter for Python Requests that verifies certificate
fingerprints,
instead of certificate hostnames.
Example usage:
.. code-block:: python
import requests
import ssl
from requests_toolbelt.adapters.fingerprint import
FingerprintAdapter
twitter_fingerprint = '...'
s = requests.Session()
s.mount(
'https://twitter.com',
FingerprintAdapter(twitter_fingerprint)
)
The fingerprint should be provided as a hexadecimal string, optionally
containing colons.
tfingerprintcKs#||_tt|�j|�dS(N(RtsuperRt__init__(tselfRtkwargs((sJ/usr/lib/python2.7/site-packages/requests_toolbelt/adapters/fingerprint.pyR&s c Cs.tjd|d|d|d|j�|_dS(Nt num_poolstmaxsizetblocktassert_fingerprint(RtPoolManagerR(RtconnectionsR R
((sJ/usr/lib/python2.7/site-packages/requests_toolbelt/adapters/fingerprint.pytinit_poolmanager+s
(t__name__t
__module__t__doc__Rt __attrs__RtFalseR(((sJ/usr/lib/python2.7/site-packages/requests_toolbelt/adapters/fingerprint.pyRs N(Rtrequests.adaptersRt_compatRR(((sJ/usr/lib/python2.7/site-packages/requests_toolbelt/adapters/fingerprint.pyt<module>s