How to change the webgui password in pfsense from a console?

15,655

I found the way to change the password for a user from a console/ssh of a pfSense.

Fist you have to download the change admin script to your /etc/phpshellsessions with the following command > fetch -o /etc/phpshellsessions/ https://raw.githubusercontent.com/pfsense/pfsense/c07e853bb4a67a3b728b7546b36801eaef770c19/etc/phpshellsessions/changepassword

And then you run the the following: pfSsh.php playback changepassword , it will ask you the new password and to confirm the new password for the user.

After you complete the above you can try log in the webgui with the new password.

Have a nice day.

Share:
15,655

Related videos on Youtube

anksos
Author by

anksos

Systems and Network Engineer, IPv6 Certified, CCNA, Microsoft Certified in Virtualization and System Center Technologies, Open Source contributor, The Big Lebowski fan. Also check my personal site.

Updated on September 18, 2022

Comments

  • anksos
    anksos over 1 year

    Is there any way to change the password of the web GUI administrator user in pfSense from the console?

    Just to mention I didn't lock myself out from the web GUI.

  • anksos
    anksos over 9 years
    Thank you for your answer but i didn't locked out my self. I just want to find a way to change my webgui admin password from the console and not accessing the Web interface.
  • Andy
    Andy over 9 years
    Then I guess that you need only the last step. And a reboot.
  • anksos
    anksos over 9 years
    When you run the last command /etc/rc.initial.password it just reset password to 'pfsense' so you can access the webgui and change it from there. I want to change the password from the console without need of accessing the web interface.