idna-ssl
========
:info: Patch ssl.match_hostname for Unicode(idna) domains support
.. image:: https://travis-ci.com/aio-libs/idna-ssl.svg?branch=master
:target: https://travis-ci.com/aio-libs/idna-ssl
.. image:: https://img.shields.io/pypi/v/idna_ssl.svg
:target: https://pypi.python.org/pypi/idna_ssl
.. image:: https://codecov.io/gh/aio-libs/idna-ssl/branch/master/graph/badge.svg
:target: https://codecov.io/gh/aio-libs/idna-ssl
Installation
------------
.. code-block:: shell
pip install idna-ssl
Usage
-----
.. code-block:: python
from idna_ssl import patch_match_hostname # noqa isort:skip
patch_match_hostname() # noqa isort:skip
import asyncio
import aiohttp
URL = 'https://цфоут.мвд.рф/news/item/8065038/'
async def main():
async with aiohttp.ClientSession() as session:
async with session.get(URL) as response:
print(response)
loop = asyncio.get_event_loop()
loop.run_until_complete(main())
Motivation
----------
* Here is 100% backward capability
* Related aiohttp `issue <https://github.com/aio-libs/aiohttp/issues/949>`_
* Related Python `bug <https://bugs.python.org/issue31872>`_
* Related Python `pull request <https://github.com/python/cpython/pull/3462>`_
* It is fixed (by January 27 2018) in upcoming Python 3.7, but `IDNA2008 <https://tools.ietf.org/html/rfc5895>`_ is still broken
Thanks
------
The library was donated by `Ocean S.A. <https://ocean.io/>`_
Thanks to the company for contribution.
Raw data
{
"_id": null,
"home_page": "https://github.com/aio-libs/idna-ssl",
"name": "idna_ssl",
"maintainer": "",
"docs_url": null,
"requires_python": "",
"maintainer_email": "",
"keywords": "ssl,Unicode,idna,match_hostname",
"author": "Victor Kovtun",
"author_email": "hellysmile@gmail.com",
"download_url": "https://files.pythonhosted.org/packages/46/03/07c4894aae38b0de52b52586b24bf189bb83e4ddabfe2e2c8f2419eec6f4/idna-ssl-1.1.0.tar.gz",
"platform": "",
"description": "idna-ssl\n========\n\n:info: Patch ssl.match_hostname for Unicode(idna) domains support\n\n.. image:: https://travis-ci.com/aio-libs/idna-ssl.svg?branch=master\n :target: https://travis-ci.com/aio-libs/idna-ssl\n\n.. image:: https://img.shields.io/pypi/v/idna_ssl.svg\n :target: https://pypi.python.org/pypi/idna_ssl\n\n.. image:: https://codecov.io/gh/aio-libs/idna-ssl/branch/master/graph/badge.svg\n :target: https://codecov.io/gh/aio-libs/idna-ssl\n\nInstallation\n------------\n\n.. code-block:: shell\n\n pip install idna-ssl\n\nUsage\n-----\n\n.. code-block:: python\n\n from idna_ssl import patch_match_hostname # noqa isort:skip\n patch_match_hostname() # noqa isort:skip\n\n import asyncio\n\n import aiohttp\n\n URL = 'https://\u0446\u0444\u043e\u0443\u0442.\u043c\u0432\u0434.\u0440\u0444/news/item/8065038/'\n\n\n async def main():\n async with aiohttp.ClientSession() as session:\n async with session.get(URL) as response:\n print(response)\n\n\n loop = asyncio.get_event_loop()\n loop.run_until_complete(main())\n\nMotivation\n----------\n\n* Here is 100% backward capability\n* Related aiohttp `issue <https://github.com/aio-libs/aiohttp/issues/949>`_\n* Related Python `bug <https://bugs.python.org/issue31872>`_\n* Related Python `pull request <https://github.com/python/cpython/pull/3462>`_\n* It is fixed (by January 27 2018) in upcoming Python 3.7, but `IDNA2008 <https://tools.ietf.org/html/rfc5895>`_ is still broken\n\nThanks\n------\n\nThe library was donated by `Ocean S.A. <https://ocean.io/>`_\n\nThanks to the company for contribution.",
"bugtrack_url": null,
"license": "",
"summary": "Patch ssl.match_hostname for Unicode(idna) domains support",
"version": "1.1.0",
"project_urls": {
"Homepage": "https://github.com/aio-libs/idna-ssl"
},
"split_keywords": [
"ssl",
"unicode",
"idna",
"match_hostname"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "460307c4894aae38b0de52b52586b24bf189bb83e4ddabfe2e2c8f2419eec6f4",
"md5": "dd44ec53bac36e68446766fd8d3835bd",
"sha256": "a933e3bb13da54383f9e8f35dc4f9cb9eb9b3b78c6b36f311254d6d0d92c6c7c"
},
"downloads": -1,
"filename": "idna-ssl-1.1.0.tar.gz",
"has_sig": false,
"md5_digest": "dd44ec53bac36e68446766fd8d3835bd",
"packagetype": "sdist",
"python_version": "source",
"requires_python": null,
"size": 3377,
"upload_time": "2018-07-05T09:15:37",
"upload_time_iso_8601": "2018-07-05T09:15:37.206167Z",
"url": "https://files.pythonhosted.org/packages/46/03/07c4894aae38b0de52b52586b24bf189bb83e4ddabfe2e2c8f2419eec6f4/idna-ssl-1.1.0.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2018-07-05 09:15:37",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "aio-libs",
"github_project": "idna-ssl",
"travis_ci": true,
"coveralls": false,
"github_actions": false,
"requirements": [
{
"name": "aiohttp",
"specs": [
[
"==",
"3.6.3"
]
]
},
{
"name": "flake8",
"specs": [
[
"==",
"3.8.4"
]
]
},
{
"name": "pytest",
"specs": [
[
"==",
"6.1.1"
]
]
},
{
"name": "pytest-asyncio",
"specs": [
[
"==",
"0.14.0"
]
]
},
{
"name": "pytest-cov",
"specs": [
[
"==",
"2.10.1"
]
]
},
{
"name": "pytest-runner",
"specs": [
[
"==",
"5.2"
]
]
},
{
"name": "isort",
"specs": [
[
"==",
"4.3.21"
]
]
}
],
"tox": true,
"lcname": "idna_ssl"
}