you can use this command to restrict access to bash shell in your linux server

# bash -r

or

# rbash

In addition to the single-character shell options documented in the description of the set built-in command, bash interprets the following options when it is invoked:

-r [If the -r option is present, the shell becomes restricted]

--restricted [The shell becomes restricted]