-
Notifications
You must be signed in to change notification settings - Fork 65
Ooth local: no way to programmatically create a user #58
Comments
That is a good point. Your observation is correct. Looks like this would solve the issue: #49. If you are in a hurry a workaround could be to create an user via http and then modify it via a command to mongodb. Both steps are ugly, I know 😁 |
In our scenario, we'd like to build an interface where an admin user can create other users, but we're running into a host of issues, primarily stemming from a lack of a programmatic interface. Also, calls to the local strategy's |
I had this same issue. I ended up studying insides of ooth and creating something similar that is compatable. I have removed the application specific parts but here it is
|
Yeah, the lack of programmatic interface ended up being the reason we had to switch from using Ooth too. Seems like it’s got a bit of work to go before it’s ready for production. Looking forward to when it matures a bit more though!
… 26. apr. 2018 kl. 18:15 skrev Adam Boe ***@***.***>:
what is the roles variable?
—
You are receiving this because you authored the thread.
Reply to this email directly, view it on GitHub, or mute the thread.
|
@jonpacker thanks for the feedback, what approach did you end up taking? Is there any library that was helpful to you? |
For the specific case of
The general idea is that every method registered with |
What's the ooth.on event callback for "login", that exist? |
It seems like the logic for inserting an Ooth local user with hashed password is inside an express route, and this is the only place it exists. Because of the prerequisite of
ooth-roles
that a user has to have their role set manually to admin, it seems like there's no good way to programmatically create that first user if they don't exist and give them an admin role. I could recreate the password hashing that is going on insideooth-local
, but this seems like a really bad idea. Is there something I'm missing here?The text was updated successfully, but these errors were encountered: