[SCM] Samba Shared Repository - branch v4-0-test updated
Karolin Seeger
kseeger at samba.org
Fri Nov 16 02:55:05 MST 2012
The branch, v4-0-test has been updated
via 02ca126 s4:samba-tool: Fix samba-tool fsmo --role=schema
via f3ab644 lib/addns: remove compiler warnings
via 1236393 lib/addns: don't depend on the order in resp->answers[]
via dd9a98c lib/addns: remove pointless check for resp->num_additionals != 1
from 3f5b4ed lib/replace: replace all *printf function if we replace snprintf (bug #9390)
http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v4-0-test
- Log -----------------------------------------------------------------
commit 02ca1263cfd793b7512d7bd9eccce786794e63f6
Author: Arvid Requate <requate at univention.de>
Date: Wed Nov 14 15:51:19 2012 +0100
s4:samba-tool: Fix samba-tool fsmo --role=schema
Fix traceback:
samba-tool fsmo --role=schema --force
ERROR(<type 'exceptions.TypeError'>): uncaught exception - argument 2 must be string, not ldb.Dn
File "/usr/lib/python2.6/dist-packages/samba/netcmd/__init__.py", line 168, in _run
return self.run(*args, **kwargs)
File "/usr/lib/python2.6/dist-packages/samba/netcmd/fsmo.py", line 160, in run
self.seize_role(role, samdb, force)
File "/usr/lib/python2.6/dist-packages/samba/netcmd/fsmo.py", line 119, in seize_role
m.dn = ldb.Dn(samdb, self.schema_dn)
Reviewed-by: Andrew Bartlett <abartlet at samba.org>
Autobuild-User(master): Andrew Bartlett <abartlet at samba.org>
Autobuild-Date(master): Fri Nov 16 00:40:24 CET 2012 on sn-devel-104
(cherry picked from commit ace0909b88739338e948b9c1e98307f324bb7503)
Fix bug #9392 - Traceback in samba-tool fsmo --role=schema.
Autobuild-User(v4-0-test): Karolin Seeger <kseeger at samba.org>
Autobuild-Date(v4-0-test): Fri Nov 16 10:54:29 CET 2012 on sn-devel-104
commit f3ab644246e85b32b06ae50e7a83f09264a4a7ae
Author: Stefan Metzmacher <metze at samba.org>
Date: Fri Nov 9 09:08:51 2012 +0100
lib/addns: remove compiler warnings
Signed-off-by: Stefan Metzmacher <metze at samba.org>
Reviewed-by: Andrew Bartlett <abartlet at samba.org>
(cherry picked from commit 1ecc76b2480c884a66e598ff6b1f9000bb0931c0)
The last 3 patches address bug #9402 - lib/addns doesn't work samba4 with a
bind9 server.
commit 1236393fbeca02acdfecdcc223e0fd421599157f
Author: Stefan Metzmacher <metze at samba.org>
Date: Fri Nov 9 08:59:36 2012 +0100
lib/addns: don't depend on the order in resp->answers[]
Signed-off-by: Stefan Metzmacher <metze at samba.org>
Reviewed-by: Andrew Bartlett <abartlet at samba.org>
(cherry picked from commit eecc1d294256210ee8c2f6ab79d21b835258a6d4)
commit dd9a98c1e651b314912e93fa68ef2010813b5034
Author: Stefan Metzmacher <metze at samba.org>
Date: Fri Nov 9 08:55:40 2012 +0100
lib/addns: remove pointless check for resp->num_additionals != 1
We never use resp->additionals, so there's no reason to check.
This fixes dns updates against BIND9 (used in a Samba4 domain).
Signed-off-by: Stefan Metzmacher <metze at samba.org>
Reviewed-by: Andrew Bartlett <abartlet at samba.org>
(cherry picked from commit b59c5db5f74f56c0536635a41ae51c389109ceb5)
-----------------------------------------------------------------------
Summary of changes:
lib/addns/dnsgss.c | 20 ++++++++++++++------
source4/scripting/python/samba/netcmd/fsmo.py | 2 +-
2 files changed, 15 insertions(+), 7 deletions(-)
Changeset truncated at 500 lines:
diff --git a/lib/addns/dnsgss.c b/lib/addns/dnsgss.c
index 64a7d85..f7ed1d1 100644
--- a/lib/addns/dnsgss.c
+++ b/lib/addns/dnsgss.c
@@ -92,7 +92,7 @@ static DNS_ERROR dns_negotiate_gss_ctx_int( TALLOC_CTX *mem_ctx,
DNS_ERROR err;
gss_OID_desc krb5_oid_desc =
- { 9, (const char *)"\x2a\x86\x48\x86\xf7\x12\x01\x02\x02" };
+ { 9, discard_const("\x2a\x86\x48\x86\xf7\x12\x01\x02\x02") };
*ctx = GSS_C_NO_CONTEXT;
input_ptr = NULL;
@@ -164,6 +164,8 @@ static DNS_ERROR dns_negotiate_gss_ctx_int( TALLOC_CTX *mem_ctx,
struct dns_request *resp;
struct dns_buffer *buf;
struct dns_tkey_record *tkey;
+ struct dns_rrec *tkey_answer = NULL;
+ uint16_t i;
err = dns_receive(mem_ctx, conn, &buf);
if (!ERR_DNS_IS_OK(err)) goto error;
@@ -174,10 +176,16 @@ static DNS_ERROR dns_negotiate_gss_ctx_int( TALLOC_CTX *mem_ctx,
/*
* TODO: Compare id and keyname
*/
-
- if ((resp->num_additionals != 1) ||
- (resp->num_answers == 0) ||
- (resp->answers[0]->type != QTYPE_TKEY)) {
+
+ for (i=0; i < resp->num_answers; i++) {
+ if (resp->answers[i]->type != QTYPE_TKEY) {
+ continue;
+ }
+
+ tkey_answer = resp->answers[i];
+ }
+
+ if (tkey_answer == NULL) {
err = ERROR_DNS_INVALID_MESSAGE;
goto error;
}
@@ -222,7 +230,7 @@ DNS_ERROR dns_negotiate_sec_ctx( const char *target_realm,
gss_name_t targ_name;
gss_OID_desc nt_host_oid_desc =
- {10, (const char *)"\x2a\x86\x48\x86\xf7\x12\x01\x02\x02\x01"};
+ {10, discard_const("\x2a\x86\x48\x86\xf7\x12\x01\x02\x02\x01")};
TALLOC_CTX *mem_ctx;
diff --git a/source4/scripting/python/samba/netcmd/fsmo.py b/source4/scripting/python/samba/netcmd/fsmo.py
index 15d1d49..c938c91 100644
--- a/source4/scripting/python/samba/netcmd/fsmo.py
+++ b/source4/scripting/python/samba/netcmd/fsmo.py
@@ -103,7 +103,7 @@ all=all of the above"""),
domain_dn = samdb.domain_dn()
self.infrastructure_dn = "CN=Infrastructure," + domain_dn
self.naming_dn = "CN=Partitions,%s" % samdb.get_config_basedn()
- self.schema_dn = samdb.get_schema_basedn()
+ self.schema_dn = str(samdb.get_schema_basedn())
self.rid_dn = "CN=RID Manager$,CN=System," + domain_dn
m = ldb.Message()
--
Samba Shared Repository
More information about the samba-cvs
mailing list