normen / homebridge-landroid

Homebridge plugin to control Worx Landroid robo mowers through the Worx Cloud
24 stars 8 forks source link

Error: unsupported #40

Closed aessing closed 2 years ago

aessing commented 2 years ago

Hi, thanks for developing this great plugin. Unfortunately I getting an error using it.

When Homebridge loads, the following error occurs

[Landroid] Error: unsupported
    at configSecureContext (node:internal/tls/secure-context:280:15)
    at Object.createSecureContext (node:_tls_common:117:3)
    at Object.connect (node:_tls_wrap:1621:48)
    at Object.buildBuilder (/usr/local/lib/node_modules/homebridge-landroid/node_modules/mqtt/lib/connect/tls.js:20:26)
    at MqttClient.wrapper [as streamBuilder] (/usr/local/lib/node_modules/homebridge-landroid/node_modules/mqtt/lib/connect/index.js:155:36)
    at MqttClient._setupStream (/usr/local/lib/node_modules/homebridge-landroid/node_modules/mqtt/lib/client.js:415:22)
    at new MqttClient (/usr/local/lib/node_modules/homebridge-landroid/node_modules/mqtt/lib/client.js:395:8)
    at Object.connect (/usr/local/lib/node_modules/homebridge-landroid/node_modules/mqtt/lib/connect/index.js:157:18)
    at Worx._connectMqtt (/usr/local/lib/node_modules/homebridge-landroid/node_modules/iobroker.worx/lib/api.js:245:27)
    at /usr/local/lib/node_modules/homebridge-landroid/node_modules/iobroker.worx/lib/api.js:212:34

Do you have an idea why this is happening?

Running

Thanks Andre

normen commented 2 years ago

What OS are you running on? And what type of mower are you using (Worx, Kress)? Looks like either an issue on the server side or an issue on the OS level with the TLS connection.

aessing commented 2 years ago

Hi @normen ,

I'm running on Almalinux 9 and using a Worx.

Can you give me an advice where the plugin connects to? Already checked the security settings on the host, but I can't figure out the issue as a "true" error message is missing.

Oh, and this comes up, after the plugin has figured out that there is a mower and how is it called, etc. So first login to worx where it discovers the mower seems to work. It is the connect afterwards that brings up the issue.

Cheers

Andre

normen commented 2 years ago

The heavy lifting of this plugin is done by this library: https://github.com/iobroker-community-adapters/ioBroker.worx

However, notice this bug report for Almalinux, which seems to fit this issue: https://bugs.almalinux.org/view.php?id=221

aessing commented 2 years ago

Thanks for your help @normen, but it seems to be a different issue, as I can connect via CURL to the HTTPS endpoint of the Landroid without an issue. Not sure if NodeJS uses a different certificate store than the OS. Also checked FW, HTTP/HTTPS and MQTT Ports are opened.

aessing commented 2 years ago

Just want to let you now - I updated to NodeJS 16.15.1, now it works like a charm.

normen commented 2 years ago

Thanks for reporting back!