Logic Machine Forum
Lost password - Printable Version

+- Logic Machine Forum (https://forum.logicmachine.net)
+-- Forum: LogicMachine eco-system (https://forum.logicmachine.net/forumdisplay.php?fid=1)
+--- Forum: General (https://forum.logicmachine.net/forumdisplay.php?fid=2)
+--- Thread: Lost password (/showthread.php?tid=1528)



Lost password - zoltan - 10.08.2018

Hello,

I've lost the password file for several LM-s that I installed last summer. 
Is there any way to recover the password? Maybe login over serial console?

I have the backup files (*.tar.gz) for them intact.


RE: Lost password - Daniel - 10.08.2018

Hi
Sorry only HW factory reset. If you have backup you can restore project.
BR


RE: Lost password - zoltan - 10.08.2018

(10.08.2018, 15:32)Daniel. Wrote: Hi
Sorry only HW factory reset. If you have backup you can restore project.
BR

Backup is with forgotten password in it. Or the password doesn't goes into backup?


RE: Lost password - Daniel - 10.08.2018

No admin pass in backup. Old fw did contain user passwords as plain text but in latest even this is encrypted.


RE: Lost password - zoltan - 10.08.2018

(10.08.2018, 15:48)Daniel. Wrote: No admin pass in backup. Old fw did contain user passwords as plain text but in latest even this is encrypted.

Ah, thanks!

Any way to login via serial console?


RE: Lost password - admin - 10.08.2018

If you can connect SD card to Linux then it's possible to set password via config file edit.


RE: Lost password - zoltan - 10.08.2018

(10.08.2018, 16:34)admin Wrote: If you can connect SD card to Linux then it's possible to set password via config file edit.

That was my next question.

So I've mounted the SD-card (I don't have the actual card with me, this is one that went read only), and...

Code:
/etc/httpd.conf
/cgi-bin/flashsys/:admin:$1$$Sde5XDOHY.2lYrKCR7Gbr.
/cgi-bin/scada/:admin:$1$$Sde5XDOHY.2lYrKCR7Gbr.
/cgi-bin/scada-remote/:admin:$1$$Sde5XDOHY.2lYrKCR7Gbr.
/cgi-bin/scada-remote/:remote:$1$$Bj7xk3bdiIWoVguAr/ugf.

looks like the winner.

Is this MD5 or SHA-1? Can I just copy the above pasted hash?

/etc/shadow doesn't contain the hash for admin


RE: Lost password - admin - 10.08.2018

You have to edit /etc/config/httpd
Set password in plain text, it will get hashed during next boot


RE: Lost password - zoltan - 10.08.2018

(10.08.2018, 17:43)admin Wrote: You have to edit /etc/config/httpd
Set password in plain text, it will get hashed during next boot

Thanks! I'll try that tomorrow.


RE: Lost password - zoltan - 12.08.2018

For future reference:

If you lost your password do the following:

- Take out the SD-card
- Mount it on any linux system (parttition 2)
- Edit /etc/config/httpd:
Code:
config user 'admin'
       option password 'ThisIsYourNewPassword'
- Unmount, put back the SD--card
- Login as admin with password ThisIsYourNewPassword
- Done!

On older versions the file is located in /etc/httpd.conf and looks a bit differently


RE: Lost password - izhlight - 17.04.2021

Hello! I have a similar problem, but more varied. lost administrator passwords for LM5light, lm2 and LogicMachine: loadballancer. Backups lost, programmer dead - covidSad The manual described above is not suitable for lm2, there is no removable sd-card.  Resetting it to factory settings will destroy at least six months of work, which is unacceptable... I will be very grateful for any advice and ideas to solve this problem.


RE: Lost password - admin - 19.04.2021

Sorry to hear that. Since LoadBalancer is a PC you can connect a monitor and a keyboard, go to BIOS, enable boot from USB and use a Linux live USB to access the on-board eMMC. The main partition should be either /dev/mmcblk0p1 or /dev/mmcblk0p2. Make sure to use a newer live USB distribution as older one won't have eMMC support. As for old LM2, check if SSH is enabled. If it is enabled then can you provide remote access so I can reset the password?