mediacms icon indicating copy to clipboard operation
mediacms copied to clipboard

There is no way to access the passwords of users created in the Django Admin

Open Dan1ell opened this issue 4 years ago • 9 comments

Comes from discussion 122

When making users in the Django admin, the user is created without prompting for a password. The auto-generated password is not displayed anywhere. No email is sent with the password either. There is no way to find out what the password for the user is.

Dan1ell avatar Apr 05 '21 13:04 Dan1ell

Nice description, this could be handled so that the case where an admin bulk creates accounts can also set the password for them

mgogoulos avatar Apr 05 '21 17:04 mgogoulos

Any hints on where can I change the user's password? I'm trying to add users via the Django admin panel but the end users can't log on due to unknown password...

ilbuonmarcio avatar Nov 03 '21 15:11 ilbuonmarcio

if you've set the email settings, reset password should email the user with a link to reset the password.

But since you're an admin, you may set any user password through the Django manage shell, checkout this thread: https://github.com/mediacms-io/mediacms/discussions/81

mgogoulos avatar Nov 03 '21 20:11 mgogoulos

Isn't there any other way, for a non technical person, to manage passwords via gui? I'm installing it for a friend of mine which is absolutely non techie, unfortunately, and can't explain to him how to use the Django management shell :P

ilbuonmarcio avatar Nov 04 '21 14:11 ilbuonmarcio

I see, what you're asking for is very valid indeed. I'm pretty sure there has to be a way on Django admin to set a new password!

mgogoulos avatar Nov 05 '21 17:11 mgogoulos

Any hints in where to touch in the code so that I can implement an integration in the Django administration panel to make it work? Thanks in advance!

ilbuonmarcio avatar Nov 08 '21 22:11 ilbuonmarcio

I see, what you're asking for is very valid indeed. I'm pretty sure there has to be a way on Django admin to set a new password!

Hi, what about using UserAdmin as suggested here?

@mgogoulos I may test this solution and send a PR, if you want to...

masavini avatar Jun 29 '22 16:06 masavini

I ran into this problem as well on initial installation in a corporate environment behind a firewall. Would be great to have it fixed.

KyleMaas avatar Oct 17 '22 13:10 KyleMaas

This worked...

  1. active your environment source /home/mediacms.io/bin/activate
  2. from home/mediacms.io/mediacms run python3 manage.py createsuperuser
  3. now create a new admin user, DON"T use the same name
  4. Log in with the new admin user
  5. delete the first admin user
  6. start from step 2, this time use 'admin`
  7. go back in with the new admin and delete the additional one.

alfred-stokespace avatar Jan 01 '23 00:01 alfred-stokespace