Comment 13 for bug 24184

Revision history for this message
Huygens (huygens-25) wrote :

Thank you Eric for your work :-) that is a nice initiative.

However, there is a caveat with your approach and the one taken in Bug 103708. The problem is that it tends to associate a share with a credential. Nevertheless, credentials in Samba are "samba-wide", meaning there can only be one login/password combination for all the shares in Samba. So if the user set a specific login for share A and define the password. When later he wants to create a new share (let's call it B), and he wants to access it using the same specific login, there is no need for him to use the same password.
If we had the user credentials definition in the GUI that share a folder, we will make the end-user think that a credential is bound to a share, which is not the case in Samba configuration (apart a few exceptions like home directories).

So a more logical place would be a central Samba configuration GUI like the one which can be found in System->Administration->Shared folders. Where you can click to set Samba-wide settings such as the domain/workgroup for the computer, etc. However, in the end-user logic, this is not the expected place, and if we put it here, I'm sure we will find countless forum posts about where to set Samba password.

A work-around solution would be to present to a user when he first shares a folder a specific GUI where he can set Samba-wide parameters (such as the domain/workgroup and his credentials). There is however another caveat, which is when there are multiple user at home. If user A install Ubuntu and share folder /tmp. User B, who is using another machine on the network and who knows about the share, wants to access it. User B enters his login name and password and the access is refused. User A would then need to understand that he should create a local user named B and then create the Samba credentials. Unless he is an IT guy, this might not be obvious to him.

Another idea could be have a simplified sharing mechanism for home users. Where a guest account is activate by default so when a share is opened, people on their network can view them (but not modified them). Then we could imagine that the smbpasswd would be automatically created when a user is created (meaning also in the Ubuntu installation process). If a user set his login credentials, he could then access read/write the shares.
There are some caveats to that, mainly for SOHO, Enterprises and enthusiasts where they do not want to have a smb account for each user they are creating. They probably do not want the guest account thing, etc.

So, I do not have solution to this problem. The approach of Windows (at least until XP, I have not seen Vista yet) is equally not satisfying, so we cannot get inspiration from there. As for how the case is handle on a Mac, I have no clue! What about the other Linux distro or the BSD*? Does anyone knows how it is done on them?