I have extended calibre web with github support.
https://github.com/jim3ma/calibre-web/commit/e993a1d9b21cd794981accbfe1d2942aca933545
and I also do some others changes.
I want to merge some enhancement into origin repo.
I like calibre web.
Thanks
Great job!
I looked at your code and I had the following questions:
1) I notice you had this bit of code:
if not config.config_public_reg:
abort(404)
Obviously this segment will deny anyone from logging in with a GitHub account if public registration is not turned on. Is there a way where we could get OAuth authentication and still block public registration? This way we can use OAuth as an authentication provider but allow more control for the administrator who can log in from that service.
2) How hard would it be to generalize the db table to allow for multiple OAuth providers? I assume if we allow for one, there would be requests for more. It doesn't make sense to have a db table for each unnecessarily. link
3) Have you tested this with OPDS?
Thanks!
There was an issue requesting Google Sign-on (#320 ), but it was closed for being "beyond project scope". Can the decision be re-considered given that GitHub login is approved?
Currently, the code is just for myself. I will refactor all those code and rethink how to allow multiple OAuth providers.
Thanks for looking into it!
If you can figure out how to do the multiple OAuth providers - I'm sure we can find other volunteers to create the other OAuth interfaces as long as you can get the first one done.
I did a little bit of research myself for multiple OAuth providers and found a very informative tutorial on youtube. Video 1 / Video 2
When I watched the videos, I think I may have a solution for the first question I had above. Can't wait to see what you can come up with!
Thanks again!
@bodybybuddha I'm working on it.
Phase 1, we will support multiple OAuth providers Github & Google, and make it simple
Phase 2. enable config ui for OAuth
@bodybybuddha see #673 , I have done it.
@Mohammed90 #673 have done with GitHub & Google OAuth support.
@jim3ma - NICE !! (I hope the keys in the image you included in the PR aren't your actual keys!)
@OzzieIsaacs has targeted this for the 1.1 release. This will give everyone some time to fully test out the code, etc. He seems to be very busy but hopefully, v1 features will be tested, approved, and released soon.
Thanks a million for this, @jim3ma !
How's OAuth login going to interact with disabled registration? I think this is something that needs to be decided, if possible. @bodybybuddha already raised this question above, but what is it like in the current implementation? Can existing users add the third-party login to their account? Can admins create users by inputting their Google email address or something like that?
Okay, we need to consider the action when we disable public registration and still enable oauth.
@bodybybuddha The keys in the image is just example.
Thanks a million for this, @jim3ma !
How's OAuth login going to interact with disabled registration? I think this is something that needs to be decided, if possible. @bodybybuddha already raised this question above, but what is it like in the current implementation? Can existing users add the third-party login to their account? Can admins create users by inputting their Google email address or something like that?
It鈥榮 merged
Most helpful comment
Currently, the code is just for myself. I will refactor all those code and rethink how to allow multiple OAuth providers.