stephen / airsonos

:musical_note: AirPlay to Sonos
MIT License
2.1k stars 254 forks source link

Play:1 problem #336

Open lobototoro opened 7 years ago

lobototoro commented 7 years ago

hi ! And first, congrats for the initiative to hack sonos sound system ;) Well, I've purchased a play:1 and it seems it doesn't return the same length of id or string than the other devices from sonos. I've installed your lib and launch it via airsonoson my mac and it found my device successfully but when I selected it in the system preference sound panel, it gave me this error :

crypto.js:239
  this._handle.initiv(cipher, toBuf(key), toBuf(iv));
               ^

Error: Invalid key length
    at Error (native)
    at new Decipheriv (crypto.js:239:16)
    at Object.Decipheriv (crypto.js:236:12)
    at Object.decryptAudioData (/Users/pablo/.config/yarn/global/node_modules/nodetunes/lib/helper.js:141:25)
    at RtpServer.<anonymous> (/Users/pablo/.config/yarn/global/node_modules/nodetunes/lib/rtp.js:32:23)
    at emitTwo (events.js:106:13)
    at Socket.emit (events.js:191:7)
    at UDP.onMessage (dgram.js:550:8)

I'm with node 6.X.X, with yarn instead of npm under mac os sierra.

akisvolanis commented 7 years ago

same issue here...

sureshn14 commented 7 years ago

Yup me too.

`crypto.js:241 this._handle.initiv(cipher, toBuf(key), toBuf(iv)); ^

Error: Invalid key length at new Decipheriv (crypto.js:241:16) at Object.Decipheriv (crypto.js:238:12) at Object.decryptAudioData (/usr/local/lib/node_modules/airsonos/node_modules/nodetunes/lib/helper.js:141:25) at RtpServer. (/usr/local/lib/node_modules/airsonos/node_modules/nodetunes/lib/rtp.js:32:23) at emitTwo (events.js:106:13) at Socket.emit (events.js:191:7) at UDP.onMessage [as onmessage] (dgram.js:547:8)`

akisvolanis commented 7 years ago

i guess it has to do with nodetunes issue. More here.

jeantristan commented 7 years ago

Exactly, i solved my problem thanks to your link