Linkding Password reset
-
Purely for the purpose of reserach <cough:, nah, I'm an idiot>, how do you reset the password for Linkding?
I can see
secretkey.txtin/app/databut don't think I can reverse it.I have tried
python3 manage.py createsuperuser --username=joe --email=joe@example.combut it returnssqlite3.OperationalError: unable to open database fileAlso trying
python3 manage.py changepasswordreturns the same error.Suggestions welcome, Couldn't see anything in their github issues.
-
I am wondering if the database is corrupt - can't find
db.sqlite3anywhere -
Hmmm, I attempted to restore from a backup.
However the latest backup I have (retention policy 7 days : maybe I should increase) also does not havedb.sqlite3.
I cannot tell when it might have stopped being present (as I use the app occasionally). -
Barking up the wrong tree
Fresh install on temp app.domain.tld doesn't havedb.sqlite3either.
So ... where is the database ?EDIT : seems like this package uses Postgres
-
Purely for the purpose of reserach <cough:, nah, I'm an idiot>, how do you reset the password for Linkding?
I can see
secretkey.txtin/app/databut don't think I can reverse it.I have tried
python3 manage.py createsuperuser --username=joe --email=joe@example.combut it returnssqlite3.OperationalError: unable to open database fileAlso trying
python3 manage.py changepasswordreturns the same error.Suggestions welcome, Couldn't see anything in their github issues.
@timconsidine said in Linkding Password reset:
Purely for the purpose of reserach <cough:, nah, I'm an idiot>, how do you reset the password for Linkding?
I found 2 places where it looks like you can do it:
/change-password/and
/admin/auth/user/1/password/
-
@timconsidine said in Linkding Password reset:
Purely for the purpose of reserach <cough:, nah, I'm an idiot>, how do you reset the password for Linkding?
I found 2 places where it looks like you can do it:
/change-password/and
/admin/auth/user/1/password/
@jdaviescoates hmm, deceptively obvious, but ...
- the first link requires a valid login
- the second throws up page
Not Found
But thank you - confirms I am overlooking info.
-
OK, phew, I'm in again on the original instance.
There is probably an easier way, but this is the 'hacking' that I did, in case it helps anyone :- installed a fresh instance of Linkding on a temporary URL
- change the default password as instructed
- launched a terminal and then clicked the
Postgresbutton to launchpsql - used
SELECT * FROM auth_user;to show the raw data for the only user, and copied the hashed password content - closed psql and closed the terminal
- in the original app installation, launched a terminal and launched a psql session
- updated the
auth_usertable for the only user withUPDATE auth_user SET password = 'copied_hashed_password_value' WHERE username = 'username'; - closed psql and terminal
- refreshed the login page for the original app instance
- logged in with the known unhashed password set for the user in the dummy app instance
- killed the dummy app instance
- for safety I also copied out the values in the bookmark table with
\COPY (SELECT * FROM bookmarks_bookmark) TO '/app/data/bookmarks.txt' WITH DELIMITER ',' CSV HEADER;
Maybe there is an easier way to do all that, but it seems Linkding doesn't provide any maintenance utilities for Postgres (just sqlite using python).
Goodnight !
-
As some petty revenge for losing access
I have packaged Shiori for Cloudron :
https://forum.cloudron.io/post/74384Hope it helps someone.
Hello! It looks like you're interested in this conversation, but you don't have an account yet.
Getting fed up of having to scroll through the same posts each visit? When you register for an account, you'll always come back to exactly where you were before, and choose to be notified of new replies (either via email, or push notification). You'll also be able to save bookmarks and upvote posts to show your appreciation to other community members.
With your input, this post could be even better 💗
Register Login