ClearFoundation Tracker - ClearOS
View Issue Details
0007711ClearOSapp-samba-directory - Samba Directorypublic2016-03-14 19:542016-04-05 09:45
user2 
user2 
normalmajorhave not tried
closedfixed 
7.2.0 
7.2.0 Updates7.2.0 Updates 
0007711: Samba Directory "administrator" account is problematic
One of the gotchas discussed during the Samba Directory beta was the unusual behavior of the Windows "Administrator" account. When the Samba 4 Directory initializes, the "administrator" account takes on a UID of 0 (?). So running as the "root" user, you see:

# id
uid=0(administrator) gid=0(root) groups=0(root)

Wah? I'm not sure what's going on here, but it seemed to work okay during the early beta. However, since ClearOS 7.2 (or earlier?), the Samba Directory provisioning seems to fail due to this uid-ness. Instead of running scripts with UID=0/root, the system is using UID=0/administrator. Here's an example of a sudoers error in the /var/log/system log file:

Mar 14 11:52:04 localhost engine: exception: error: /usr/clearos/apps/base/libraries/Shell.php (207): administrator is not in the sudoers file. This incident will be reported.

Can we prevent the Samba 4 Directory behavior? Are we missing a step somewhere?
No tags attached.
related to 0007991closed  Samba Directory "administrator" uid=0 is problematic 
Issue History
2016-03-14 19:54user2New Issue
2016-03-14 19:58user2Statusnew => acknowledged
2016-03-15 03:27bchambersNote Added: 0002821
2016-03-15 11:42dloperNote Added: 0002861
2016-03-29 13:31user2Statusacknowledged => resolved
2016-03-29 13:31user2Fixed in Version => 7.2.0 Updates
2016-03-29 13:31user2Resolutionopen => fixed
2016-03-29 13:31user2Assigned To => user2
2016-04-04 18:55user2Statusresolved => closed
2016-04-05 09:45user2Issue cloned: 0007991
2016-04-05 09:45user2Relationship addedrelated to 0007991

Notes
(0002821)
bchambers   
2016-03-15 03:27   
Relevant???

"The problem is that there are two ways to use the windows user
'Administrator' on a Unix machine, you can map 'Administrator' to the
Unix user 'root' via a line in smb.conf and a mapping file, this is the
easiest way.
You can also give the 'Administrator' user a uidNumber, this turns it
into a normal Unix user and further setup is required to allow this user
to work as the root user, something that in essence gives you two 'root'
users and is probably not a good idea.

I will think how to edit the page, I do not think giving a uidNumber to
'Administrator' is a good idea and probably the wiki shouldn't show it.

Rowland"

Ref: https://groups.google.com/forum/#!topic/linux.samba/8y7TdrinYzg [^]
(0002861)
dloper   
2016-03-15 11:42   
Something to try...map it to root:

https://lists.samba.org/archive/samba/2013-May/173658.html [^]