Discussion:
[Geoserver-users] Forgot the geoserver login password
ldong
2016-12-02 20:58:14 UTC
Permalink
Hi,

This is a simple question, but it is important. I forgot the password to
login to geoserver for web administration. It has to be a way to reset;
please help.
--
LingLing Dong
Lamont-Doherty Earth Observation of Columbia University
Office Phone: 1-845-365-8836
Lab: 1-845-365-8679
Ben Caradoc-Davies
2016-12-02 22:16:22 UTC
Permalink
If you have write access to the data directory and have not set a master
password, you can change the admin password by editing:
security/usergroup/default/users.xml

Change the line like this:

<user enabled="true" name="admin"
password="digest1:D9miXH/hVgfxZJscMbfXtbtliG0WOxhLfsznyWfG38X2pda2JOSV4POi55PQI4tw"/>

To:

<user enabled="true" name="admin" password="plain:PASSWORD"/>

where PASSWORD is your new temporary password in plain text. I do not
think you need to restart GeoServer.

This technique is also useful for scripted installations of GeoServer.

Because storing passwords in plain text is a bad practice, you should
log in and change the admin password again to ensure it is stored as a
digest (cryptographic hash), not as plain text: under Security /
Users/Groups/Roles / Users/Groups / click on admin / fill in a new
password (twice) and press Save.

Check security/usergroup/default/users.xml to satisfy yourself that the
password digest is now stored (not plain text).

Kind regards,
Ben.
Post by ldong
Hi,
This is a simple question, but it is important. I forgot the password to
login to geoserver for web administration. It has to be a way to reset;
please help.
--
Ben Caradoc-Davies <***@transient.nz>
Director
Transient Software Limited <http://transient.nz/>
New Zealand
Loading...