question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Emulated Hue: Limited to RFC1918 IPv4 addresses

See original GitHub issue

Home Assistant release with the issue:

Home Assistant 0.103.6

Last working Home Assistant release (if known): n/a

Operating environment (Hass.io/Docker/Windows/etc.):

HASS.IO on Synology NAS (.SPK)

Integration:

/components/emulated_hue/

Description of problem: The Hue Emulation is limited to RFC1918 IPv4 adresses; if running in a network with e.g. RFC 3927 addresses or with public IPv4 addresses (as in my setup), which is perfectly fine and valid, access to e.g. /api/pi/lights is denied with message:

{“message”: “Only local IPs allowed”}

This is not mentioned anywhere in the docs.

There seems to be no option to work around this issue. The list of allowed IPv4 addresses seems to be hardcoded (see https://community.home-assistant.io/t/emulated-hue-only-local-ips-allowed/109852/4).

Please disable this check (I don’t know what it is good for) or provide a setting to override this check.

Problem-relevant configuration.yaml entries and (fill out even if it seems unimportant):

emulated_hue:

Traceback (if applicable):


Additional information:

Issue Analytics

  • State:open
  • Created 4 years ago
  • Comments:20 (1 by maintainers)

github_iconTop GitHub Comments

2reactions
amitsamanta996commented, Mar 10, 2022

Copy the emulated_hue folder from components to /config/custom_components, edit hue_api.py Add these after all import lines (around line 70) from ipaddress import IPv4Address, IPv6Address from typing import Union def is_local(address: Union [IPv6Address, IPv4Address]) -> bool: return True

0reactions
raskitomacommented, Jul 15, 2022

Like I said before, this should be open to configuration. amitsamanta996 solution is excellent! Thanks!

Read more comments on GitHub >

github_iconTop Results From Across the Web

Emulated Hue - "only local IPs allowed" - Configuration
I'm currently in the local network configuring from (11.0.0.9) and not sure whats blacklisting my IP. I'm running a RPi 3B+ 32Bit HA...
Read more >
RFC 1918: Address Allocation for Private Internets
In order to extend the life of the IPv4 address space, address registries are ... Category 2: hosts that need access to a...
Read more >
Emulated Hue setup question (IP Ranges) : r/homeassistant
My LAN network uses 23.10.x.x as it's IP range. According to the post, HomeAssistant only allows 10., 172. and 192. addresses. In HassIO,...
Read more >
IP Multicast Routing Configuration Guide, ...
Any use of actual IP addresses or phone numbers in illustrative content is unintentional ... IP Multicast Optimization: IGMP State Limit 309.
Read more >
Untitled
Reino metaphyta plantas, Coca steamboat prices, Sarens india pvt ltd, ... Pa skull radiograph, Discard upstream rfc1918 responses, Zytowska, Barclays africa ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found