Page 1 of 1

Samba home directory setup

Posted: 25 Jan 2015 07:48
by v81
Seems no matter how i try i cant get home dirs setup.

The desired outcome is to have 1 main share, accessible from a windows box read only to guests, r/w to authenticated users.
And each user to have a home directory accessible from a windows box r/w, private and not accessibly to other users.
The userdirs are not to be visible in the main share.

I have 1 mount point, /data

I have 1 share, /mnt/data

I have 1 group, Home

I have 2 users
  • user1, Group=Home, Home directory= /mnt/data/user1
  • user2, Group=Home, Home directory= /mnt/data/user2
When browsing the nas as user1 only the data share appears.

How would i go about creating a private storage area and share for each user?


Thanks.

Re: Samba home directory setup

Posted: 25 Jan 2015 08:46
by b0ssman
use the forum search tool

viewtopic.php?t=2277

Re: Samba home directory setup

Posted: 26 Jan 2015 05:18
by v81
b0ssman wrote:use the forum search tool

viewtopic.php?t=2277
You say that as if i haven't already searched.
Pointing me to a closed thread with a lack of information is no help.

I want to share the home dirs, only to the users whom own them, the info in that thread just creates the dirs.
And unless i'm wrong I'd also expect to be able to do it without editing parameters.

Re: Samba home directory setup

Posted: 26 Jan 2015 10:22
by b0ssman
the second post in that thread has the information you need.

its not about creating dirs those are the samba settings.

Re: Samba home directory setup

Posted: 26 Jan 2015 15:43
by v81
Ok, have decided to add the required samba settings.
On the surface it appears to work.
Browsing the nas in Windows shows the main share and that users home share.

However if i manually type the path to another user i can gain r/w access to their share.
I'd bet several people have used the same method without realizing it isn't secure, and with only another users name you can gain read/write access to their share.

There must me a better way to do this, maybe create individual shares for each user, but for a large number of users this could become tedious.

Can anyone comment on this, or how i might go about locking down users shares so only the authenticated user can access it?

Re: Samba home directory setup

Posted: 26 Jan 2015 17:55
by v81
decided to look closer and opened a shell, found that both users folder were owned by 1 of the users.
Correcting this seems to have resolved a few issues, though no sure how it happened in the first place.

Browsing to the other users share now prompts for credentials as expected.