Lutron Certificate Error

I’ve seen the same question pop up, but no definitive answers quite yet.

I have my Lutron Pro bridge on a static IP, installed the Lutron Certificate add-on, as I click through the generator I get an “Internal Server Error” after entering my hub’s IP address. When I browse to the \ssl\lutron I see “caseta.crt” and "caseta.key, but no “caseta-bridge.crt”.

When I reboot Home Assistant I get the following error when trying to configure the integration.

Failed to import Caséta bridge configuration.

Couldn’t setup bridge (host: 10.131.229.93) imported from configuration.yaml.

Failed to connect to Caséta bridge; check your host and certificate configuration.

I have Home Assistant OS running on a VM inside Unraid. I also initially setup the bridge as a HomeKit Controller. Would I need to disable the in Home Assistant and on the Lutron side for this to work?

I had the same issue with the caseta-bridge.crt not created. I had a different error. While troubleshooting I wondered if assigning a static IP by MAC address at the router was an issue. I had a standard bridge at first and upgraded to a pro. I kept the same IP but the MAC changed. I removed the devices, then the home in the lutron app. After that I chose a different static IP for the new pro bridge and it worked.

Traceback (most recent call last):
  File "/usr/src/homeassistant/homeassistant/config_entries.py", line 231, in async_setup
    result = await component.async_setup_entry(hass, self)  # type: ignore
  File "/usr/src/homeassistant/homeassistant/components/lutron_caseta/__init__.py", line 75, in async_setup_entry
    await bridge.connect()
  File "/usr/local/lib/python3.8/site-packages/pylutron_caseta/smartbridge.py", line 51, in connect
    await self._login()
  File "/usr/local/lib/python3.8/site-packages/pylutron_caseta/smartbridge.py", line 360, in _login
    self._reader, self._writer = await self._connect()
  File "/usr/local/lib/python3.8/site-packages/pylutron_caseta/smartbridge.py", line 64, in _connect
    res = await open_connection(hostname,
  File "/usr/local/lib/python3.8/site-packages/pylutron_caseta/leap.py", line 15, in open_connection
    connection = await asyncio.open_connection(host, port,
  File "/usr/local/lib/python3.8/asyncio/streams.py", line 52, in open_connection
    transport, _ = await loop.create_connection(
  File "/usr/local/lib/python3.8/asyncio/base_events.py", line 1025, in create_connection
    raise exceptions[0]
  File "/usr/local/lib/python3.8/asyncio/base_events.py", line 1010, in create_connection
    sock = await self._connect_sock(
  File "/usr/local/lib/python3.8/asyncio/base_events.py", line 924, in _connect_sock
    await self.sock_connect(sock, address)
  File "/usr/local/lib/python3.8/asyncio/selector_events.py", line 494, in sock_connect
    return await fut
  File "/usr/local/lib/python3.8/asyncio/selector_events.py", line 526, in _sock_connect_cb
    raise OSError(err, f'Connect call failed {address}')

I got it working, but not with the DIY certificate generator. Watched a couple of YT videos and figured out how to run the Python script from GitHub and was up and running in 20 minutes.

Can you share the videos you used? I am running into this issue myself

I couldn’t find anything specifically about the certificate generator script. I just searched along the lines of “How to run Python script on windows” and skimmed through a couple of videos. I got a few errors because I was needing to run a few more commands since the script was depending on some other things to be loaded first. I googled the errors and got the answers in the first couple of results.

I’m definitely a beginner when it comes to this stuff, but in all honesty I was surprised how quick I was able to figure it out.

I just realized we have different problems- I have the same error msg as you, but I do have all 3 files. Weird.

And just to confirm, I just ran it on Windows, copied over the 3 files, and same error. Odd. Not sure where to go from here