TransWikia.com

Protected shell in embedded linux

Reverse Engineering Asked by Meryy on January 3, 2021

When I run telnetd -l /bin/sh on an embedded Linux device and use Putty to telnet to it, the provided shell is /bin/psh (protected shell).

On this device, /bin/sh is a symbolic link to /bin/busybox.

Where I can see on this system that /bin/sh redirects to /bin/psh?

How can I change it if /bin is read only?

One Answer

First you can ask where the shell lies with which sh. The command tells the full path.

Then, you can use ls - al to view whether or not that is a symbolic link on its own or not.

Once you have found the original shell you know whether or not it fits your need.

To change the shell for the user you are using, you have plenty of choices, depending on whether or not you are root. Have a look here to have an idea.

If, instead, you want to change where the symbolic link points, you can you have to be root and use the ln command. Keep in mind that changing the shell in this way can have serious unwanted consequences.

Answered by Yennefer on January 3, 2021

Add your own answers!

Ask a Question

Get help from others!

© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP