TuyaAPI / cli

🔧 A CLI for Tuya devices
MIT License
262 stars 44 forks source link

TLS error at opening the Tuya Smart app #51

Closed arunoruto closed 4 years ago

arunoruto commented 4 years ago

Setting up the cert file and installing it on the iPhone of a friend worked fine. But as soon as I try to open the app, I get the following error:

_tls_common.js:88
      c.context.setCert(options.cert);
                ^

Error: error:0906D06C:PEM routines:PEM_read_bio:no start line
    at Object.createSecureContext (_tls_common.js:88:17)
    at Server (_tls_wrap.js:805:25)
    at new Server (https.js:54:14)
    at Object.createServer (https.js:76:10)
    at Proxy._createHttpsServer (/usr/lib/node_modules/@tuyapi/cli/node_modules/http-mitm-proxy/lib/proxy.js:106:27)
    at /usr/lib/node_modules/@tuyapi/cli/node_modules/http-mitm-proxy/lib/proxy.js:493:16
    at /usr/lib/node_modules/@tuyapi/cli/node_modules/async/dist/async.js:473:16
    at processQueue (/usr/lib/node_modules/@tuyapi/cli/node_modules/async/dist/async.js:1578:20)
    at taskComplete (/usr/lib/node_modules/@tuyapi/cli/node_modules/async/dist/async.js:1601:9)
    at /usr/lib/node_modules/@tuyapi/cli/node_modules/async/dist/async.js:1625:17

I have tried to make a new cert file and have repeated the same process a few times, but always with the same result. Maybe the app or device firmware is too new? Can someone help me with this?

codetheweb commented 4 years ago

Probably related to https://github.com/codetheweb/tuyapi/issues/280.