Restricting user to read-only access for different folders in RHEL

The name of the pictureThe name of the pictureThe name of the pictureClash Royale CLAN TAG#URR8PPP











up vote
0
down vote

favorite












I have referred all the similar questions in this site, but couldn't find out the correct answer.
My requirement is that I have a user testUser where he should only access different folders /etc/apache/ and /var/www/html as a read-only user. Apart from these folders, he shouldn't be able to access any other folder.



In the jailroot process as per my understanding, we will create a folder /home/test and we will provide him the access to these folders. But, in my case, he should be able to access different folders as I mentioned above.



Is there any quick solution for this?







share|improve this question






















  • So you'll need to expand - what other folders should this user not access and importantly, why. By default, regular users on RHEL can't damage system files, and can't read any files that are considered to have secure content. Do you mean, the user should have read access to those folders, but no ability to change anything in them, and other users do need that ability, and that you don't mind if testUser can also access other systems as 'any normal Linux user'?
    – EightBitTony
    Nov 27 '17 at 12:27






  • 1




    Is this an ftp or sftp user or a normal interactive user? If interactive, what programs should the user be able to run? Not having access to /bin and /usr/bin means not being able to do much.
    – Mark Plotnick
    Nov 27 '17 at 13:20











  • @EightBitTony, for this testUser I don't want to see any other code files as well. So, I want to restrict him to these folders only. MarkPlotnick, he is a normal interactive user and he is not having any ftp access.
    – Kiran
    Nov 28 '17 at 5:23










  • Prevent any other 'code' files from being visible to a group testUser is in, or world. Interactive users need access to the rest of the system, but you're in control of the permissions of the files you don't want them to see.
    – EightBitTony
    Nov 28 '17 at 7:45














up vote
0
down vote

favorite












I have referred all the similar questions in this site, but couldn't find out the correct answer.
My requirement is that I have a user testUser where he should only access different folders /etc/apache/ and /var/www/html as a read-only user. Apart from these folders, he shouldn't be able to access any other folder.



In the jailroot process as per my understanding, we will create a folder /home/test and we will provide him the access to these folders. But, in my case, he should be able to access different folders as I mentioned above.



Is there any quick solution for this?







share|improve this question






















  • So you'll need to expand - what other folders should this user not access and importantly, why. By default, regular users on RHEL can't damage system files, and can't read any files that are considered to have secure content. Do you mean, the user should have read access to those folders, but no ability to change anything in them, and other users do need that ability, and that you don't mind if testUser can also access other systems as 'any normal Linux user'?
    – EightBitTony
    Nov 27 '17 at 12:27






  • 1




    Is this an ftp or sftp user or a normal interactive user? If interactive, what programs should the user be able to run? Not having access to /bin and /usr/bin means not being able to do much.
    – Mark Plotnick
    Nov 27 '17 at 13:20











  • @EightBitTony, for this testUser I don't want to see any other code files as well. So, I want to restrict him to these folders only. MarkPlotnick, he is a normal interactive user and he is not having any ftp access.
    – Kiran
    Nov 28 '17 at 5:23










  • Prevent any other 'code' files from being visible to a group testUser is in, or world. Interactive users need access to the rest of the system, but you're in control of the permissions of the files you don't want them to see.
    – EightBitTony
    Nov 28 '17 at 7:45












up vote
0
down vote

favorite









up vote
0
down vote

favorite











I have referred all the similar questions in this site, but couldn't find out the correct answer.
My requirement is that I have a user testUser where he should only access different folders /etc/apache/ and /var/www/html as a read-only user. Apart from these folders, he shouldn't be able to access any other folder.



In the jailroot process as per my understanding, we will create a folder /home/test and we will provide him the access to these folders. But, in my case, he should be able to access different folders as I mentioned above.



Is there any quick solution for this?







share|improve this question














I have referred all the similar questions in this site, but couldn't find out the correct answer.
My requirement is that I have a user testUser where he should only access different folders /etc/apache/ and /var/www/html as a read-only user. Apart from these folders, he shouldn't be able to access any other folder.



In the jailroot process as per my understanding, we will create a folder /home/test and we will provide him the access to these folders. But, in my case, he should be able to access different folders as I mentioned above.



Is there any quick solution for this?









share|improve this question













share|improve this question




share|improve this question








edited Nov 27 '17 at 13:23









Videonauth

1,038718




1,038718










asked Nov 27 '17 at 12:22









Kiran

1




1











  • So you'll need to expand - what other folders should this user not access and importantly, why. By default, regular users on RHEL can't damage system files, and can't read any files that are considered to have secure content. Do you mean, the user should have read access to those folders, but no ability to change anything in them, and other users do need that ability, and that you don't mind if testUser can also access other systems as 'any normal Linux user'?
    – EightBitTony
    Nov 27 '17 at 12:27






  • 1




    Is this an ftp or sftp user or a normal interactive user? If interactive, what programs should the user be able to run? Not having access to /bin and /usr/bin means not being able to do much.
    – Mark Plotnick
    Nov 27 '17 at 13:20











  • @EightBitTony, for this testUser I don't want to see any other code files as well. So, I want to restrict him to these folders only. MarkPlotnick, he is a normal interactive user and he is not having any ftp access.
    – Kiran
    Nov 28 '17 at 5:23










  • Prevent any other 'code' files from being visible to a group testUser is in, or world. Interactive users need access to the rest of the system, but you're in control of the permissions of the files you don't want them to see.
    – EightBitTony
    Nov 28 '17 at 7:45
















  • So you'll need to expand - what other folders should this user not access and importantly, why. By default, regular users on RHEL can't damage system files, and can't read any files that are considered to have secure content. Do you mean, the user should have read access to those folders, but no ability to change anything in them, and other users do need that ability, and that you don't mind if testUser can also access other systems as 'any normal Linux user'?
    – EightBitTony
    Nov 27 '17 at 12:27






  • 1




    Is this an ftp or sftp user or a normal interactive user? If interactive, what programs should the user be able to run? Not having access to /bin and /usr/bin means not being able to do much.
    – Mark Plotnick
    Nov 27 '17 at 13:20











  • @EightBitTony, for this testUser I don't want to see any other code files as well. So, I want to restrict him to these folders only. MarkPlotnick, he is a normal interactive user and he is not having any ftp access.
    – Kiran
    Nov 28 '17 at 5:23










  • Prevent any other 'code' files from being visible to a group testUser is in, or world. Interactive users need access to the rest of the system, but you're in control of the permissions of the files you don't want them to see.
    – EightBitTony
    Nov 28 '17 at 7:45















So you'll need to expand - what other folders should this user not access and importantly, why. By default, regular users on RHEL can't damage system files, and can't read any files that are considered to have secure content. Do you mean, the user should have read access to those folders, but no ability to change anything in them, and other users do need that ability, and that you don't mind if testUser can also access other systems as 'any normal Linux user'?
– EightBitTony
Nov 27 '17 at 12:27




So you'll need to expand - what other folders should this user not access and importantly, why. By default, regular users on RHEL can't damage system files, and can't read any files that are considered to have secure content. Do you mean, the user should have read access to those folders, but no ability to change anything in them, and other users do need that ability, and that you don't mind if testUser can also access other systems as 'any normal Linux user'?
– EightBitTony
Nov 27 '17 at 12:27




1




1




Is this an ftp or sftp user or a normal interactive user? If interactive, what programs should the user be able to run? Not having access to /bin and /usr/bin means not being able to do much.
– Mark Plotnick
Nov 27 '17 at 13:20





Is this an ftp or sftp user or a normal interactive user? If interactive, what programs should the user be able to run? Not having access to /bin and /usr/bin means not being able to do much.
– Mark Plotnick
Nov 27 '17 at 13:20













@EightBitTony, for this testUser I don't want to see any other code files as well. So, I want to restrict him to these folders only. MarkPlotnick, he is a normal interactive user and he is not having any ftp access.
– Kiran
Nov 28 '17 at 5:23




@EightBitTony, for this testUser I don't want to see any other code files as well. So, I want to restrict him to these folders only. MarkPlotnick, he is a normal interactive user and he is not having any ftp access.
– Kiran
Nov 28 '17 at 5:23












Prevent any other 'code' files from being visible to a group testUser is in, or world. Interactive users need access to the rest of the system, but you're in control of the permissions of the files you don't want them to see.
– EightBitTony
Nov 28 '17 at 7:45




Prevent any other 'code' files from being visible to a group testUser is in, or world. Interactive users need access to the rest of the system, but you're in control of the permissions of the files you don't want them to see.
– EightBitTony
Nov 28 '17 at 7:45















active

oldest

votes











Your Answer







StackExchange.ready(function()
var channelOptions =
tags: "".split(" "),
id: "106"
;
initTagRenderer("".split(" "), "".split(" "), channelOptions);

StackExchange.using("externalEditor", function()
// Have to fire editor after snippets, if snippets enabled
if (StackExchange.settings.snippets.snippetsEnabled)
StackExchange.using("snippets", function()
createEditor();
);

else
createEditor();

);

function createEditor()
StackExchange.prepareEditor(
heartbeatType: 'answer',
convertImagesToLinks: false,
noModals: false,
showLowRepImageUploadWarning: true,
reputationToPostImages: null,
bindNavPrevention: true,
postfix: "",
onDemand: true,
discardSelector: ".discard-answer"
,immediatelyShowMarkdownHelp:true
);



);













 

draft saved


draft discarded


















StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f407276%2frestricting-user-to-read-only-access-for-different-folders-in-rhel%23new-answer', 'question_page');

);

Post as a guest



































active

oldest

votes













active

oldest

votes









active

oldest

votes






active

oldest

votes















 

draft saved


draft discarded















































 


draft saved


draft discarded














StackExchange.ready(
function ()
StackExchange.openid.initPostLogin('.new-post-login', 'https%3a%2f%2funix.stackexchange.com%2fquestions%2f407276%2frestricting-user-to-read-only-access-for-different-folders-in-rhel%23new-answer', 'question_page');

);

Post as a guest













































































Popular posts from this blog

How to check contact read email or not when send email to Individual?

Displaying single band from multi-band raster using QGIS

How many registers does an x86_64 CPU actually have?