mirror of
https://github.com/home-assistant/core.git
synced 2026-12-02 19:57:03 -04:00
2026.10.4 (#188384)
This commit is contained in:
@@ -10,7 +10,7 @@
|
||||
"integration_type": "hub",
|
||||
"iot_class": "local_push",
|
||||
"loggers": ["pylutron_caseta"],
|
||||
"requirements": ["pylutron-caseta==0.29.0"],
|
||||
"requirements": ["pylutron-caseta==0.30.0"],
|
||||
"zeroconf": [
|
||||
{
|
||||
"properties": {
|
||||
|
||||
@@ -23,7 +23,7 @@ if TYPE_CHECKING:
|
||||
APPLICATION_NAME: Final = "HomeAssistant"
|
||||
MAJOR_VERSION: Final = 2026
|
||||
MINOR_VERSION: Final = 10
|
||||
PATCH_VERSION: Final = "3"
|
||||
PATCH_VERSION: Final = "4"
|
||||
__short_version__: Final = f"{MAJOR_VERSION}.{MINOR_VERSION}"
|
||||
__version__: Final = f"{__short_version__}.{PATCH_VERSION}"
|
||||
REQUIRED_PYTHON_VER: Final[tuple[int, int, int]] = (3, 14, 2)
|
||||
|
||||
@@ -157,6 +157,10 @@ async def _async_is_blocked_host(
|
||||
MAXIMUM_CONNECTIONS = 4096
|
||||
MAXIMUM_CONNECTIONS_PER_HOST = 100
|
||||
|
||||
# aiohttp's 8190 byte default is too small for some servers, e.g. GitHub's
|
||||
# release download redirects carry a ~9 KiB Content-Security-Policy header.
|
||||
MAXIMUM_HEADER_SIZE = 65536
|
||||
|
||||
|
||||
class HassAsyncDNSResolver(AsyncDualMDNSResolver):
|
||||
"""Home Assistant AsyncDNSResolver.
|
||||
@@ -290,6 +294,9 @@ def _async_create_clientsession(
|
||||
*kwargs.pop("middlewares", ()),
|
||||
)
|
||||
|
||||
kwargs.setdefault("max_line_size", MAXIMUM_HEADER_SIZE)
|
||||
kwargs.setdefault("max_field_size", MAXIMUM_HEADER_SIZE)
|
||||
|
||||
clientsession = aiohttp.ClientSession(
|
||||
connector=_async_get_connector(hass, verify_ssl, family, ssl_cipher),
|
||||
json_serialize=json_dumps,
|
||||
|
||||
+1
-1
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
|
||||
|
||||
[project]
|
||||
name = "homeassistant"
|
||||
version = "2026.10.3"
|
||||
version = "2026.10.4"
|
||||
license = "Apache-2.0"
|
||||
license-files = ["LICENSE*", "homeassistant/backports/LICENSE*"]
|
||||
description = "Open-source home automation platform running on Python 3."
|
||||
|
||||
Generated
+1
-1
@@ -2397,7 +2397,7 @@ pylitejet==0.6.3
|
||||
pylitterbot==2025.6.5
|
||||
|
||||
# homeassistant.components.lutron_caseta
|
||||
pylutron-caseta==0.29.0
|
||||
pylutron-caseta==0.30.0
|
||||
|
||||
# homeassistant.components.lutron
|
||||
pylutron==0.4.4
|
||||
|
||||
@@ -690,3 +690,22 @@ async def test_redirect_to_blocked_address(
|
||||
pytest.raises(client.SSRFRedirectError),
|
||||
):
|
||||
await session.get(redirect_url)
|
||||
|
||||
|
||||
@pytest.mark.usefixtures("socket_enabled")
|
||||
async def test_clientsession_accepts_large_headers(hass: HomeAssistant) -> None:
|
||||
"""Test the clientsession reads header fields larger than aiohttp's default limit."""
|
||||
large_value = "x" * 9300
|
||||
|
||||
async def handler(request: web.Request) -> web.Response:
|
||||
"""Return a response with a header field larger than 8190 bytes."""
|
||||
return web.Response(text="ok", headers={"Content-Security-Policy": large_value})
|
||||
|
||||
app = web.Application()
|
||||
app.router.add_get("/", handler)
|
||||
|
||||
async with TestServer(app) as server:
|
||||
session = client.async_get_clientsession(hass)
|
||||
async with session.get(server.make_url("/")) as resp:
|
||||
assert resp.status == 200
|
||||
assert resp.headers["Content-Security-Policy"] == large_value
|
||||
|
||||
Reference in New Issue
Block a user