summaryrefslogtreecommitdiffstats
path: root/source4/scripting/python/samba/samdb.py
diff options
context:
space:
mode:
authorKai Blin <kai@samba.org>2008-04-01 00:17:00 +0200
committerKai Blin <kai@samba.org>2008-04-02 23:07:53 +0200
commit8ac91d913231ecd7ead595b93032c7486f67c949 (patch)
treeb527ff7d36496e142e915091231eea9e432f4b0d /source4/scripting/python/samba/samdb.py
parentb6c48091d442781d5f22d703a00aa242de8f7226 (diff)
downloadsamba-8ac91d913231ecd7ead595b93032c7486f67c949.tar.gz
samba-8ac91d913231ecd7ead595b93032c7486f67c949.tar.xz
samba-8ac91d913231ecd7ead595b93032c7486f67c949.zip
provision: Set up id mappings in the idmap db, only map Administrator.
(This used to be commit 206b7d387c6d17e5cc40fd45b489abac9235a7a4)
Diffstat (limited to 'source4/scripting/python/samba/samdb.py')
-rw-r--r--source4/scripting/python/samba/samdb.py19
1 files changed, 0 insertions, 19 deletions
diff --git a/source4/scripting/python/samba/samdb.py b/source4/scripting/python/samba/samdb.py
index de0fd4ba046..bc3eef7879c 100644
--- a/source4/scripting/python/samba/samdb.py
+++ b/source4/scripting/python/samba/samdb.py
@@ -53,25 +53,6 @@ description: %s
for msg in self.parse_ldif(add):
self.add(msg[1])
- def setup_name_mapping(self, domaindn, sid, unixname):
- """Setup a mapping between a sam name and a unix name.
-
- :param domaindn: DN of the domain.
- :param sid: SID of the NT-side of the mapping.
- :param unixname: Unix name to map to.
- """
- res = self.search(domaindn, ldb.SCOPE_SUBTREE,
- "objectSid=%s" % sid, ["dn"])
- assert len(res) == 1, "Failed to find record for objectSid %s" % sid
-
- mod = """
-dn: %s
-changetype: modify
-replace: unixName
-unixName: %s
-""" % (res[0].dn, unixname)
- self.modify(self.parse_ldif(mod).next()[1])
-
def enable_account(self, user_dn):
"""Enable an account.