LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices


Reply
  Search this Thread
Old 04-02-2006, 03:05 AM   #1
joadoor
Member
 
Registered: Apr 2002
Location: Clevedon, UK
Distribution: SUSE 8.2, 9.2, 10.0 OSS
Posts: 57

Rep: Reputation: 15
permissions are changed when mounting


Hi all,

I currently mount a folder (/mnt/windowspc) to my windows pc and all is working fine.

However, I am currently trying to lockdown the security on files and folders and have noticed that the mount folder (/mnt/windowspc) has rwxr-xr-x root:root set on it.

When I umount and then run chmod and chown to set it to rwxrwx--- root:mygroup so that root and anyone in mygroup can do what they want, the settings are ok.
However, when I then remount, the settings are reset back to rwxr-xr-x root:root.

Am I doing something wrong / could this be done a different way.

TIA,

Andy
 
Old 04-02-2006, 04:40 AM   #2
gloomy
Member
 
Registered: Jan 2006
Location: Finland
Distribution: Mainly Gentoo
Posts: 119

Rep: Reputation: 15
What is the filesystem behind "windowspc"?

The word "windows" turns my attention to e.g. fat32, which of course does not give you the ability to change permissions. (At least to my limited understanding, as I do not use fat.)

Last edited by gloomy; 04-02-2006 at 04:42 AM.
 
Old 04-03-2006, 03:23 AM   #3
joadoor
Member
 
Registered: Apr 2002
Location: Clevedon, UK
Distribution: SUSE 8.2, 9.2, 10.0 OSS
Posts: 57

Original Poster
Rep: Reputation: 15
Thanks for the reply. Have no fear, its NTFS. However its the windowspc folder under /mnt that has the chmod settings changed when mounting.

Just thought, the moethod I am using to mount is
mount -t smbfs username=........

Would it be better to use something in fstab. Doesn't this have additonal settings that could be applied, like usergroups, readwrite or something???
 
Old 04-03-2006, 06:59 AM   #4
gloomy
Member
 
Registered: Jan 2006
Location: Finland
Distribution: Mainly Gentoo
Posts: 119

Rep: Reputation: 15
My above comment applies also (or especially) to NTFS.

Chmod and chown should have nothing to do with mounting.

But what is wrong with rwxr-xr-x root:root?

If I understood correctly, you wanted to change the write-settings - but if you are using NTFS you can not write anyhow, that is if you haven't enabled the (experimental) write-mode of NTFS in the kernel.

Generally I would prefer to have settings in the fstab but it is largely a matter of taste and practicalness. You might want to run 'man mount' and try for instance the options 'user' or 'users' to enable ordinary users to mount the file system.
 
  


Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
changed permissions, ls does not work blizunt7 Linux - General 3 09-26-2005 07:12 AM
file permissions cant be changed! shishimo Fedora 1 12-04-2004 10:23 AM
changed permissions shosh Linux - General 3 11-02-2004 05:07 AM
Something Changed File Permissions anthony114 Linux - Security 2 08-12-2003 08:53 PM
Permissions changed crashmeister Linux - Security 3 11-13-2002 07:57 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Security

All times are GMT -5. The time now is 01:31 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration