1
0
mirror of https://github.com/samba-team/samba.git synced 2025-07-27 07:42:04 +03:00

python: Fix representation of UUIDs as strings in zone files rather than binary blobs, fix escaping of LDAP URL's in PHP LDAP admin configuration.

Pair-programmed with Andrew, but git doesn't appear to support multiple --author arguments. :-(
(This used to be commit dff54ff043)
This commit is contained in:
Jelmer Vernooij
2008-01-25 03:54:33 +01:00
parent c28c683208
commit dcb04065cd
5 changed files with 19 additions and 10 deletions

View File

@ -79,7 +79,7 @@ class LdbExtensionTests(TestCaseInTempDir):
l = samba.Ldb(path)
try:
l.add({"dn": "foo=dc", "bar": "bla"})
self.assertEquals("bla", l.searchone(ldb.Dn(l, "foo=dc"), "bar"))
self.assertEquals("bla", l.searchone(basedn=ldb.Dn(l, "foo=dc"), attribute="bar"))
finally:
del l
os.unlink(path)

View File

@ -33,7 +33,7 @@ class ProvisionTestCase(samba.tests.TestCaseInTempDir):
ldb = setup_secretsdb(path, setup_path, None, None, None)
try:
self.assertEquals("LSA Secrets",
ldb.searchone(Dn(ldb, "CN=LSA Secrets"), "CN"))
ldb.searchone(basedn="CN=LSA Secrets", attribute="CN"))
finally:
del ldb
os.unlink(path)
@ -50,6 +50,14 @@ class ProvisionTestCase(samba.tests.TestCaseInTempDir):
machinepass="machinepass", dnsdomain="example.com")
self.assertEquals(1,
len(secrets_ldb.search("samAccountName=krbtgt,flatname=EXAMPLE,CN=Principals")))
self.assertEquals("keytab.path",
secrets_ldb.searchone(basedn="flatname=EXAMPLE,CN=primary domains",
expression="(privateKeytab=*)",
attribute="privateKeytab"))
self.assertEquals("S-5-22",
secrets_ldb.searchone(basedn="flatname=EXAMPLE,CN=primary domains",
expression="objectSid=*", attribute="objectSid"))
finally:
del secrets_ldb
os.unlink(path)