lardbit/nefarious

How to reset password?

Explosion-Scratch opened this issue · 9 comments

Is there a way to reset/change/view the password? (With root access to the system hosting nefarious)

You can change user's passwords on the settings page, but you cannot view it.

Doesn't settings require you to login though?

Hmm, somehow I had uninstalled nefarious but never shut down the port(?), anyways, for anyone looking at this issue in the future I believe setting the NEFARIOUS_USER and NEFARIOUS_PASS variables will work.

# nefarious user and password
NEFARIOUS_USER=admin
NEFARIOUS_PASS=admin

Oh, I didn't realize you got locked out.

If this happens again, you can manually change the password (e.g admin user) by running:

docker-compose exec nefarious /env/bin/python manage.py changepassword admin

@Explosion-Scratch, changing NEFARIOUS_USER and NEFARIOUS_PASS with an existing docker installation won't work unless you delete the docker volumes (e.g docker-compose down -v) since the data is persisted.

docker-compose down -v

Got it, also where is nefarious located, I'm getting this error:

➜  nefarious docker-compose exec nefarious /env/bin/python manage.py changepassword admin
ERROR: 
        Can't find a suitable configuration file in this directory or any
        parent. Are you in the right directory?

        Supported filenames: docker-compose.yml, docker-compose.yaml

I presume this is because I'm not cd'd into the right directory but I also don't have nefarious in path (which nefarious doesn't work)

Somehow it's starting on linux boot though, I remember reading something about that in the README when I installed (a few months ago) but can't find it now

You first have to cd to the directory where nefarious lives before running those docker-compose commands. Even if you delete the nefarious directory, the docker containers will still exist (via the docker daemon/init) so you'll have to manually stop & remove them.

You first have to cd to the directory where nefarious lives before running those docker-compose commands. Even if you delete the nefarious directory, the docker containers will still exist (via the docker daemon/init) so you'll have to manually stop & remove them.

And how would I go about doing that?