how to make every user like to be in a virtual server please help

mido0z0

Member
Oct 18, 2019
7
0
1
usa
cPanel Access Level
Root Administrator
i dont know how to search for it
what i mean that when you login to a cpanel and trying to read /etc/passwd it show you couple of users but dont show the real /etc/passwd
i mean fake /etc/passwd for every user also many files in the server not visible to any user cpanel just when the user cat /etc/passwd he see himself only and the system users like root mailman cpaneleximfilter etc
how can i make it in my whm root server
please help
 

cPanelLauren

Product Owner
Staff member
Nov 14, 2017
13,296
1,252
313
Houston
I think you might be talking about CloudLinux's CageFS? Though I'm unaware of a "fake" /etc/passwd, CageFS restricts users to their own data - CloudLinux - Main | New template
 

cPanelLauren

Product Owner
Staff member
Nov 14, 2017
13,296
1,252
313
Houston
I think you might mean Jailshell? If you go to WHM>>Account Functions>>Manage Shell Access -> Set Jail Shell for a user they won't be able to see other cPanel users in /etc/passwd
 

cPanelLauren

Product Owner
Staff member
Nov 14, 2017
13,296
1,252
313
Houston
I think you may be mistaken, did you log out between changing the shell type? I tested this before my previous response and confirmed I could not see other cPanel users.
 

mido0z0

Member
Oct 18, 2019
7
0
1
usa
cPanel Access Level
Root Administrator
i setup mod_ruid2 and its prevent the symlink, thats why im asking about what i need to add for my server i was thinking its a apache plugin to be setup like mod_ruid2
 

cPanelLauren

Product Owner
Staff member
Nov 14, 2017
13,296
1,252
313
Houston
How are you testing? I can show the differences:

I have a test server with three users cptest, owned and reseller

On the cptest account I access ssh with normal shell and I can see the following in /etc/passwd:

Code:
[[email protected] ~]$ egrep 'cptest|owned|reseller' /etc/passwd
cptest:x:503:503::/home/cptest:/bin/bash
reseller:x:504:504::/home/reseller:/bin/bash
owned:x:505:505::/home/owned:/bin/bash
When I log out and change shell to jailed shell I see the following when I log back in:

Code:
[[email protected] ~]$ egrep 'cptest|owned|reseller' /etc/passwd
cptest:x:503:503::/home/cptest:/usr/local/cpanel/bin/jailshell