Home Assistant keeps recording failed sign-ins when the connecting address has an unreadable reverse-DNS hostname. That lookup is only needed to add a name to the log, but an invalid response could interrupt processing before the failure was counted.

Guillaume BAILLEUL prevents that lookup error from bypassing the failed-login counter used for IP banning. It also preserves the normal unauthorized response instead of returning a server error. This is his first contribution to Home Assistant Core.