-
-
Notifications
You must be signed in to change notification settings - Fork 5.5k
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
dump and manual restore causes broken external auth sources. #16831
Comments
We need logs. |
When I try to log a user in that belongs to the authentication source
When trying to edit the authentication source
|
Now that's more helpful. It would be useful to examine the Likely what has happened is that the You may be better off deleting the login_source and recreating it. |
I cannot edit the login source to delete it. but I can do it from sql... would it be ok to delete them, recreate them and then update their IDs? I have many users and would like it all to jive. In fact I have 8 different LDAP sources ... and they are all broken... 5 is just the one that user was authenticating against which is broken. I could share the data privately in row 5 if you like just not on git... do you use element/matrix ? I am @two:gnu.fun Not certain what you mean by cfg field ? potentially I am missing it? since I have been using gitea since it forked from gogs. Pretty sure I can correct this without help but I would be glad to share the data, if you think this might be an issue... if not on element I can clean the data of private bits and share it here? |
Ah you have a lot of users you want to keep... OK. Create a new source with the all the details - mark it inactive - then in the db copy over its cfg on to the broken.
You'll have to do the same thing.
That might be useful
I meant in the db |
Ok this is annoying because I definitely fixed an issue with this early on in 1.14.x but it appears that it came back. The problem is that the https://gitea.com/xorm/xorm/pulls/1903 Fixed this but it appears that it's been refactored away at some point. |
OK so testing reveals that the dump works on 1.14.0, 1.14.1, and 1.14.2 and is broken on 1.14.3. The bad commit is: ad54f00
|
However, things are correct on v1.16.0-dev-159-gcd8db3a83. The fixing commit is: 7224cfc
|
go-gitea#16831 has occurred because of a missed regression. This PR adds a simple test to try to prevent this occuring again. Signed-off-by: Andrew Thornton <art27@cantab.net>
…gitea#16847) go-gitea#16831 has occurred because of a missed regression. This PR adds a simple test to try to prevent this occuring again. Signed-off-by: Andrew Thornton <art27@cantab.net>
…gitea#16847) go-gitea#16831 has occurred because of a missed regression. This PR adds a simple test to try to prevent this occuring again. Signed-off-by: Andrew Thornton <art27@cantab.net>
) #16831 has occurred because of a missed regression. This PR adds a simple test to try to prevent this occuring again. Signed-off-by: Andrew Thornton <art27@cantab.net>
Maybe we should publish v1.15.1 or v1.14.7 ASAP |
Yup I think so |
…login sources remains correct (#16847) (#16849) * Upgrade xorm to v1.2.2 (#16663) Backport #16663 Fix #16683 * Upgrade xorm to v1.2.2 * Change the Engine interface to match xorm v1.2.2 * Add test to ensure that dumping of login sources remains correct (#16847) #16831 has occurred because of a missed regression. This PR adds a simple test to try to prevent this occuring again. Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
…login sources remains correct (#16847) (#16848) * Upgrade xorm to v1.2.2 (#16663) Backport #16663 Fix #16683 * Add test to ensure that dumping of login sources remains correct (#16847) #16831 has occurred because of a missed regression. This PR adds a simple test to try to prevent this occuring again. Signed-off-by: Andrew Thornton <art27@cantab.net> Co-authored-by: Lunny Xiao <xiaolunwen@gmail.com>
The underlying bug also means that the |
[x]
):...
using gitea dump to backup my system then restored it I realized that all the external authentication is broken.
During the restore process I deleted the old DB and restored it the with the command provided in the docs.
mysql --default-character-set=utf8mb4 -u$USER -p$PASS $DATABASE <gitea-db.sql
now when users from external auth try to login they get error 500 and also when trying to edit the sources from my local admin account they also error 500.
This is reproducible with my setup but I have not tried to setup external auth with a vanilla install. please let me know if more details are needed.
The text was updated successfully, but these errors were encountered: