nautilus-share can't share ntfs/fat32 folders

Bug #214420 reported by Rocko
14
This bug affects 1 person
Affects Status Importance Assigned to Milestone
nautilus-share (Baltix)
New
Undecided
Unassigned
nautilus-share (Ubuntu)
Incomplete
Undecided
Unassigned

Bug Description

Binary package hint: nautilus-share

To reproduce this bug, do the following without root privileges:

1. Select a folder in an ntfs partition (in my case, it's an internal partition mounted via fstab as /c - my user has full access to the drive).

2. Right-click, select sharing options, configure it and press 'create share'.

3. Nautilus says it needs to alter the properties of the folder. Select the 'automatic' option.

4. Nautilus says it can't alter the properties.

Note that if you do this process with root privileges, it works fine.

I would expect that nautilus-share should ask you for the admin password if it finds it doesn't have permission.

(Note that if you try this on an ext3 root folder where you don't have access permissions, nautilus-share tells you that you can't share it.)

package versions:

Ubuntu 8.04
nautilus 1:2.22.2-0ubuntu2
nautilus-share 0.7.2-0ubuntu4

Revision history for this message
Patrice Vetsel (vetsel-patrice) wrote :

usershare is set to not allow users to share directories that they are not owners. It's a security parameter.

Changed in nautilus-share:
status: New → Invalid
Revision history for this message
Rocko (rockorequin) wrote :

But my comment still holds true: nautilus-share should prompt for an admin password if it can't share the directory. Or it should tell you that it can't share it because you don't own it (as it does for ext3 partitions).

On a related note, perhaps the installer should automatically add uid=1000,gid=1000 to the /etc/fstab mount entry for ntfs drives so that this problem doesn't occur?

Rocko (rockorequin)
Changed in nautilus-share:
status: Invalid → New
Revision history for this message
Duncan Hawthorne (duncan.hawthorne) wrote :

patrice vetsel and rocko:
the problems here are twofold

when nautilus says it needs to alter the permissions of the folder, this is not about altering the owner of the folder, but giving the group "others" read,write,execute permissions. the folder needs to have those permissions so that it can be read over the network.
now on reason why it cant alter the permissions of the folders because you are not the owner, but this is a different stage to sharing it.
it is also true that if you are not the owner you are not allowed to share the folder (unless you edit smb.conf of start nautilus as root)

note also that even if you were the owner, you couldnt change the permissions, because ntfs/vfat dont support individual file permissions. to change the permissions it needs to edit the fstab entry for the drive. the actual fact of you owning the drive is irrelevant therefore in this case to whether you can change the permissions, as it is superseded by the fstab thing.

i made bug #255391 about the ntfs drive not having the right permissions by default that it needs to be able to be read across the network. once that is changed it will just be the case of the owner problem. then all users need to do is make the edit to smb.conf as suggested in the gui (or run gksu nautilus)

Revision history for this message
Nicolò Chieffo (yelo3) wrote :

Why the group others must have read permissions?? This should be valid only if browsing as the anonymouns user, but if we require samba authentication, than it should be enough to set the permissions for the authenticated user..

Revision history for this message
Matthew McGowan (mmcg069) wrote :

This bug is a real frustration, and the error response is horrible. Could an Unlock button be added and the appropriate entry be made in the smb.conf or what ever is best practice in this scenario?

Revision history for this message
Rocko (rockorequin) wrote :

I think the last two comments would be better directed at bug #255391, because this one is about local partitions, not network shares.

Revision history for this message
Rocko (rockorequin) wrote :

Sorry, I was mistaken. I confused this bug with another one describing how you can only delete files on an ntfs partition and not move them to trash. In that bug, the point was made that windoze doesn't treat ntfs as secure, so why should Ubuntu? This point applies to samba shares, too.

Revision history for this message
Chow Loong Jin (hyperair) wrote : Re: [Bug 214420] Re: nautilus-share can't share ntfs/fat32 folders

On Thu, 2009-05-07 at 07:26 +0000, mmnz wrote:
> This bug is a real frustration, and the error response is horrible.
> Could an Unlock button be added and the appropriate entry be made in
> the smb.conf or what ever is best practice in this scenario?
>
Could you be clearer about the error response you get? If I'm not
mistaken, the issue you're probably getting is that you cannot share
what does not belong to you (owner = your username). If you're getting
that, then it's a bug in how you mounted your fat32 volume, not in
nautilus-share. USB drives which are formatted using fat32 have a
uid=<your userid> argument passed in when mounted automatically in
Ubuntu, and these can be shared perfectly fine. I have not tested with
NTFS, but chances are that it is the same.
--
Regards,
Chow Loong Jin

Revision history for this message
Chow Loong Jin (hyperair) wrote :

Marking as incomplete, because more information is needed, as per my last post

Changed in nautilus-share (Ubuntu):
status: New → Incomplete
Revision history for this message
Rocko (rockorequin) wrote :

This is a usability bug. The behaviour has improved considerably in Jaunty, eg:

1. Attach an ntfs external drive.

2. Try to share a folder through nautilus.

3. The share dialog says:

'net usershare' returned error 255: net usershare add: cannot share path /media/disk1/test as we are restricted to only sharing directories we own.
 Ask the administrator to add the line "usershare owner only = false"
 to the [global] section of the smb.conf to allow this.

4. If you follow the instructions and then click on the 'share' button, samba shares the folder (and there's no need to restart samba).

A more user-friendly option would be the alternative steps 3 and 4:

3. Assuming that the current user has admin rights, the share dialog presents a window that explains you need to enable sharing of non-owned folders, and to prompt for the admin password to do so.

4. Upon entry of the admin password, samba alters its smb.conf file and shares the folder.

Revision history for this message
Matthew McGowan (mmcg069) wrote :

On 30/06/09 13:18, Rocko wrote:
> This is a usability bug. The behaviour has improved considerably in
> Jaunty, eg:
>
> 1. Attach an ntfs external drive.
>
> 2. Try to share a folder through nautilus.
>
> 3. The share dialog says:
>
> 'net usershare' returned error 255: net usershare add: cannot share path /media/disk1/test as we are restricted to only sharing directories we own.
> Ask the administrator to add the line "usershare owner only = false"
> to the [global] section of the smb.conf to allow this.
>
> 4. If you follow the instructions and then click on the 'share' button,
> samba shares the folder (and there's no need to restart samba).
>
>
> A more user-friendly option would be the alternative steps 3 and 4:
>
> 3. Assuming that the current user has admin rights, the share dialog
> presents a window that explains you need to enable sharing of non-owned
> folders, and to prompt for the admin password to do so.
>
> 4. Upon entry of the admin password, samba alters its smb.conf file and
> shares the folder.
>
>
Hi, yes that is the error i get, Rocko's suggested steps 3 and 4 are
inline with what i had in mind...

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.