ownership on ".." double dot directories.
ok I have a dumb question...I know, I know. all my question on here are dumb.
I created a user yesterday and when cd into their account and do a ls -alh I see something strange. Code:
drwxr--r-- 2 user1 country 4.0K Jul 8 07:14 . I want to know if there is a flag that can be used to specify changing ownership from SUPER-USER:Country back to user1:country on the ".." directory....I know its not a real directory but for the sake of this thread that is what I will refer to it as. any help would be appreciated. I have changed it before, but been working like a dog lately, and cant remember how I did it. |
.. is indeed a real directory, it's the one above the one you've listed (normally /home). If what you've listed is the user's home directory, you don't want to be giving them ownership of anything above that.
That's an unusual setup you have there. Normally /home has root root ownership. I've never heard of SUPER-USER as a user - it sounds like an artificial creation to me. Also .profile and .bash_profile normally have user ownership, not root. Are you sure that this is Ubuntu you're running (according to the info in your sidebar)? |
Quote:
that is true, I do not want them to have ownership of the directory above their home directory. Maybe I'm just dumb and not thinking about this correctly. I have just remember have to change this in the past or users were not able to get their .menu, but a command prompt instead. IDK. maybe I'm just too tired and not thinking straight. Thanks for you help. |
chris_carr, something is VERY, VERY WRONG with your system.
for comparison, this is what this command gives on my system (debian stable): Code:
$ ls -alh 1) there's no group "country"! 2) no file should have -rwxrwxrwx permissions, which equals 777. 3) .. should be root:root, and nothing else 4) ~/.profile should be user owned are you sure you know what you're doing? do you even understand the output of "ls -alh"? |
Actually a group country is certainly possible; its just unusual, especially on a home machine.
The rest is indeed very odd... |
Let's forget the strange setup ... That's clearly his modification (and beside the SUPER-USER thing, that should simply be root, it's nothing that strange)...
@chris_carr: hydrurga already gave you the answer to this... "/home/user/.." is actually "/home" and changing the permission to one of them equals changing the other one... Now here's the thing, the /home should have permision "drwxr-xr-x root:root" on your setup... This is important because of security reasons (only root should be able to create a file/directory there or delete one, others should be able just read that content and enter the directory). If you want a specific user to mangle that directory, use extended ACLs. |
Thank you guys. I realized my mistake after a few more cups of coffee. not sure what I was thinking.
Glad everyone had a laugh at this. Trust me nobody is more confused by the set up than me....however I cant just go changing things willy nilly on a live production machine. on my QA box the permission are corrected, and that was after months of testing trying to get the right permissions to work with these stupid menus. I know it sounds and looks crazy, but trust me, you make one minor change to permissions and the menu no longer works. and for the record THIS IS NOT MY DESIGN. I was hired to clean this crap up. |
^ good, glad you see it & solved it.
Quote:
of course all this is possible on a linux box. that's the beauty of it. but for almost all intents and purposes it is still wrong to do so. i see this quite often, the long-time linux users and forum power posters start pointing out each other's logical mistakes, but for the OP with less than 10 posts and less than a year of linux experience, well the OP just needs some clear guidance & unambiguous explanations, no? |
Of course we can still chat about this. I would love any input or suggestions to make my box more secure.
|
All times are GMT -5. The time now is 10:30 PM. |