fuatakgun / eufy_security

Home Assistant integration to manage Eufy Security devices as cameras, home base stations, doorbells, motion and contact sensors.
842 stars 73 forks source link

[P2PClientProtocol.handleDataBinaryAndVideo] Error: AES key could not be decrypted! #1115

Closed chris173972 closed 3 months ago

chris173972 commented 4 months ago

When trying to steam my T8210 doorbell:

2024-03-04 11:31:39.335 WARN eufy-security-ws:eufy-security-client [p2p] [P2PClientProtocol.handleDataBinaryAndVideo] Error: AES key could not be decrypted! The entire stream is discarded. { error: { cause: undefined, message: 'Error: Error during decryption (probably incorrect key). Original error: TypeError: RSA_PKCS1_PADDING is no longer supported for private decryption, this can be reverted with --security-revert=CVE-2023-46809', context: undefined, stacktrace: 'Error: Error during decryption (probably incorrect key). Original error: TypeError: RSA_PKCS1_PADDING is no longer supported for private decryption, this can be reverted with --security-revert=CVE-2023-46809\n' + ' at module.exports.NodeRSA.$$decryptKey (/usr/src/app/node_modules/node-rsa/src/NodeRSA.js:301:19)\n' + ' at module.exports.NodeRSA.decrypt (/usr/src/app/node_modules/node-rsa/src/NodeRSA.js:249:21)\n' + ' at P2PClientProtocol.handleDataBinaryAndVideo (/usr/src/app/node_modules/eufy-security-client/build/p2p/session.js:1355:63)\n' + ' at P2PClientProtocol.handleData (/usr/src/app/node_modules/eufy-security-client/build/p2p/session.js:1295:18)\n' + ' at P2PClientProtocol.parseDataMessage (/usr/src/app/node_modules/eufy-security-client/build/p2p/session.js:1152:26)\n' + ' at P2PClientProtocol.handleMsg (/usr/src/app/node_modules/eufy-security-client/build/p2p/session.js:986:26)\n' + ' at Socket. (/usr/src/app/node_modules/eufy-security-client/build/p2p/session.js:118:56)\n' + ' at Socket.emit (node:events:517:28)\n' + ' at Socket.emit (node:domain:489:12)\n' + ' at UDP.onMessage [as onmessage] (node:dgram:942:8)' }, stationSN: 'T8020P11224526BC', key: ... }

Additional information

Core 2024.2.5 Supervisor 2024.02.1 Operating System 12.0 eufy-security-ws version: 1.8.0 fuatakgun/eufy_security version: 8.0.1

HBosscha-AT commented 3 months ago

I've got exactly the same issue when trying to stream my doorbell T8210.

b14ckw1d0w commented 3 months ago

Same issue with Doorbell T8210. Other camera (T8142-z) works fine.

Only happened with latest eufy-security-ws update.

51av0sh commented 3 months ago

Having the same issue with T8170 (s340)

kauthmbt commented 3 months ago

More likely an add-on issue than an integration issue: https://github.com/bropat/eufy-security-ws/issues/310

DavidinoX commented 3 months ago

Same here with eufycam 2c. how do i install an older version?

kauthmbt commented 3 months ago

In general the only option is to revert to the backup of the add-on which was hopefully done during the add-on update process.

Nevertheless there is a new addon version 1.8.0-2 available which fixes the issue.

chris173972 commented 3 months ago

Tested with 1.8.0-2 and it works correctly with T8210