Clear Banned LAN IPs

Hostname hassio
System HassOS 2.12
Deployment production
(Raspberry PI 3 B)

In testing API calls, I got my PC banned as indicated via some log messages.
Of course I searched posts for the location of this banned_ip file, but none of the posts had relevant info.

How do I clear my banned LAN IP, and how do I trust my LAN to avoid this issue.
BTW- Not using SSL

3 Likes

You would have an ip_bans.yaml in your configuration directory. Delete that and restart HA.

More info: https://www.home-assistant.io/components/http/#trusted_networks

12 Likes

Yes, I had seen that info in another post. I do not have such a file. I looked via the GUI’s “Configurator” and also with WinSCP, showing hidden files. Even performed a search with WinSCP using *ip* on the root, and no relevant matches.
Thanks for the answer though.

Any input on how to configure the ban parameters? IE setting attempt thresholds and trusted IPs or subnets?

That information is on the same page I linked. What is your http: configuration?

My oversight. The page you linked is actually a different than I thought it was. It does indeed answer my question about parameters. To answer your question, I actually did not have any http configurations in the configuration.yaml. I’m going through the page now to learn and set it up correctly. For anyone else reading, note the page indicates trusted_networks paramter is deprecated since 0.89 release. Configuration moved to Trusted Networks auth provider.

My Hass.io just updated recently to version 94.4 (or maybe .5)

Just an update to anyone following, I never did find a ip_bans.yaml file, but that may have been due to a view not refreshing or something. Adding the trusted_networks parameter to the configuration.yaml file and rebooting appears to have alleviated my ban issue.
Now my API calls are getting “405 Method Not Allowed”, but I’m sure that is another topic.
Thanks for the assist.

1 Like