I have an IP-camera with the BusyBox v1.22.1 operating system that has some accounts either without or with public known passwords that I want to change to make it more secure. I have managed to log in to the root account via telnet but could initially not change password or users. The filesystem is squashfs and except the /tmp and /home directories all other direcories are mounted as read only.

After some searches on the internet I found a way to change the contents of files in the /etc directory where the password and shadow files are stored. I used bind-mounting of a copy of the /etc directory in the /home directory as the /tmp directory was nor persistent during reboot. /tmp is probably just stored in ram memory. I used the following command:

cp -a /etc /home/tst && mount --bind /home/tst/etc /etc

but the bind-mount is not persistent during reboot so I need to find a file that is exceuted in the boot process that does the binding (eg where I can put the "mount --bind /home/tst/etc /etc" command) as the files in the /home directory is not affected by reboot.

What file would be good to have the mount --bind command in, preferably a file in the /home directory that is executed in the last part of the boot process so it is not overridden by some other command?

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.