-
Notifications
You must be signed in to change notification settings - Fork 19
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Generate secret key during first run and store it in the database #4
Comments
Good idea, i would put this in the settings table and create it with the first run function (empty db). |
It's only used internally so I don't think there's any point in exposing it to the end user. Worst case if you lose it is all the currently active user sessions get reset and people need to log in again. |
makes sense. will integrate this in the coming days. |
Awesome, I'm going to go through this OpenId connect example and try to adapt it to your database models |
with the current app structure its no possible to load the key using the config object as the db would have to be initialized already. I think i will put this aside for the moment and maybe add some instructions how to generate one |
Realistically the user never needs to care about the secret key, it can be auto-generated during the first run. I think it makes sense to put it in the database and not the file system because that way if you use a distributed database backend like cockroachDb every node gets the same secret key and everything sort of just works.
Is part of the standard library.
Just removes a little bit more friction when people set up the service for the first time.
The text was updated successfully, but these errors were encountered: