[Samba] change winbind use default domain at a later stage

2013-09-04 Thread Coert Waagmeester
Hello all,

Running Samba 3.6.9, member of a windows 2008r2 domain.
We have two domains (OLD and NEW), with a full trust relationship
between them.

The samba server is joined to domain NEW, and I have not set "winbind
use default domain"

Everything works as expected, I added the OLD domain to krb5.conf as
well, so with wbinfo I can see users and groups from both NEW and OLD.

I have set up samba with a root preexec script that creates a home
directory the first time for a domain user, in the form /home/DOMAIN/USER

The idea is to ultimately get rid of OLD domain.

Can I change "winbind use default domain" without causing problems?

Will that allow me to login with USERNAME for the NEW domain, and also
with OLD+USERNAME for the OLD domain?


Thank you in advance,
Coert Waagmeester
-- 
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


Re: [Samba] custom permission for single user deep in tree where he has no access

2013-06-18 Thread Coert Waagmeester



On 2013/06/11 09:56 AM, Coert Waagmeester wrote:

Hello all,

Got samba with AD integration and extended ACL up and running.

Here is what I am trying to do.

share1 in smb.conf:
 [share1]
 comment = share1
 path = /mnt/data/share1
 public = no
 writable = yes
 printable = no
 valid users = @DOMAIN+group1

user1 and user2 are members of group1
user3 is not

user1 creates \\server\share1\dir1\user3
user1 grants permission only on the user3 directory to user3, not on any
parent directories

according to what I experienced with a windows file server, user3 should
be able to access this folder on:
\\server\share1\dir1\user3

But I get access denied with this samba setup.

Are there any configuration directives I am missing?

Kind regards,
Coert Waagmeester

PS HERE is my smb.conf:
#=== Global Settings
=
[global]
 workgroup = DOMAIN
 server string = DOMAIN File server
# --- Logging Options -
 log file = /var/log/samba/log.%m
 max log size = 50
# --- Domain Members Options 
 security = domain
 passdb backend = tdbsam
 realm = DOMAIN.LOCAL

 winbind enum users = Yes
 winbind enum groups = Yes
 ;winbind use default domain = Yes
 winbind nested groups = Yes
 winbind separator = +
 idmap config * : range = 6000-2
 idmap config * : backend = tdb
 ;idmap uid = 6000-2
 ;idmap gid = 6000-2
 ;template primary group = "Domain Users"
 template shell = /sbin/nologin
 template homedir = /mnt/data/DOMAIN/home/%D/%U
 root preexec = /usr/local/sbin/mkhomedir.sh %D %U
;   password server = 
# --- Printing Options
-
 load printers = yes
 cups options = raw
;   printcap name = /etc/printcap
 #obtain list of printers automatically on SystemV
;   printcap name = lpstat
;   printing = cups
# --- Filesystem Options
---
map archive = yes
map hidden = yes
map read only = yes
map system = yes
store dos attributes = yes
# Share Definitions
==
[homes]
 comment = Home Directories
 browseable = no
 writable = yes
 create mask = 0700
 directory mask = 0700
[printers]
 comment = All Printers
 path = /var/spool/samba
 browseable = no
 guest ok = no
 writable = no
 printable = yes

[share1]
 comment = share1
 path = /mnt/data/share1
 public = no
 writable = yes
 printable = no
 ;write list = +staff
 valid users = @DOMAIN+group1, DOMAIN+user3


Hello all,

Found out how to solve this.
On the tree to the directory where the user needs access, he needs UNIX 
execute permission.


This works well so far, he cannot read or list anything apart from the 
directory in the tree where he needs rw access.


Regards,
Coert Waagmeester
--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba


[Samba] custom permission for single user deep in tree where he has no access

2013-06-11 Thread Coert Waagmeester

Hello all,

Got samba with AD integration and extended ACL up and running.

Here is what I am trying to do.

share1 in smb.conf:
[share1]
comment = share1
path = /mnt/data/share1
public = no
writable = yes
printable = no
valid users = @DOMAIN+group1

user1 and user2 are members of group1
user3 is not

user1 creates \\server\share1\dir1\user3
user1 grants permission only on the user3 directory to user3, not on any 
parent directories


according to what I experienced with a windows file server, user3 should 
be able to access this folder on:

\\server\share1\dir1\user3

But I get access denied with this samba setup.

Are there any configuration directives I am missing?

Kind regards,
Coert Waagmeester

PS HERE is my smb.conf:
#=== Global Settings 
=

[global]
workgroup = DOMAIN
server string = DOMAIN File server
# --- Logging Options -
log file = /var/log/samba/log.%m
max log size = 50
# --- Domain Members Options 
security = domain
passdb backend = tdbsam
realm = DOMAIN.LOCAL

winbind enum users = Yes
winbind enum groups = Yes
;winbind use default domain = Yes
winbind nested groups = Yes
winbind separator = +
idmap config * : range = 6000-2
idmap config * : backend = tdb
;idmap uid = 6000-2
;idmap gid = 6000-2
;template primary group = "Domain Users"
template shell = /sbin/nologin
template homedir = /mnt/data/DOMAIN/home/%D/%U
root preexec = /usr/local/sbin/mkhomedir.sh %D %U
;   password server = 
# --- Printing Options -
load printers = yes
cups options = raw
;   printcap name = /etc/printcap
#obtain list of printers automatically on SystemV
;   printcap name = lpstat
;   printing = cups
# --- Filesystem Options ---
   map archive = yes
   map hidden = yes
   map read only = yes
   map system = yes
   store dos attributes = yes
# Share Definitions 
==

[homes]
comment = Home Directories
browseable = no
writable = yes
create mask = 0700
directory mask = 0700
[printers]
comment = All Printers
path = /var/spool/samba
browseable = no
guest ok = no
writable = no
printable = yes

[share1]
comment = share1
path = /mnt/data/share1
public = no
writable = yes
printable = no
;write list = +staff
valid users = @DOMAIN+group1, DOMAIN+user3
--
To unsubscribe from this list go to the following URL and read the
instructions:  https://lists.samba.org/mailman/options/samba