forked from urllib3/urllib3
-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
2.2.900 (2023-11-01) ==================== - Added support for in-memory client (intermediary) certificate to be used with mTLS. This feature compensates for the complete removal of ``pyOpenSSL``. Unfortunately, it is only available on Linux, OpenBSD, and FreeBSD. Using newly added ``cert_data`` and ``key_data`` arguments in ``HTTPSConnection`` and ``HTTPSPoolConnection`` you will be capable of passing the certificate along with its key without getting nowhere near your filesystem. MacOS and Windows are not concerned by this feature when using HTTP/1.1, and HTTP/2 with TLS over TCP. - Removed remnant ``SSLTransport.makefile`` as it was built to circumvent a legacy constraint when urllib3 depended upon ``http.client``. - Bumped minimum requirement for ``qh3`` to version 0.13.0 in order to support in-memory client certificate (mTLS). - Symbolic complete detachment from ``http.client``. Removed all references and imports to ``http.client``. Farewell! - Changed the default ciphers in default SSLContext for an **increased** security level. *Rational:* Earlier in v2.1.901 we initialized the SSLContext ciphers with the value ``DEFAULT`` but after much consideration, after we saw that the associated ciphers (e.g. ``DEFAULT`` from OpenSSL) includes some weak suites we decided to inject a rather safer and limited cipher suite. It is based on https://ssl-config.mozilla.org Starting now, urllib3.future will match Mozilla cipher recommendations (intermediary) and will regularly update the suite. - Added support for multiplexed connection. HTTP/2 and HTTP/3 can benefit from this. urllib3.future no longer blocks when ``urlopen(...)`` is invoked using ``multiplexed=True``, and return a ``ResponsePromise`` instead of a ``HTTPResponse``. You may dispatch as much requests as the protocol permits you (concurrent stream) and then retrieve the response(s) using the ``get_response(...)``. ``get_response(...)`` can take up to one kwarg to specify the target promise, if none is specified, will retrieve the first available response. ``multiplexed`` is set to False by default and will likely be the default for a long time. Here is an example ```python from urllib3 import PoolManager with PoolManager() as pm: promise0 = pm.urlopen("GET", "https://pie.dev/delay/3", multiplexed=True) # <ResponsePromise 'IOYTFooi0bCuaQ9mwl4HaA==' HTTP/2.0 Stream[1]> promise1 = pm.urlopen("GET", "https://pie.dev/delay/1", multiplexed=True) # <ResponsePromise 'U9xT9dPVGnozL4wzDbaA3w==' HTTP/2.0 Stream[3]> response0 = pm.get_response() # the second request arrived first response0.json()["url"] # https://pie.dev/delay/1 # the first arrived last response1 = pm.get_response() response1.json()["url"] # https://pie.dev/delay/3 ``` or you may do ```python from urllib3 import PoolManager with PoolManager() as pm: promise0 = pm.urlopen("GET", "https://pie.dev/delay/3", multiplexed=True) # <ResponsePromise 'IOYTFooi0bCuaQ9mwl4HaA==' HTTP/2.0 Stream[1]> promise1 = pm.urlopen("GET", "https://pie.dev/delay/1", multiplexed=True) # <ResponsePromise 'U9xT9dPVGnozL4wzDbaA3w==' HTTP/2.0 Stream[3]> response0 = pm.get_response(promise=promise0) # forcing retrieving promise0 response0.json()["url"] # https://pie.dev/delay/3 # then pick first available response1 = pm.get_response() response1.json()["url"] # https://pie.dev/delay/1 ``` You may do multiplexing using ``PoolManager``, and ``HTTPSPoolConnection``. Connection upgrade to HTTP/3 cannot be done until all in-flight requests are completed. - Connections are now released into their respective pool when the connection support multiplexing (HTTP/2, HTTP/3) before the response has been consumed. This allows to have multiple responses half-consumed from a single connection.
- Loading branch information
Showing
56 changed files
with
2,015 additions
and
498 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,2 @@ | ||
tidelift: pypi/urllib3 | ||
github: urllib3 | ||
open_collective: urllib3 | ||
github: | ||
- Ousret |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,11 +1,8 @@ | ||
blank_issues_enabled: false | ||
contact_links: | ||
- name: 📚 Documentation | ||
url: https://urllib3.readthedocs.io | ||
url: https://urllib3future.readthedocs.io | ||
about: Make sure you read the relevant docs | ||
- name: ❓ Ask on StackOverflow | ||
url: https://stackoverflow.com/questions/tagged/urllib3 | ||
about: Ask questions about usage in StackOverflow | ||
- name: 💬 Ask the Community | ||
url: https://discord.gg/CHEgCZN | ||
about: Join urllib3's Discord server |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,8 +1,8 @@ | ||
<!--- | ||
Thanks for your contribution! ♥️ | ||
Hello! | ||
If this is your first PR to urllib3 please review the Contributing Guide: | ||
https://urllib3.readthedocs.io/en/latest/contributing.html | ||
If this is your first PR to urllib3.future please review the Contributing Guide: | ||
https://urllib3future.readthedocs.io/en/latest/contributing.html | ||
Adhering to the Contributing Guide means we can review, merge, and release your change faster! :) | ||
---> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,19 +1,8 @@ | ||
* [ ] See if all tests, including integration, pass | ||
* [ ] Get the release pull request approved by a [CODEOWNER](https://github.com/urllib3/urllib3/blob/main/.github/CODEOWNERS) | ||
* [ ] Get the release pull request approved by a [CODEOWNER](https://github.com/jawah/urllib3.future/blob/main/.github/CODEOWNERS) | ||
* [ ] Squash merge the release pull request with message "`Release <VERSION>`" | ||
* [ ] Tag with X.Y.Z, push tag on urllib3/urllib3 (not on your fork, update `<REMOTE>` accordingly) | ||
* Notice that the `<VERSION>` shouldn't have a `v` prefix (Use `1.26.6` instead of `v.1.26.6`) | ||
* ``` | ||
git tag -s -a '<VERSION>' -m 'Release: <VERSION>' | ||
git push <REMOTE> --tags | ||
``` | ||
* [ ] Execute the `publish` GitHub workflow. This requires a review from a maintainer. | ||
* [ ] Create a Github Release | ||
* [ ] Ensure that all expected artifacts are added to the new GitHub release. Should | ||
be one `.whl`, one `.tar.gz`, and one `multiple.intoto.jsonl`. Update the GitHub | ||
release to have the content of the release's changelog. | ||
* [ ] Announce on: | ||
* [ ] Discord | ||
* [ ] OpenCollective | ||
* [ ] Update Tidelift metadata | ||
* [ ] If this was a 1.26.x release, add changelog to the `main` branch |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.