[Bug]: Mobile App login for Openid user crashes server #1591

Closed
opened 2026-04-24 23:51:06 +02:00 by adam · 3 comments
Owner

Originally created by @gdunstone on GitHub (Dec 10, 2023).

Describe the issue

Attempting to log in using the mobile app, to a server that has OpenID SSO enabled causes the server to crash and the mobile app to not login.

home-audiobookshelf-1  | /server/libs/bcryptjs/index.js:31
home-audiobookshelf-1  | c){e(function(b,d){b?c(b):a(d)})})};m.compareSync=function(a,b){if("string"!==typeof a||"string"!==typeof b)throw Error("Illegal arguments: "+typeof a+", "+typeof b);return 60!==b.length?!1:g(m.hashSync(a,b.substr(0,b.length-31)),b)};m.compare=function(a,b,h,c){function e(f){"string"!==typeof a||"string"!==typeof b?r(f.bind(this,Error("Illegal arguments: "+typeof a+", "+typeof b))):60!==b.length?r(f.bind(this,null,!1)):m.hash(a,b.substr(0,29),function(a,c){a?f(a):f(null,g(c,b))},c)}if(h){if("function"!==
home-audiobookshelf-1  |                                                                                                                                                                                                                                                                                                                                            ^
home-audiobookshelf-1  | 
home-audiobookshelf-1  | Error: Illegal arguments: string, object
home-audiobookshelf-1  |     at e (/server/libs/bcryptjs/index.js:31:332)
home-audiobookshelf-1  |     at /server/libs/bcryptjs/index.js:32:96
home-audiobookshelf-1  |     at new Promise (<anonymous>)
home-audiobookshelf-1  |     at Object.m.compare (/server/libs/bcryptjs/index.js:32:70)
home-audiobookshelf-1  |     at Auth.localAuthCheckUserPw (/server/Auth.js:525:34)

Steps to reproduce the issue

  1. setup server with OpenID SSO
  2. login once to create the account
  3. attempt login using the mobile app

Audiobookshelf version

v2.6.0

How are you running audiobookshelf?

Docker

Originally created by @gdunstone on GitHub (Dec 10, 2023). ### Describe the issue Attempting to log in using the mobile app, to a server that has OpenID SSO enabled causes the server to crash and the mobile app to not login. ``` home-audiobookshelf-1 | /server/libs/bcryptjs/index.js:31 home-audiobookshelf-1 | c){e(function(b,d){b?c(b):a(d)})})};m.compareSync=function(a,b){if("string"!==typeof a||"string"!==typeof b)throw Error("Illegal arguments: "+typeof a+", "+typeof b);return 60!==b.length?!1:g(m.hashSync(a,b.substr(0,b.length-31)),b)};m.compare=function(a,b,h,c){function e(f){"string"!==typeof a||"string"!==typeof b?r(f.bind(this,Error("Illegal arguments: "+typeof a+", "+typeof b))):60!==b.length?r(f.bind(this,null,!1)):m.hash(a,b.substr(0,29),function(a,c){a?f(a):f(null,g(c,b))},c)}if(h){if("function"!== home-audiobookshelf-1 | ^ home-audiobookshelf-1 | home-audiobookshelf-1 | Error: Illegal arguments: string, object home-audiobookshelf-1 | at e (/server/libs/bcryptjs/index.js:31:332) home-audiobookshelf-1 | at /server/libs/bcryptjs/index.js:32:96 home-audiobookshelf-1 | at new Promise (<anonymous>) home-audiobookshelf-1 | at Object.m.compare (/server/libs/bcryptjs/index.js:32:70) home-audiobookshelf-1 | at Auth.localAuthCheckUserPw (/server/Auth.js:525:34) ``` ### Steps to reproduce the issue 1. setup server with OpenID SSO 2. login once to create the account 3. attempt login using the mobile app ### Audiobookshelf version v2.6.0 ### How are you running audiobookshelf? Docker
adam added the bug label 2026-04-24 23:51:06 +02:00
adam closed this issue 2026-04-24 23:51:06 +02:00
Author
Owner

@advplyr commented on GitHub (Dec 10, 2023):

How are you attempting to login with the mobile app? There is a bug fixed for a server crash when login into a user that doesn't have a password. Is this the same? https://github.com/advplyr/audiobookshelf/issues/2378

@advplyr commented on GitHub (Dec 10, 2023): How are you attempting to login with the mobile app? There is a bug fixed for a server crash when login into a user that doesn't have a password. Is this the same? https://github.com/advplyr/audiobookshelf/issues/2378
Author
Owner

@advplyr commented on GitHub (Dec 10, 2023):

Duplicate of #2378

@advplyr commented on GitHub (Dec 10, 2023): Duplicate of #2378
Author
Owner

@gdunstone commented on GitHub (Dec 11, 2023):

Yeah it is a duplicate of that one, I didnt find that issue as I wasnt searching for the same thing.

@gdunstone commented on GitHub (Dec 11, 2023): Yeah it is a duplicate of that one, I didnt find that issue as I wasnt searching for the same thing.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/audiobookshelf#1591