MCPcopy Create free account

hub / github.com/urllib3/urllib3 / functions

Functions1,476 in github.com/urllib3/urllib3

↓ 4 callersFunctionensure_can_construct_http_header_dict
( potential: object, )
src/urllib3/_collections.py:45
↓ 4 callersFunctionextract_from_urllib3
Undo monkey-patching by :func:`inject_into_urllib3`.
src/urllib3/contrib/pyopenssl.py:150
↓ 4 callersMethodfileno
(self)
src/urllib3/response.py:1092
↓ 4 callersFunctionfind_unused_port
Returns an unused port that should be suitable for binding. This is achieved by creating a temporary socket with the same family and type as
test/port_helpers.py:14
↓ 4 callersFunctioninject_into_urllib3
Monkey-patch urllib3 with PyOpenSSL-backed SSL-support.
src/urllib3/contrib/pyopenssl.py:139
↓ 4 callersMethodkeys
(self)
src/urllib3/_collections.py:16
↓ 4 callersFunctionmatch_hostname
Verify that *cert* (in decoded format as returned by SSLSocket.getpeercert()) matches the *hostname*. RFC 2818 and RFC 6125 rules are followe
src/urllib3/util/ssl_match_hostname.py:95
↓ 4 callersMethodread
( self, amt: int | None = None, decode_content: bool | None = None, # ignored because
src/urllib3/contrib/emscripten/response.py:139
↓ 4 callersMethodrender_headers
Renders the headers for this request field.
src/urllib3/fields.py:291
↓ 4 callersMethodrequest_encode_body
Make a request using :meth:`urlopen` with the ``fields`` encoded in the body. This is useful for request methods like POST, PUT, PATC
src/urllib3/_request_methods.py:185
↓ 4 callersFunctionrun_server_and_proxy_in_thread
( proxy_scheme: str, proxy_host: str, tmpdir: Path, ca: trustme.CA, proxy_cert: trustme.Le
test/conftest.py:94
↓ 4 callersFunctionsample_response
(binary: typing.Literal[True] = ...)
test/test_ssltransport.py:63
↓ 4 callersMethodseek
(self, offset: int, whence: int = 0)
test/test_util.py:620
↓ 4 callersMethodsetdefault
(self, key: str, default: str = "")
src/urllib3/_collections.py:271
↓ 4 callersMethodstart_parsing_handler
(self)
test/with_dummyserver/test_socketlevel.py:1745
↓ 4 callersFunctiontests_impl
( session: nox.Session, extras: str = "socks,brotli,zstd,h2", # hypercorn dependency h2 compares b
noxfile.py:14
↓ 3 callersMethod_decode
Decode the data passed in and potentially flush the decoder.
src/urllib3/response.py:465
↓ 3 callersFunction_dnsname_to_stdlib
Converts a dNSName SubjectAlternativeName field to the form used by the standard library on the given Python version. Cryptography produ
src/urllib3/contrib/pyopenssl.py:185
↓ 3 callersMethod_init_decoder
Set-up the _decoder attribute if necessary.
src/urllib3/response.py:446
↓ 3 callersMethod_proxy_requires_url_absolute_form
Indicates if the proxy requires the complete destination URL in the request. Normally this is only needed when not using an HTTP CON
src/urllib3/poolmanager.py:396
↓ 3 callersMethod_raise_timeout
Is the error actually a timeout? Will raise a ReadTimeout or pass
src/urllib3/connectionpool.py:360
↓ 3 callersFunction_read_exactly
Read *exactly* ``amt`` bytes from the socket ``sock``.
test/contrib/test_socks.py:50
↓ 3 callersMethod_set_ctx_options
(self)
src/urllib3/contrib/pyopenssl.py:515
↓ 3 callersFunction_set_up_fake_getaddrinfo
(monkeypatch: pytest.MonkeyPatch)
test/contrib/test_socks.py:97
↓ 3 callersMethod_test_broken_header_parsing
( self, headers: list[bytes], unparsed_data_check: str | None = None )
test/with_dummyserver/test_socketlevel.py:1938
↓ 3 callersFunction_wrap_proxy_error
(err: Exception, proxy_scheme: str | None)
src/urllib3/connection.py:882
↓ 3 callersMethod_wrap_ssl_read
(self, len: int, buffer: bytearray | None = None)
src/urllib3/util/ssltransport.py:214
↓ 3 callersFunctionallowed_gai_family
This function is designed to work in the context of getaddrinfo, where family=socket.AF_UNSPEC is the default and will perform a DNS search fo
src/urllib3/util/connection.py:103
↓ 3 callersFunctionassert_header_parsing
Asserts whether all headers have been successfully parsed. Extracts encountered errors from the result of parsing headers. Only works on
src/urllib3/util/response.py:40
↓ 3 callersMethodclose
(self)
src/urllib3/contrib/emscripten/response.py:234
↓ 3 callersMethodclose
(self)
src/urllib3/util/ssltransport.py:171
↓ 3 callersFunctioncreate_urllib3_context
Creates and configures an :class:`ssl.SSLContext` instance for use with urllib3. :param ssl_version: The desired protocol version to use.
src/urllib3/util/ssl_.py:216
↓ 3 callersMethoddispose_func
(arg: int)
test/test_collections.py:108
↓ 3 callersFunctionformat_multipart_header_param
Format and quote a single multipart header parameter. This follows the `WHATWG HTML Standard`_ as of 2021/06/10, matching the behavior o
src/urllib3/fields.py:79
↓ 3 callersMethodfrom_tuples
A :class:`~urllib3.fields.RequestField` factory from old-style tuple parameters. Supports constructing :class:`~urllib3.fields.Reque
src/urllib3/fields.py:200
↓ 3 callersMethodget_redirect_location
(self)
src/urllib3/http2.py:211
↓ 3 callersMethodgetpeercert
( self, binary_form: typing.Literal[False] = ... )
src/urllib3/util/ssltransport.py:175
↓ 3 callersFunctionis_in_browser_main_thread
()
src/urllib3/contrib/emscripten/fetch.py:292
↓ 3 callersMethodis_retry
Is this method/status code retryable? (Based on allowlists and control variables such as the number of total retries to allow, whether to
src/urllib3/util/retry.py:387
↓ 3 callersMethoditeritems
Iterate over all header lines, including duplicate ones.
src/urllib3/_collections.py:435
↓ 3 callersMethodmake_multipart
Makes this request field into a multipart request field. This method overrides "Content-Disposition", "Content-Type" and "Co
src/urllib3/fields.py:310
↓ 3 callersMethodparse_retry_after
(self, retry_after: str)
src/urllib3/util/retry.py:308
↓ 3 callersMethodpop_current_chunk
(self, amt: int = -1, till_crlf: bool = False)
test/test_response.py:1592
↓ 3 callersMethodread
(self, len: int = 1024, buffer: typing.Any | None = None)
src/urllib3/util/ssltransport.py:81
↓ 3 callersMethodread1
(self, amt: int = -1)
test/test_response.py:1628
↓ 3 callersMethodresolve_default_timeout
(timeout: _TYPE_TIMEOUT)
src/urllib3/util/timeout.py:127
↓ 3 callersFunctionresolve_ssl_version
like resolve_cert_reqs
src/urllib3/util/ssl_.py:200
↓ 3 callersMethodsend
(self, request: EmscriptenRequest)
src/urllib3/contrib/emscripten/fetch.py:218
↓ 3 callersFunctionserver_client_ssl_contexts
()
test/test_ssltransport.py:22
↓ 3 callersMethodset_alpn_protocols
(self, protocols: list[bytes | str])
src/urllib3/contrib/pyopenssl.py:480
↓ 3 callersMethodstart_connect
Start the timeout clock, used during a connect() attempt :raises urllib3.exceptions.TimeoutStateError: if you attempt to start a
src/urllib3/util/timeout.py:202
↓ 3 callersFunctionto_bytes
( x: str | bytes, encoding: str | None = None, errors: str | None = None )
src/urllib3/util/util.py:7
↓ 3 callersFunctionvalidate_request
( provided_request: bytearray, binary: typing.Literal[False, True] = True )
test/test_ssltransport.py:54
↓ 3 callersFunctionwait_for_socket
(ready_event: Event)
test/with_dummyserver/test_connectionpool.py:39
↓ 2 callersMethod__init__
(self, obj: T)
src/urllib3/http2.py:34
↓ 2 callersMethod__init__
(self, host: str, port: int | None = None)
src/urllib3/connectionpool.py:81
↓ 2 callersMethod_copy_from
(self, other: HTTPHeaderDict)
src/urllib3/_collections.py:425
↓ 2 callersFunction_dnsname_match
Matching according to RFC 6125, section 6.4.3 http://tools.ietf.org/html/rfc6125#section-6.4.3
src/urllib3/util/ssl_match_hostname.py:24
↓ 2 callersMethod_error_catcher
Catch low-level python exceptions, instead re-raising urllib3 variants, so that low-level exceptions are not leaked in the hi
src/urllib3/response.py:736
↓ 2 callersMethod_flush_decoder
Flushes the decoder. Should only be called if the decoder is actually being used.
src/urllib3/response.py:495
↓ 2 callersFunction_get_coverage_filename
(prefix: str)
test/contrib/emscripten/conftest.py:23
↓ 2 callersFunction_get_decoder
(mode: str)
src/urllib3/response.py:209
↓ 2 callersMethod_get_proxy_fingerprint_md5
(ca_path: str)
test/with_dummyserver/test_proxy_poolmanager.py:730
↓ 2 callersMethod_get_socket_mark
(cls, sock: socket.socket, server: bool)
dummyserver/testcase.py:385
↓ 2 callersMethod_get_timeout
Helper that always returns a :class:`urllib3.util.Timeout`
src/urllib3/connectionpool.py:348
↓ 2 callersFunction_have_working_poll
()
src/urllib3/util/wait.py:82
↓ 2 callersMethod_init_length
Set initial length value for Response content if available.
src/urllib3/response.py:679
↓ 2 callersFunction_is_has_never_check_common_name_reliable
( openssl_version: str, openssl_version_number: int, implementation_name: str, version_info: _
src/urllib3/util/ssl_.py:57
↓ 2 callersMethod_is_method_retryable
Checks if a given HTTP method should be retried upon, depending if it is included in the allowed_methods
src/urllib3/util/retry.py:379
↓ 2 callersMethod_new_conn
Return a fresh :class:`HTTPConnection`.
src/urllib3/connectionpool.py:238
↓ 2 callersMethod_new_h2_conn
(self)
src/urllib3/http2.py:64
↓ 2 callersMethod_new_pool
Create a new :class:`urllib3.connectionpool.ConnectionPool` based on host, port, scheme, and any additional pool keyword arguments.
src/urllib3/poolmanager.py:229
↓ 2 callersFunction_normalize_host
(host: None, scheme: str | None)
src/urllib3/connectionpool.py:1140
↓ 2 callersMethod_prepare_for_method_change
Remove content-specific header fields before changing the request method to GET or HEAD according to RFC 9110, Section 15.4.
src/urllib3/_collections.py:396
↓ 2 callersMethod_raw_read
Reads `amt` of bytes from the socket.
src/urllib3/response.py:858
↓ 2 callersMethod_render_parts
Helper function to format and quote a single header. Useful for single headers that are composed of multiple items. E.g., 'C
src/urllib3/fields.py:260
↓ 2 callersMethod_request_without_resource_warnings
( self, method: str, url: str )
test/with_dummyserver/test_https.py:717
↓ 2 callersMethod_set_proxy_headers
Sets headers needed by proxies: specifically, the Accept and Host headers. Only sets headers not provided by the user.
src/urllib3/poolmanager.py:604
↓ 2 callersFunction_ssl_wrap_socket_and_match_hostname
Logic for constructing an SSLContext from all TLS parameters, passing that down into ssl_wrap_socket, and then doing certificate verification
src/urllib3/connection.py:731
↓ 2 callersMethod_test_okay_header_parsing
(self, header: bytes)
test/with_dummyserver/test_socketlevel.py:1981
↓ 2 callersFunction_url_from_connection
Returns the URL from a given connection. This is mainly used for testing and logging.
src/urllib3/connection.py:922
↓ 2 callersFunction_url_from_pool
Returns the URL from a given connection pool. This is mainly used for testing and logging.
src/urllib3/connectionpool.py:1167
↓ 2 callersMethod_validate_conn
Called right before a request is made, after the socket is created.
src/urllib3/connectionpool.py:339
↓ 2 callersMethod_wrap_socket_and_mock_warn
( self, sock: socket.socket, server_hostname: str | None )
test/test_util.py:1041
↓ 2 callersFunction_write_cert_to_dir
( cert: trustme.LeafCert, tmpdir: Path, file_prefix: str = "server" )
test/conftest.py:65
↓ 2 callersFunctionclear_warnings
(cls: type[Warning] = HTTPWarning)
test/__init__.py:112
↓ 2 callersMethodclose
(self)
src/urllib3/connection.py:273
↓ 2 callersMethodclose
(self)
src/urllib3/contrib/pyopenssl.py:373
↓ 2 callersMethodclose
(self)
src/urllib3/contrib/emscripten/fetch.py:125
↓ 2 callersMethodconnect
(self)
src/urllib3/http2.py:68
↓ 2 callersMethodconnect
(self)
src/urllib3/connection.py:613
↓ 2 callersMethoddiscard
(self, key: str)
src/urllib3/_collections.py:296
↓ 2 callersMethoddrain_conn
Read and discard any remaining HTTP response data in the response connection. Unread data in the HTTPResponse connection blocks the
src/urllib3/response.py:642
↓ 2 callersFunctionencrypt_key_pem
(private_key_pem: trustme.Blob, password: bytes)
dummyserver/socketserver.py:184
↓ 2 callersMethodfrom_float
Create a new Timeout from a legacy timeout value. The timeout value used by httplib.py sets the same timeout on the connect(), and re
src/urllib3/util/timeout.py:173
↓ 2 callersMethodfrom_int
Backwards-compatibility for the old retries format.
src/urllib3/util/retry.py:271
↓ 2 callersFunctiongenerate
()
dummyserver/app.py:107
↓ 2 callersMethodget_connect_duration
Gets the time elapsed since the call to :meth:`start_connect`. :return: Elapsed time in seconds. :rtype: float :raises urllib
src/urllib3/util/timeout.py:213
↓ 2 callersFunctionget_subj_alt_name
Given an PyOpenSSL certificate, provides all the subject alternative names.
src/urllib3/contrib/pyopenssl.py:226
↓ 2 callersFunctionget_unreachable_address
()
dummyserver/socketserver.py:179
← previousnext →101–200 of 1,476, ranked by callers