epoupon / lms

Lightweight Music Server. Access your self-hosted music using a web interface.
http://lms-demo.poupon.dev
GNU General Public License v3.0
1.03k stars 60 forks source link

MusicBee Subsonic API #12

Closed alfureu closed 4 years ago

alfureu commented 4 years ago

Trying to connect to LMS via the Subsonic API plugin of MusicBee. I can confirm that other server Subsonic API implementations work fine. However, I am not able to connect to LMS Subsonic API implementation. Can you have a look whether it is in LMS or in MusicBee?

epoupon commented 4 years ago

Hi! I don't know it but I would say it requires a minimal subsonic API to work. Could you please paste some connection attempt logs from LMS?

epoupon commented 4 years ago

Ok I have just had a look on the plugin source code. As a reminder, the authentication api has changed since subsonic 1.13, it now requires the server to store passwords in clear text, which is very questionable. The problem is that LMS stores hashed passwords. Therefore it cannot use the new authentication scheme.

The reported plugin is using api 1.13.0, but you can chose the authentication method (hex would be compatible), which is good. But i guess LMS would reject it since the api reported by the plugin is greater than the one used in lms. As usual with this API, I am quite puzzled as different solutions (hacks) may do the job:

  1. Report LMS to support 1.16.1 but handle only the hex authentication scheme (the api documentation is not clear about this). It is likely to break some other clients.
  2. Ignore the client api as long as the authentication scheme used is hex encoded password.
  3. Patch the plugin to report 1.12 version in case hex encoded passwords are used.
alfureu commented 4 years ago

Hi @epoupon, I think you are right with your analysis, especially with the authentication part. I made a screenshot, see below.

image

I switched to the hex encoded password (as per suggestion 2), and I see a different "error" message, or rather a "Detected Subsonic server" which I have not seen before.

image

I believe that especially your suggestion no. 3 might be the way to go, if there is a possibility to detect/differentiate between DSub and MusicBee as clients. Otherwise don't waste time, as currently the DSub option works well on Android and I am ecstatic about it. Before, the MusicBee Subsonic plugin worked with Airsonic, and maybe some other server backends (cannot remember). I just opened this issue as I thought you might be interested in the Subsonic API implementation.

epoupon commented 4 years ago

Hello, I have reported the issue here: https://github.com/midwan/MB_SubSonic/issues/53 But AFAIU of other issues on this client it looks like it should work with hex encoded password. Could please check the logs produced by lms when connecting using MusicBee?

alfureu commented 4 years ago

Thanks @epoupon, much appreciated. I added some info to that comment too. Hopefully it will get addressed!