[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via ae4e545 WHATSNEW.txt: Updated with VFS ABI changes for 4.9.0. from 0fb122a tests/demote: replace demote test bash script to python https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit ae4e54563e69d3cd82ad6cf83ededb130a284c40 Author: Jeremy Allison Date: Thu Jun 7 00:47:30 2018 -0700 WHATSNEW.txt: Updated with VFS ABI changes for 4.9.0. Signed-off-by: Jeremy Allison Reviewed-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Thu Jun 7 13:48:25 CEST 2018 on sn-devel-144 --- Summary of changes: WHATSNEW.txt | 15 +++ 1 file changed, 15 insertions(+) Changeset truncated at 500 lines: diff --git a/WHATSNEW.txt b/WHATSNEW.txt index 574e9b2..b9c80cf 100644 --- a/WHATSNEW.txt +++ b/WHATSNEW.txt @@ -72,6 +72,21 @@ to allow better Windows fileserver compatibility in a default install. store dos attributes Default changed yes ea support Default changed yes +VFS interface changes += + +The VFS ABI interface version has changed to 39. Function changes +are: + +SMB_VFS_FSYNC: Removed: Only async versions are used. +SMB_VFS_READ: Removed: Only PREAD or async versions are used. +SMB_VFS_WRITE: Removed: Only PWRITE or async versions are used. +SMB_VFS_CHMOD_ACL: Removed: Only CHMOD is used. +SMB_VFS_FCHMOD_ACL: Removed: Only FCHMOD is used. + +Any external VFS modules will need to be updated to match these +changes in order to work with 4.9.x. + KNOWN ISSUES -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via f052b60 talloc: Fix some typos in the comments from 1531fcd vfs_gpfs: Use full_path_tos instead of talloc_asprintf https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f052b6057294baed1fdf0e916200d3f653bba8ca Author: Kai Blin Date: Sun May 27 08:38:19 2018 +0200 talloc: Fix some typos in the comments Now with even more typos fixed. Thanks Rowland. Signed-off-by: Kai Blin Reviewed-by: Rowland Penny Autobuild-User(master): Kai Blin Autobuild-Date(master): Mon May 28 16:16:17 CEST 2018 on sn-devel-144 --- Summary of changes: lib/talloc/talloc.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/talloc/talloc.h b/lib/talloc/talloc.h index dda308d..7372df1 100644 --- a/lib/talloc/talloc.h +++ b/lib/talloc/talloc.h @@ -1898,8 +1898,8 @@ void talloc_set_log_stderr(void); * This affects all children of this context and constrain any * allocation in the hierarchy to never exceed the limit set. * The limit can be removed by setting 0 (unlimited) as the - * max_size by calling the funciton again on the sam context. - * Memory limits can also be nested, meaning a hild can have + * max_size by calling the function again on the same context. + * Memory limits can also be nested, meaning a child can have * a stricter memory limit than a parent. * Memory limits are enforced only at memory allocation time. * Stealing a context into a 'limited' hierarchy properly -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 5a72a2e dns_server: Remove unused handle_question via 6adec93 dns_server: Add handle_authoritative_send() via 3b7f99e dns_server: Add add_dns_res_rec() via b6aaf77 dns_server: Convert "ask_forwarder" params via 4b54e14 dns_server: Simplify array length handling via 3f2cbb6 dns_server: Simplify talloc handling via 9de59c7 dns_server: Consolidate talloc_realloc from 4807577 Fix bug 10881 Wrong keytab permissions when joining additional DC with BIND backend https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 5a72a2ed0d28004d51039313e84047554c0a8f63 Author: Volker Lendecke Date: Tue Aug 11 07:40:50 2015 +0200 dns_server: Remove unused handle_question Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Tue Dec 15 17:50:32 CET 2015 on sn-devel-104 commit 6adec9339dee488e41c7552451eca45ebae4b917 Author: Volker Lendecke Date: Tue Aug 11 07:39:31 2015 +0200 dns_server: Add handle_authoritative_send() An async version of handle_question Bug: https://bugzilla.samba.org/show_bug.cgi?id=9409 Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin commit 3b7f99e6f4996cfd97220b3a6d5cceeab6ab5b79 Author: Volker Lendecke Date: Sat Aug 8 14:36:43 2015 +0200 dns_server: Add add_dns_res_rec() Same as add_response_rr(), but it copies over a dns_res_rec Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin commit b6aaf77897082c6ac447e9514260b435ac3ad854 Author: Volker Lendecke Date: Sat Aug 8 07:20:26 2015 +0200 dns_server: Convert "ask_forwarder" params Usually we have mem_ctx and ev first when doing a _send function Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin commit 4b54e14b7cf456e327b176b365e8471e0899210b Author: Volker Lendecke Date: Sat Aug 8 06:54:11 2015 +0200 dns_server: Simplify array length handling talloc objects carry an implicit length Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin commit 3f2cbb616f8b0becf8a3479e72dda11433126e65 Author: Volker Lendecke Date: Sat Aug 8 06:49:16 2015 +0200 dns_server: Simplify talloc handling By making sure that the answers are always allocated, we don't have to pass an explicit mem_ctx anymore Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin commit 9de59c7e3f01c578831a8e352ff8e9ee2312c77f Author: Volker Lendecke Date: Fri Aug 7 08:27:19 2015 +0200 dns_server: Consolidate talloc_realloc This puts the talloc_realloc into add_response_rr instead of before create_response_rr. It is a bit less efficient, but as we do not expect hundreds of answers, I think this code is a bit easier to understand. Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin --- Summary of changes: source4/dns_server/dns_query.c | 531 + 1 file changed, 425 insertions(+), 106 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 956898e..63c219a 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -40,15 +40,27 @@ #undef DBGC_CLASS #define DBGC_CLASS DBGC_DNS -static WERROR create_response_rr(const char *name, -const struct dnsp_DnssrvRpcRecord *rec, -struct dns_res_rec **answers, uint16_t *ancount) +static WERROR add_response_rr(const char *name, + const struct dnsp_DnssrvRpcRecord *rec, + struct dns_res_rec **answers) { struct dns_res_rec *ans = *answers; - uint16_t ai = *ancount; + uint16_t ai = talloc_array_length(ans); char *tmp; uint32_t i; + if (ai == UINT16_MAX) { + return WERR_BUFFER_OVERFLOW; + } + + /* +* "ans" is always non-NULL and thus its own talloc context +*/ + ans = talloc_realloc(ans, ans, struct dns_res_rec, ai+1); + if (ans == NULL) { + return WERR_NOMEM; + } + ZERO_STRUCT(ans[ai]); switch (rec->wType) { @@ -122,10 +134,132 @@ static WERROR create_response_rr(const char *name, ans[ai].rr_class = DNS_QCLASS_IN; ans[ai].ttl = rec->dwTtlSeconds; ans[ai].length = UINT16_MAX; - ai++; *answers = ans; - *ancount = ai; + + return WERR_OK; +} + +static WERROR add_dns_res_rec(struct dns_res_rec **pdst, + const struct dns_res_rec *src) +{ + struct dns_res_rec *dst = *pdst; + uint16_t di = t
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 42f38fe dns: always add authority records via d9a3f19 dns: Add a SOA record to error replies via bda1a73 dns: Also pass nsrecs to handle_question() via 0e11c08 dns: Just pass the name to create_response_rr via d7a54f3 dns: Add dns_get_authoritative_zone helper function from 54cbecb script/librelease.sh: this is replaced by script/release.sh now https://git.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 42f38fe8d9a34a9d3710dcddfe642257f41ece87 Author: Kai Blin Date: Fri Jul 17 15:27:51 2015 +0200 dns: always add authority records Signed-off-by: Kai Blin Reviewed-by: Andreas Schneider Autobuild-User(master): Kai Blin Autobuild-Date(master): Thu Aug 6 14:06:52 CEST 2015 on sn-devel-104 commit d9a3f197495951f2b85e042f1bc4525bab389879 Author: Kai Blin Date: Wed Oct 29 13:41:53 2014 +0100 dns: Add a SOA record to error replies Signed-off-by: Kai Blin Reviewed-by: Andreas Schneider commit bda1a7320f72049cf7aad2233899eaf2a55d6973 Author: Kai Blin Date: Wed Oct 29 13:39:16 2014 +0100 dns: Also pass nsrecs to handle_question() Signed-off-by: Kai Blin Reviewed-by: Andreas Schneider commit 0e11c08d3e11c83b21e1366e9e91b6d841fbbd6c Author: Kai Blin Date: Wed Oct 29 13:36:58 2014 +0100 dns: Just pass the name to create_response_rr Signed-off-by: Kai Blin Reviewed-by: Andreas Schneider commit d7a54f33ef5d4f45127c9264f0c4f16a2a8a6541 Author: Kai Blin Date: Wed Oct 29 13:35:36 2014 +0100 dns: Add dns_get_authoritative_zone helper function Signed-off-by: Kai Blin Reviewed-by: Andreas Schneider --- Summary of changes: python/samba/tests/dns.py | 34 +++ source4/dns_server/dns_query.c | 96 ++--- source4/dns_server/dns_server.c | 6 ++- source4/dns_server/dns_server.h | 2 + source4/dns_server/dns_utils.c | 16 +++ 5 files changed, 121 insertions(+), 33 deletions(-) Changeset truncated at 500 lines: diff --git a/python/samba/tests/dns.py b/python/samba/tests/dns.py index 04ac356..044eaf6 100644 --- a/python/samba/tests/dns.py +++ b/python/samba/tests/dns.py @@ -247,23 +247,23 @@ class TestSimpleQueries(DNSTest): response = self.dns_transaction_udp(p) self.assert_dns_rcode_equals(response, dns.DNS_RCODE_NOTIMP) -# Only returns an authority section entry in BIND and Win DNS -# FIXME: Enable one Samba implements this feature -#def test_soa_hostname_query(self): -#"create a SOA query for a hostname" -#p = self.make_name_packet(dns.DNS_OPCODE_QUERY) -#questions = [] -# -#name = "%s.%s" % (os.getenv('SERVER'), self.get_dns_domain()) -#q = self.make_name_question(name, dns.DNS_QTYPE_SOA, dns.DNS_QCLASS_IN) -#questions.append(q) -# -#self.finish_name_packet(p, questions) -#response = self.dns_transaction_udp(p) -#self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) -#self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) -## We don't get SOA records for single hosts -#self.assertEquals(response.ancount, 0) +def test_soa_hostname_query(self): +"create a SOA query for a hostname" +p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +questions = [] + +name = "%s.%s" % (os.getenv('SERVER'), self.get_dns_domain()) +q = self.make_name_question(name, dns.DNS_QTYPE_SOA, dns.DNS_QCLASS_IN) +questions.append(q) + +self.finish_name_packet(p, questions) +response = self.dns_transaction_udp(p) +self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) +self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) +# We don't get SOA records for single hosts +self.assertEquals(response.ancount, 0) +# But we do respond with an authority section +self.assertEqual(response.nscount, 1) def test_soa_domain_query(self): "create a SOA query for a domain" diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 3cafc23..94f5d49 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -40,7 +40,7 @@ #undef DBGC_CLASS #define DBGC_CLASS DBGC_DNS -static WERROR create_response_rr(const struct dns_name_question *question, +static WERROR create_response_rr(const char *name, const struct dnsp_DnssrvRpcRecord *rec, struct dns_res_rec **answers, uint16_t *ancount) { @@ -116,7 +116,7 @@ static WERROR create_response_rr(const struct dns_name_question *question, r
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 634f116 provision: Correctly provision the SOA record minimum TTL from 392ec4d bug #10609: CVE-2014-0239 Don't reply to replies http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 634f116fbb89d723a627f4501b4cd89342cecb8e Author: Kai Blin Date: Fri May 16 18:33:42 2014 +0200 provision: Correctly provision the SOA record minimum TTL This fixes bug #10466 Signed-off-by: Kai Blin Reviewed-by: Guenter Kukkukk Autobuild-User(master): Kai Blin Autobuild-Date(master): Wed May 21 10:55:00 CEST 2014 on sn-devel-104 --- Summary of changes: python/samba/provision/sambadns.py |1 + python/samba/tests/dns.py |1 + 2 files changed, 2 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/python/samba/provision/sambadns.py b/python/samba/provision/sambadns.py index 13e03ab..f1cb1e2 100644 --- a/python/samba/provision/sambadns.py +++ b/python/samba/provision/sambadns.py @@ -130,6 +130,7 @@ class SOARecord(dnsp.DnssrvRpcRecord): soa.expire = expire soa.mname = mname soa.rname = rname +soa.minimum = minimum self.data = soa diff --git a/python/samba/tests/dns.py b/python/samba/tests/dns.py index 400321f..f93e13f 100644 --- a/python/samba/tests/dns.py +++ b/python/samba/tests/dns.py @@ -289,6 +289,7 @@ class TestSimpleQueries(DNSTest): self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) self.assertEquals(response.ancount, 1) +self.assertEquals(response.answers[0].rdata.minimum, 3600) class TestDNSUpdates(DNSTest): -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 392ec4d bug #10609: CVE-2014-0239 Don't reply to replies from e5649ef smbd: fix creation of BUILTIN\{Administrators,Users} when "tdbsam:map builtin = false" http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 392ec4d241eb19c812cd49ff73bd32b2b09d8533 Author: Kai Blin Date: Tue May 13 08:13:29 2014 +0200 bug #10609: CVE-2014-0239 Don't reply to replies Due to insufficient input checking, the DNS server will reply to a packet that has the "reply" bit set. Over UDP, this allows to send a packet with a spoofed sender address and have two servers DOS each other with circular replies. This patch fixes bug #10609 and adds a test to make sure we don't regress. CVE-2014-2039 has been assigned to this issue. Bug: https://bugzilla.samba.org/show_bug.cgi?id=10609 Signed-off-by: Kai Blin Reviewed-by: Stefan Metzmacher Autobuild-User(master): Kai Blin Autobuild-Date(master): Tue May 20 04:15:44 CEST 2014 on sn-devel-104 --- Summary of changes: python/samba/tests/dns.py | 29 + source4/dns_server/dns_server.c |6 ++ 2 files changed, 35 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/python/samba/tests/dns.py b/python/samba/tests/dns.py index 9c0b274..400321f 100644 --- a/python/samba/tests/dns.py +++ b/python/samba/tests/dns.py @@ -833,6 +833,35 @@ class TestInvalidQueries(DNSTest): self.assertEquals(response.answers[0].rdata, os.getenv('SERVER_IP')) +def test_one_a_reply(self): +"send a reply instead of a query" + +p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +questions = [] + +name = "%s.%s" % ('fakefakefake', self.get_dns_domain()) +q = self.make_name_question(name, dns.DNS_QTYPE_A, dns.DNS_QCLASS_IN) +print "asking for ", q.name +questions.append(q) + +self.finish_name_packet(p, questions) +p.operation |= dns.DNS_FLAG_REPLY +s = None +try: +send_packet = ndr.ndr_pack(p) +s = socket.socket(socket.AF_INET, socket.SOCK_STREAM, 0) +host=os.getenv('SERVER_IP') +s.connect((host, 53)) +tcp_packet = struct.pack('!H', len(send_packet)) +tcp_packet += send_packet +s.send(tcp_packet, 0) +recv_packet = s.recv(0x + 2, 0) +self.assertEquals(0, len(recv_packet)) +finally: +if s is not None: +s.close() + + if __name__ == "__main__": import unittest unittest.main() diff --git a/source4/dns_server/dns_server.c b/source4/dns_server/dns_server.c index 976774d..60ce27c 100644 --- a/source4/dns_server/dns_server.c +++ b/source4/dns_server/dns_server.c @@ -156,6 +156,12 @@ static struct tevent_req *dns_process_send(TALLOC_CTX *mem_ctx, return tevent_req_post(req, ev); } + if (state->in_packet.operation & DNS_FLAG_REPLY) { + DEBUG(1, ("Won't reply to replies.\n")); + tevent_req_werror(req, WERR_INVALID_PARAM); + return tevent_req_post(req, ev); + } + state->state.flags = state->in_packet.operation; state->state.flags |= DNS_FLAG_REPLY; -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via f27d8b8 lib: Fix build --without-winbind by adding winbind_lookup_usersids dummy from c664859 selftest: Test auth_wbc, the auth4 winbind and winbind_wbclient modules using pdbtest http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f27d8b813c085cf2527a36d8ce671073acdb4b16 Author: Kai Blin Date: Fri May 9 15:01:23 2014 +0200 lib: Fix build --without-winbind by adding winbind_lookup_usersids dummy When building without winbind lib/winbind_util.c was missing a dummy function for winbind_lookup_usersids() Signed-off-by: Kai Blin Reviewed-by: Volker Lendecke Autobuild-User(master): Kai Blin Autobuild-Date(master): Fri May 16 17:19:18 CEST 2014 on sn-devel-104 --- Summary of changes: source3/lib/winbind_util.c |8 1 files changed, 8 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/lib/winbind_util.c b/source3/lib/winbind_util.c index f62682b..3189dd3 100644 --- a/source3/lib/winbind_util.c +++ b/source3/lib/winbind_util.c @@ -485,4 +485,12 @@ bool winbind_get_sid_aliases(TALLOC_CTX *mem_ctx, return false; } +bool winbind_lookup_usersids(TALLOC_CTX *mem_ctx, +const struct dom_sid *user_sid, +uint32_t *p_num_sids, +struct dom_sid **p_sids) +{ + return false; +} + #endif /* WITH_WINBIND */ -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via e9cff21 ldbsamba: Move pyldb-utils dependency to python_samba__ldb from a581f23 smbd: Remove unused code for dos attributes in stat struct http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit e9cff2183196f25eb734c8779e84fc382ab1e342 Author: Kai Blin Date: Wed May 14 00:22:01 2014 +0200 ldbsamba: Move pyldb-utils dependency to python_samba__ldb This allows to build smbd statically again. Pair-programmed-with: Stefan Metzmacher Signed-off-by: Kai Blin Signed-off-by: Stefan Metzmacher Autobuild-User(master): Kai Blin Autobuild-Date(master): Wed May 14 04:01:46 CEST 2014 on sn-devel-104 --- Summary of changes: lib/ldb-samba/wscript_build |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/ldb-samba/wscript_build b/lib/ldb-samba/wscript_build index 63ff5b1..7016b2f 100644 --- a/lib/ldb-samba/wscript_build +++ b/lib/ldb-samba/wscript_build @@ -8,7 +8,7 @@ bld.SAMBA_LIBRARY('ldbsamba', source='ldif_handlers.c', autoproto='ldif_handlers_proto.h', public_deps='ldb', - deps='samba-security ndr NDR_DRSBLOBS NDR_DNSP ldbwrap samdb-common SAMDB_SCHEMA tdb pyldb-util errors', + deps='samba-security ndr NDR_DRSBLOBS NDR_DNSP ldbwrap samdb-common SAMDB_SCHEMA tdb errors', private_library=True ) @@ -20,7 +20,7 @@ bld.SAMBA_SUBSYSTEM('ldbwrap', bld.SAMBA_PYTHON('python_samba__ldb', 'pyldb.c', - deps='ldbsamba pyparam_util ldbwrap', + deps='ldbsamba pyparam_util ldbwrap pyldb-util', realname='samba/_ldb.so') bld.SAMBA_MODULE('ldbsamba_extensions', -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 5bd47bb dns: Extend tests for records with another type via d9829df bug #10471: Don't respond with NXDOMAIN to records that exist with another type from 6f092cf autobuild: Run "make dist" to ensure non-waf docs build is run http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 5bd47bb563c3736b9de1a3a93bdf46a498928643 Author: Kai Blin Date: Fri Feb 28 10:35:07 2014 +0100 dns: Extend tests for records with another type Add another check to the one added for bug #10471, for added paranoia Signed-off-by: Kai Blin Reviewed-by: Andrew Bartlett Autobuild-User(master): Kai Blin Autobuild-Date(master): Tue Mar 4 15:47:10 CET 2014 on sn-devel-104 commit d9829df13317b38677d92a499134727ab31fbb0e Author: Kai Blin Date: Thu Feb 27 23:49:24 2014 +0100 bug #10471: Don't respond with NXDOMAIN to records that exist with another type DNS queries for records with the wrong type need to trigger an empty response with RCODE_OK instead of returning NXDOMAIN. This adds a test and fixes bug #10471 Signed-off-by: Kai Blin Reviewed-by: Andrew Bartlett --- Summary of changes: python/samba/tests/dns.py | 30 ++ source4/dns_server/dns_query.c | 14 -- 2 files changed, 38 insertions(+), 6 deletions(-) Changeset truncated at 500 lines: diff --git a/python/samba/tests/dns.py b/python/samba/tests/dns.py index 0ac9cf4..f2c5685 100644 --- a/python/samba/tests/dns.py +++ b/python/samba/tests/dns.py @@ -171,6 +171,36 @@ class TestSimpleQueries(DNSTest): self.assertEquals(response.answers[0].rdata, os.getenv('SERVER_IP')) +def test_one_mx_query(self): +"create a query packet causing an empty RCODE_OK answer" +p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +questions = [] + +name = "%s.%s" % (os.getenv('SERVER'), self.get_dns_domain()) +q = self.make_name_question(name, dns.DNS_QTYPE_MX, dns.DNS_QCLASS_IN) +print "asking for ", q.name +questions.append(q) + +self.finish_name_packet(p, questions) +response = self.dns_transaction_udp(p) +self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) +self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) +self.assertEquals(response.ancount, 0) + +p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +questions = [] + +name = "invalid-%s.%s" % (os.getenv('SERVER'), self.get_dns_domain()) +q = self.make_name_question(name, dns.DNS_QTYPE_MX, dns.DNS_QCLASS_IN) +print "asking for ", q.name +questions.append(q) + +self.finish_name_packet(p, questions) +response = self.dns_transaction_udp(p) +self.assert_dns_rcode_equals(response, dns.DNS_RCODE_NXDOMAIN) +self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) +self.assertEquals(response.ancount, 0) + def test_two_queries(self): "create a query packet containing two query records" p = self.make_name_packet(dns.DNS_OPCODE_QUERY) diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 5414e1d..77f797b 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -258,7 +258,7 @@ static WERROR handle_question(struct dns_server *dns, struct dns_res_rec **answers, uint16_t *ancount) { struct dns_res_rec *ans = *answers; - WERROR werror; + WERROR werror, werror_return; unsigned int ri; struct dnsp_DnssrvRpcRecord *recs; uint16_t rec_count, ai = *ancount; @@ -275,6 +275,9 @@ static WERROR handle_question(struct dns_server *dns, return WERR_NOMEM; } + /* Set up for an NXDOMAIN reply if no match is found */ + werror_return = DNS_ERR(NAME_ERROR); + for (ri = 0; ri < rec_count; ri++) { if ((recs[ri].wType == DNS_TYPE_CNAME) && ((question->question_type == DNS_QTYPE_A) || @@ -319,28 +322,27 @@ static WERROR handle_question(struct dns_server *dns, if (!W_ERROR_IS_OK(werror)) { return werror; } + werror_return = WERR_OK; continue; } if ((question->question_type != DNS_QTYPE_ALL) && (recs[ri].wType != question->question_type)) { + werror_return = WERR_OK; continue; }
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 096c962 Backport 0e97908 from WAF repository: symlink fix for OpenBSD from d5eb3b2 s4:torture: remove and useless variable and assignment in smb2.session.reauth5 http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 096c962bfe4646274c08b2953d9fbaebb892a689 Author: Matthieu Patou Date: Fri Sep 6 23:23:07 2013 -0700 Backport 0e97908 from WAF repository: symlink fix for OpenBSD Author: Thomas Nagy Signed-off-by: Matthieu Patou Reviewed-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Sat Sep 21 11:14:30 CEST 2013 on sn-devel-104 --- Summary of changes: buildtools/wafadmin/Tools/ccroot.py |9 ++--- 1 files changed, 6 insertions(+), 3 deletions(-) Changeset truncated at 500 lines: diff --git a/buildtools/wafadmin/Tools/ccroot.py b/buildtools/wafadmin/Tools/ccroot.py index f54c82f..264bdc7 100644 --- a/buildtools/wafadmin/Tools/ccroot.py +++ b/buildtools/wafadmin/Tools/ccroot.py @@ -597,9 +597,12 @@ def apply_vnum(self): path = self.install_path if not path: return - bld.install_as(path + os.sep + name3, node, env=self.env) - bld.symlink_as(path + os.sep + name2, name3) - bld.symlink_as(path + os.sep + libname, name3) + if self.env.DEST_OS == 'openbsd': + bld.install_as(path + os.sep + name2, node, env=self.env, chmod=self.link_task.chmod) + else: + bld.install_as(path + os.sep + name3, node, env=self.env) + bld.symlink_as(path + os.sep + name2, name3) + bld.symlink_as(path + os.sep + libname, name3) # the following task is just to enable execution from the build dir :-/ self.create_task('vnum', node, [node.parent.find_or_declare(name2), node.parent.find_or_declare(name3)]) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 573b455 pkgconfig: Do not hardcode library version numbers in pc files. via a0b245c s3-pkgconfig: remove leftovers from autoconf build. from db1d034 client: add missing newlines to error messages for invalid iosize parameter. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 573b455de9a45990446af26eea01539a32fef209 Author: Günther Deschner Date: Thu Aug 22 15:00:32 2013 +0200 pkgconfig: Do not hardcode library version numbers in pc files. We control version numbers via 'vnum' from the wscript_build files for all other libraries. In case of libndr we already reported a wrong 0.0.1 version via pkgconfig while in fact the library is versioned as 0.0.2. Guenther Signed-off-by: Günther Deschner Reviewed-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Thu Aug 22 20:48:44 CEST 2013 on sn-devel-104 commit a0b245c78271d060d59f763fb586221ec10edd7b Author: Günther Deschner Date: Thu Aug 22 14:59:08 2013 +0200 s3-pkgconfig: remove leftovers from autoconf build. No worries, we still ship appropriate pc files for these libs. Guenther Signed-off-by: Günther Deschner Reviewed-by: Kai Blin --- Summary of changes: lib/torture/torture.pc.in |2 +- lib/util/samba-util.pc.in |2 +- librpc/ndr.pc.in |2 +- librpc/ndr_krb5pac.pc.in |2 +- librpc/ndr_nbt.pc.in |2 +- librpc/ndr_standard.pc.in |2 +- source3/pkgconfig/netapi.pc.in| 14 -- source3/pkgconfig/smbclient.pc.in | 14 -- source3/pkgconfig/smbsharemodes.pc.in | 14 -- source3/pkgconfig/wbclient.pc.in | 13 - 10 files changed, 6 insertions(+), 61 deletions(-) delete mode 100644 source3/pkgconfig/netapi.pc.in delete mode 100644 source3/pkgconfig/smbclient.pc.in delete mode 100644 source3/pkgconfig/smbsharemodes.pc.in delete mode 100644 source3/pkgconfig/wbclient.pc.in Changeset truncated at 500 lines: diff --git a/lib/torture/torture.pc.in b/lib/torture/torture.pc.in index 459b35c..e0421b0 100644 --- a/lib/torture/torture.pc.in +++ b/lib/torture/torture.pc.in @@ -7,6 +7,6 @@ modulesdir=${prefix}/modules/torture Name: torture Description: Samba torture (test) suite Requires: talloc -Version: 0.0.1 +Version: @PACKAGE_VERSION@ Libs: @LIB_RPATH@ -L${libdir} -ltorture Cflags: -I${includedir} -DHAVE_IMMEDIATE_STRUCTURES=1 diff --git a/lib/util/samba-util.pc.in b/lib/util/samba-util.pc.in index a49c1d0..65876c4 100644 --- a/lib/util/samba-util.pc.in +++ b/lib/util/samba-util.pc.in @@ -6,6 +6,6 @@ includedir=@includedir@ Name: samba-util Description: Samba utility functions Requires: talloc tevent -Version: 0.0.1 +Version: @PACKAGE_VERSION@ Libs: @LIB_RPATH@ -L${libdir} -lsamba-util Cflags: -I${includedir} -DHAVE_IMMEDIATE_STRUCTURES=1 diff --git a/librpc/ndr.pc.in b/librpc/ndr.pc.in index 1ee50cc..6828ac0 100644 --- a/librpc/ndr.pc.in +++ b/librpc/ndr.pc.in @@ -6,6 +6,6 @@ includedir=@includedir@ Name: ndr Description: Network Data Representation Core Library Requires: samba-util talloc -Version: 0.0.1 +Version: @PACKAGE_VERSION@ Libs: @LIB_RPATH@ -L${libdir} -lndr Cflags: -I${includedir} -DHAVE_IMMEDIATE_STRUCTURES=1 -D_GNU_SOURCE=1 diff --git a/librpc/ndr_krb5pac.pc.in b/librpc/ndr_krb5pac.pc.in index 21ecb55..597bbd1 100644 --- a/librpc/ndr_krb5pac.pc.in +++ b/librpc/ndr_krb5pac.pc.in @@ -6,6 +6,6 @@ includedir=@includedir@ Name: ndr-krb5pac Description: NDR marshallers for the KRB5 PAC formats Requires: ndr -Version: 0.0.1 +Version: @PACKAGE_VERSION@ Libs: @LIB_RPATH@ -L${libdir} -lndr-krb5pac Cflags: -I${includedir} -DHAVE_IMMEDIATE_STRUCTURES=1 -D_GNU_SOURCE=1 diff --git a/librpc/ndr_nbt.pc.in b/librpc/ndr_nbt.pc.in index 5b69699..2083e2d 100644 --- a/librpc/ndr_nbt.pc.in +++ b/librpc/ndr_nbt.pc.in @@ -6,6 +6,6 @@ includedir=@includedir@ Name: ndr-nbt Description: NDR marshallers for nbt formats Requires: ndr -Version: 0.0.1 +Version: @PACKAGE_VERSION@ Libs: @LIB_RPATH@ -L${libdir} -lndr-nbt Cflags: -I${includedir} -DHAVE_IMMEDIATE_STRUCTURES=1 -D_GNU_SOURCE=1 diff --git a/librpc/ndr_standard.pc.in b/librpc/ndr_standard.pc.in index d400ef1..97687ba 100644 --- a/librpc/ndr_standard.pc.in +++ b/librpc/ndr_standard.pc.in @@ -6,6 +6,6 @@ includedir=@includedir@ Name: ndr-standard Description: NDR marshallers for the standard set of DCE/RPC interfaces Requires: ndr -Version: 0.0.1 +Version: @PACKAGE_VERSION@ Libs: @LIB_RPATH@ -L${libdir} -lndr-standard Cflags: -I${includedir} -DHAVE_IMMEDIATE_STRUCTURES=1 -D_GNU_SOURCE=1 diff --git a/source3/pkgconfig/netapi.pc.in b/source3/pkgconfig/netapi.pc.in de
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via d7708fd talloc: Fix a typo from 96f9724 ldb_tdb: Warn when reindexing is done http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit d7708fd360c1fa1e3111fd4df266b52c96cca196 Author: Volker Lendecke Date: Mon May 20 14:26:08 2013 +0200 talloc: Fix a typo Signed-off-by: Volker Lendecke Reviewed-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Mon May 20 18:48:49 CEST 2013 on sn-devel-104 --- Summary of changes: lib/talloc/talloc.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/talloc/talloc.c b/lib/talloc/talloc.c index 885d700..76f0aee 100644 --- a/lib/talloc/talloc.c +++ b/lib/talloc/talloc.c @@ -255,7 +255,7 @@ struct talloc_chunk { * if 'limit' is set it means all *new* children of the context will * be limited to a total aggregate size ox max_size for memory * allocations. -* cur_size is used to kep track of the current use +* cur_size is used to keep track of the current use */ struct talloc_memlimit *limit; -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 61a2ad3 swat: Remove swat. from a3a3086 dns: Also print packet information for DBGC_DNS http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 61a2ad3c020424cead067cbdc89ea6f25708fde4 Author: Kai Blin Date: Fri May 17 14:16:26 2013 +0200 swat: Remove swat. Signed-off-by: Kai Blin Reviewed-by: Andrew Bartlett Autobuild-User(master): Kai Blin Autobuild-Date(master): Sat May 18 16:32:38 CEST 2013 on sn-devel-104 --- Summary of changes: buildtools/wafsamba/samba_patterns.py |1 - dynconfig/config.m4 |3 - dynconfig/dynconfig.c |1 - dynconfig/dynconfig.h |1 - dynconfig/wscript |4 - examples/misc/swat.pl | 122 -- source3/Makefile.in | 33 +- source3/configure.in|2 - source3/lib/popt_common.c | 10 - source3/m4/swat.m4 | 27 - source3/param/loadparm.c|2 +- source3/po/de.msg | 616 -- source3/po/en.msg | 592 -- source3/po/fi.msg | 610 -- source3/po/fr.msg | 592 -- source3/po/genmsg | 40 - source3/po/it.msg | 592 -- source3/po/ja.msg | 594 -- source3/po/nl.msg | 592 -- source3/po/pl.msg | 592 -- source3/po/ru.msg | 606 -- source3/po/tr.msg | 593 -- source3/script/installmsg.sh| 65 - source3/script/installswat.sh | 296 - source3/script/mkbuildoptions.awk |1 - source3/web/cgi.c | 798 - source3/web/diagnose.c | 80 -- source3/web/neg_lang.c | 120 -- source3/web/startstop.c | 130 -- source3/web/statuspage.c| 467 source3/web/swat.c | 1683 +-- source3/web/swat_proto.h| 76 -- source3/wscript |4 - source3/wscript_build | 33 - source4/smbd/server.c |1 - swat/help/welcome-no-samba-doc.html |3 - swat/help/welcome.html | 63 - swat/images/globals.gif | Bin 2004 -> 0 bytes swat/images/home.gif| Bin 2044 -> 0 bytes swat/images/passwd.gif | Bin 1993 -> 0 bytes swat/images/printers.gif| Bin 2077 -> 0 bytes swat/images/samba.gif | Bin 3643 -> 0 bytes swat/images/shares.gif | Bin 2006 -> 0 bytes swat/images/status.gif | Bin 2080 -> 0 bytes swat/images/viewconfig.gif | Bin 1939 -> 0 bytes swat/images/wizard.gif | Bin 2554 -> 0 bytes swat/include/footer.html|3 - swat/include/header.html| 11 - swat/lang/ja/help/welcome.html | 66 -- swat/lang/ru/help/welcome-no-samba-doc.html |6 - swat/lang/ru/help/welcome.html | 65 - swat/lang/ru/images/globals.gif | Bin 2041 -> 0 bytes swat/lang/ru/images/home.gif| Bin 2190 -> 0 bytes swat/lang/ru/images/passwd.gif | Bin 1936 -> 0 bytes swat/lang/ru/images/printers.gif| Bin 2139 -> 0 bytes swat/lang/ru/images/shares.gif | Bin 2081 -> 0 bytes swat/lang/ru/images/status.gif | Bin 2305 -> 0 bytes swat/lang/ru/images/viewconfig.gif | Bin 2096 -> 0 bytes swat/lang/ru/images/wizard.gif | Bin 2605 -> 0 bytes swat/lang/ru/include/header.html| 14 - swat/lang/tr/help/welcome.html | 66 -- swat/lang/tr/images/globals.gif | Bin 442 -> 0 bytes swat/lang/tr/images/home.gif| Bin 608 -> 0 bytes swat/lang/tr/images/passwd.gif | Bin 326 -> 0 bytes swat/lang/tr/images/printers.gif| Bin 519 -> 0 bytes swat/lang/tr/images/samba.gif | Bin 3643 -> 0 bytes swat/lang/tr/images/shares.gif | Bin 474 -> 0 bytes swat/lang/tr/images/status.gif | Bin 431 -> 0 bytes swat/lang/tr/images/viewconfig.gif | Bin 455 -> 0 bytes 69 files changed, 41
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via a3a3086 dns: Also print packet information for DBGC_DNS via 0f5e9d2 librpc: Add NDR_PRINT_DEBUGC to ndr print to a debug class via 30cba0d debug: Add ability to dump_data per debug class from 1c9ef67 smbd: Fix a ISO C90 forbids mixed declarations and code warning http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit a3a3086a2a35021bcf4dd4d3bcaeb51eb1b44a19 Author: Kai Blin Date: Fri Jan 18 18:36:45 2013 +0100 dns: Also print packet information for DBGC_DNS Signed-off-by: Kai Blin Reviewed-by: Andrew Bartlett Autobuild-User(master): Kai Blin Autobuild-Date(master): Sat May 18 12:48:15 CEST 2013 on sn-devel-104 commit 0f5e9d29f607f9d910641632dfcd20ef800b0bc4 Author: Kai Blin Date: Fri Jan 18 18:35:15 2013 +0100 librpc: Add NDR_PRINT_DEBUGC to ndr print to a debug class Signed-off-by: Kai Blin Reviewed-by: Andrew Bartlett commit 30cba0d201fc91cff30b6ea2bd11979930650169 Author: Kai Blin Date: Fri Jan 18 09:44:02 2013 +0100 debug: Add ability to dump_data per debug class Signed-off-by: Kai Blin Reviewed-by: Andrew Bartlett --- Summary of changes: lib/util/debug.h |7 +++ lib/util/samba_util.h |8 lib/util/util.c | 30 ++ librpc/ABI/{ndr-0.0.1.sigs => ndr-0.0.2.sigs} |2 + librpc/ndr/libndr.h |3 + librpc/ndr/ndr.c | 51 + librpc/wscript_build |2 +- source4/dns_server/dns_server.c | 10 ++-- 8 files changed, 107 insertions(+), 6 deletions(-) copy librpc/ABI/{ndr-0.0.1.sigs => ndr-0.0.2.sigs} (99%) Changeset truncated at 500 lines: diff --git a/lib/util/debug.h b/lib/util/debug.h index feea0a8..30df787 100644 --- a/lib/util/debug.h +++ b/lib/util/debug.h @@ -161,10 +161,17 @@ extern int *DEBUGLEVEL_CLASS; ( ((level) <= MAX_DEBUG_LEVEL) && \ unlikely(DEBUGLEVEL_CLASS[ DBGC_CLASS ] >= (level))) +#define CHECK_DEBUGLVLC( dbgc_class, level ) \ + ( ((level) <= MAX_DEBUG_LEVEL) && \ +unlikely(DEBUGLEVEL_CLASS[ dbgc_class ] >= (level))) + #define DEBUGLVL( level ) \ ( CHECK_DEBUGLVL(level) \ && dbghdrclass( level, DBGC_CLASS, __location__, __FUNCTION__ ) ) +#define DEBUGLVLC( dbgc_class, level ) \ + ( CHECK_DEBUGLVLC( dbgc_class, level ) \ + && dbghdrclass( level, dbgc_class, __location__, __FUNCTION__ ) ) #define DEBUG( level, body ) \ (void)( ((level) <= MAX_DEBUG_LEVEL) && \ diff --git a/lib/util/samba_util.h b/lib/util/samba_util.h index 6a4373e..89aa9aa 100644 --- a/lib/util/samba_util.h +++ b/lib/util/samba_util.h @@ -693,6 +693,14 @@ _PUBLIC_ void dump_data(int level, const uint8_t *buf,int len); /** * Write dump of binary data to the log file. * + * The data is only written if the log level is at least level for + * debug class dbgc_class. + */ +_PUBLIC_ void dump_data_dbgc(int dbgc_class, int level, const uint8_t *buf, int len); + +/** + * Write dump of binary data to the log file. + * * The data is only written if the log level is at least level. * 16 zero bytes in a row are omitted */ diff --git a/lib/util/util.c b/lib/util/util.c index 7962c1e..7c669fb 100644 --- a/lib/util/util.c +++ b/lib/util/util.c @@ -384,6 +384,19 @@ _PUBLIC_ bool fcntl_lock(int fd, int op, off_t offset, off_t count, int type) return true; } +struct debug_channel_level { + int channel; + int level; +}; + +static void debugadd_channel_cb(const char *buf, void *private_data) +{ + struct debug_channel_level *dcl = + (struct debug_channel_level *)private_data; + + DEBUGADDC(dcl->channel, dcl->level,("%s", buf)); +} + static void debugadd_cb(const char *buf, void *private_data) { int *plevel = (int *)private_data; @@ -505,6 +518,23 @@ _PUBLIC_ void dump_data(int level, const uint8_t *buf, int len) /** * Write dump of binary data to the log file. * + * The data is only written if the log level is at least level for + * debug class dbgc_class. + */ +_PUBLIC_ void dump_data_dbgc(int dbgc_class, int level, const uint8_t *buf, int len) +{ + struct debug_channel_level dcl = { dbgc_class, level }; + + if (!DEBUGLVLC(dbgc_class, level)) { + DEBUG(0, ("dbgc_class is %d\n", dbgc_class)); + return; + } + dump_data_cb(buf, len, false, debugadd_channel_cb, &dcl); +} + +/** + * Write dump of binary data to the log file. + * * The data is only written if the log level is at least level. * 16 zero bytes in a row are omitted */ diff --git a/libr
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 9f36d0c build: default --with-regedit to "auto" instead of "yes" via 431eeef build: fix --with-regedit to properly honour the yes/no/auto scheme via 356b825 build: simplify ncurses checks: --with-regedit does not take a path list from 8d34f2f docs: update the description of the formulas in the idmap_autorid manpage http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 9f36d0c447b2107798e560ce257026318952c5e2 Author: Michael Adam Date: Mon May 6 13:16:49 2013 +0200 build: default --with-regedit to "auto" instead of "yes" This means we don't build regedit when there is no ncurses and this is not an error for the overall build. Signed-off-by: Michael Adam Reviewed-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Mon May 6 20:11:09 CEST 2013 on sn-devel-104 commit 431eeef9311a8e172dc782bc91492c94cc5fcde7 Author: Michael Adam Date: Mon May 6 14:14:02 2013 +0200 build: fix --with-regedit to properly honour the yes/no/auto scheme I.e. fail configure when ncurses support is not found but regedit build was requested. Signed-off-by: Michael Adam Reviewed-by: Kai Blin commit 356b825838cd97cc43aaa4b108267d1bd5f16ca1 Author: Michael Adam Date: Mon May 6 13:19:24 2013 +0200 build: simplify ncurses checks: --with-regedit does not take a path list --with-regedit is defined using SAMBA3_ADD_OPTION(), and can hence take the values "yes", "no", and "auto". So it is not possible to hand in paths to look for ncurses-config via this option. Signed-off-by: Michael Adam Reviewed-by: Kai Blin --- Summary of changes: source3/wscript | 19 +-- source3/wscript_configure_system_ncurses | 18 ++ 2 files changed, 27 insertions(+), 10 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 28fa11f..5e45fac 100644 --- a/source3/wscript +++ b/source3/wscript @@ -47,7 +47,7 @@ def set_options(opt): opt.SAMBA3_ADD_OPTION('cluster-support', default=None) -opt.SAMBA3_ADD_OPTION('regedit', default=True) +opt.SAMBA3_ADD_OPTION('regedit', default=None) opt.add_option('--with-ctdb-dir', help=("Directory under which ctdb is installed"), @@ -1713,8 +1713,23 @@ main() { if conf.CHECK_HEADERS('cephfs/libcephfs.h', False, False, 'cephfs') and conf.CHECK_LIB('cephfs'): conf.DEFINE('HAVE_CEPH', '1') -if Options.options.with_regedit: +conf.env.build_regedit = False +if not Options.options.with_regedit == False: conf.PROCESS_SEPARATE_RULE('system_ncurses') +if conf.CONFIG_SET('HAVE_NCURSES'): +conf.env.build_regedit = True + +if conf.env.build_regedit: +Logs.info("building regedit") +else: +if Options.options.with_regedit == False: +Logs.info("not building regedit (--without-regedit)") +elif Options.options.with_regedit == True: +Logs.error("ncurses not available, cannot build regedit") +conf.fatal("ncurses not available, but --with-regedit was specified") +else: +Logs.info("ncurses not available, not building regedit") + default_static_modules.extend(TO_LIST('''pdb_smbpasswd pdb_tdbsam pdb_wbc_sam auth_sam auth_unix auth_winbind auth_wbc diff --git a/source3/wscript_configure_system_ncurses b/source3/wscript_configure_system_ncurses index e8c4ab5..5c80429 100644 --- a/source3/wscript_configure_system_ncurses +++ b/source3/wscript_configure_system_ncurses @@ -2,19 +2,13 @@ import Logs, Options, sys Logs.info("Looking for ncurses features") -if isinstance(Options.options.with_regedit, list): -path_ncurses_config = [x+'/bin' for x in Options.options.with_regedit] -else: -path_ncurses_config = None - -conf.find_program('ncurses5-config', path_list=path_ncurses_config, var='NCURSES_CONFIG') +conf.find_program('ncurses5-config', var='NCURSES_CONFIG') if not conf.env.NCURSES_CONFIG: -conf.find_program('ncurses6-config', path_list=path_ncurses_config, var='NCURSES_CONFIG') +conf.find_program('ncurses6-config', var='NCURSES_CONFIG') if conf.env.NCURSES_CONFIG: conf.check_cfg(path=conf.env.NCURSES_CONFIG, args="--cflags --libs", pack
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 2c3a808 s4-dns: Fix the comments about ignoring zones in internal server from bddd118 s3:smb2_getinfo ensure proper error for not yet present quota support http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 2c3a8081ea2fd7eaa2d7bacffc35e0a58c54 Author: Matthieu Patou Date: Sat Oct 13 01:36:06 2012 -0700 s4-dns: Fix the comments about ignoring zones in internal server Acked-By: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Sat Oct 13 12:37:53 CEST 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_server.c |8 +++- 1 files changed, 7 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_server.c b/source4/dns_server/dns_server.c index d139eb7..8e25396 100644 --- a/source4/dns_server/dns_server.c +++ b/source4/dns_server/dns_server.c @@ -832,7 +832,13 @@ static void dns_task_init(struct task_server *task) z->name = ldb_msg_find_attr_as_string(res->msgs[i], "name", NULL); z->dn = talloc_move(z, &res->msgs[i]->dn); - /* Ignore the RootDNSServers zone and zones that we don't support yet */ + /* +* Ignore the RootDNSServers zone and zones that we don't support yet +* RootDNSServers should never be returned (Windows DNS server don't) +* ..TrustAnchors should never be returned as is, (Windows returns +* TrustAnchors) and for the moment we don't support DNSSEC so we'd better +* not return this zone. +*/ if ((strcmp(z->name, "RootDNSServers") == 0) || (strcmp(z->name, "..TrustAnchors") == 0)) { DEBUG(10, ("Ignoring zone %s\n", z->name)); -- Samba Shared Repository
Re: [SCM] Samba Shared Repository - branch master updated
On 2012-10-11 21:23, Stefan (metze) Metzmacher wrote: > Hi Jelmer, > >> - Log - >> commit c2d14747d608d406de6410556807d467cd0b85ef >> Author: Jelmer Vernooij >> Date: Thu Oct 11 14:45:10 2012 +0200 >> >> provision: Always create DNS user. >> >> The DNS user is currently only used by the bind9 plugin. This makes it >> easier to later on switch between the builtin DNS server and bind >> backend. >> >> In addition, ideally the internal DNS server would use that (separate) >> user too. > > Why? Isn't that the job of samba_upgradedns? > I removed this behavior because I want us to match windows as much as > possible. +1 Cheers, Kai -- Kai Blin Worldforge developer http://www.worldforge.org/ Wine developer http://wiki.winehq.org/KaiBlin Samba team member http://www.samba.org/samba/team/
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via f4b9007 s4-dns: fix a non handled memory out of memory from 9f83968 Add samba3.samba3badnameblob test to check regressions in bug #9215. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f4b9007faf901db6f703b5109df055081949c3f1 Author: Matthieu Patou Date: Mon Oct 1 21:43:11 2012 -0700 s4-dns: fix a non handled memory out of memory Signed-off-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Tue Oct 2 09:43:52 CEST 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_server.c |1 + 1 files changed, 1 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_server.c b/source4/dns_server/dns_server.c index dbdc300..003dd4e 100644 --- a/source4/dns_server/dns_server.c +++ b/source4/dns_server/dns_server.c @@ -828,6 +828,7 @@ static void dns_task_init(struct task_server *task) z = talloc_zero(dns, struct dns_server_zone); if (z == NULL) { + task_server_terminate(task, "dns failed to allocate memory", true); } z->name = ldb_msg_find_attr_as_string(res->msgs[i], "name", NULL); -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 8180522 s4 dns: Fix return code for deleted records via ecb4a8a s4 dns: Get rid of deprecated allocation result check from 7d0a9f5 selftest: use an array when starting testenv with system() http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 81805222ec7a652e188bd106199820570c9dcaad Author: Kai Blin Date: Sun Sep 30 11:26:24 2012 +0200 s4 dns: Fix return code for deleted records This fixes bug #9225. We already had a test for this scenario, but the test wasn't correct. This patch fixes the test, and also fixes the bug. Signed-off-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Sun Sep 30 13:09:14 CEST 2012 on sn-devel-104 commit ecb4a8a824faf89a442bdd0eeb5ab9f79a14fb40 Author: Kai Blin Date: Sun Sep 30 10:44:03 2012 +0200 s4 dns: Get rid of deprecated allocation result check --- Summary of changes: source4/dns_server/dns_utils.c |6 ++- source4/scripting/python/samba/tests/dns.py | 46 +-- 2 files changed, 47 insertions(+), 5 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_utils.c b/source4/dns_server/dns_utils.c index 11ded68..3988393 100644 --- a/source4/dns_server/dns_utils.c +++ b/source4/dns_server/dns_utils.c @@ -201,11 +201,13 @@ WERROR dns_lookup_records(struct dns_server *dns, if (el == NULL) { *records = NULL; *rec_count = 0; - return WERR_OK; + return DNS_ERR(NAME_ERROR); } recs = talloc_zero_array(mem_ctx, struct dnsp_DnssrvRpcRecord, el->num_values); - W_ERROR_HAVE_NO_MEMORY(recs); + if (recs == NULL) { + return WERR_NOMEM; + } for (ri = 0; ri < el->num_values; ri++) { struct ldb_val *v = &el->values[ri]; enum ndr_err_code ndr_err; diff --git a/source4/scripting/python/samba/tests/dns.py b/source4/scripting/python/samba/tests/dns.py index 7401124..49d699e 100644 --- a/source4/scripting/python/samba/tests/dns.py +++ b/source4/scripting/python/samba/tests/dns.py @@ -434,6 +434,10 @@ class TestDNSUpdates(DNSTest): def test_delete_record(self): "Test if deleting records works" + +NAME = "deleterec.%s" % self.get_dns_domain() + +# First, create a record to make sure we have a record to delete. p = self.make_name_packet(dns.DNS_OPCODE_UPDATE) updates = [] @@ -445,7 +449,43 @@ class TestDNSUpdates(DNSTest): updates = [] r = dns.res_rec() -r.name = "textrec.%s" % self.get_dns_domain() +r.name = NAME +r.rr_type = dns.DNS_QTYPE_TXT +r.rr_class = dns.DNS_QCLASS_IN +r.ttl = 900 +r.length = 0x +r.rdata = dns.txt_record() +r.rdata.txt = '"This is a test"' +updates.append(r) +p.nscount = len(updates) +p.nsrecs = updates + +response = self.dns_transaction_udp(p) +self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) + +# Now check the record is around +p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +questions = [] +q = self.make_name_question(NAME, dns.DNS_QTYPE_TXT, dns.DNS_QCLASS_IN) +questions.append(q) + +self.finish_name_packet(p, questions) +response = self.dns_transaction_udp(p) +self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) + +# Now delete the record +p = self.make_name_packet(dns.DNS_OPCODE_UPDATE) +updates = [] + +name = self.get_dns_domain() + +u = self.make_name_question(name, dns.DNS_QTYPE_SOA, dns.DNS_QCLASS_IN) +updates.append(u) +self.finish_name_packet(p, updates) + +updates = [] +r = dns.res_rec() +r.name = NAME r.rr_type = dns.DNS_QTYPE_TXT r.rr_class = dns.DNS_QCLASS_NONE r.ttl = 0 @@ -459,11 +499,11 @@ class TestDNSUpdates(DNSTest): response = self.dns_transaction_udp(p) self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) +# And finally check it's gone p = self.make_name_packet(dns.DNS_OPCODE_QUERY) questions = [] -name = "textrec.%s" % self.get_dns_domain() -q = self.make_name_question(name, dns.DNS_QTYPE_TXT, dns.DNS_QCLASS_IN) +q = self.make_name_question(NAME, dns.DNS_QTYPE_TXT, dns.DNS_QCLASS_IN) questions.append(q) self.finish_name_packet(p, questions) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 5f97363 s4:dns_server - introduce the wildcard binding feature from 9e6070b s3-pylibsmb: Add get_oplock_break http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 5f973631b6baecf5f026d07dded9da15650e Author: Matthias Dieter Wallnöfer Date: Sun Aug 12 18:08:20 2012 +0200 s4:dns_server - introduce the wildcard binding feature We need the wildcard binding feature otherwise we might get bound to a private interface in case of multiple interfaces and no "interfaces" parameter in smb.conf. Code taken from source4/ldap_server/ldap_server.c Signed-off-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Sun Sep 23 23:44:03 CEST 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_server.c | 38 -- 1 files changed, 28 insertions(+), 10 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_server.c b/source4/dns_server/dns_server.c index c88ea83..dbdc300 100644 --- a/source4/dns_server/dns_server.c +++ b/source4/dns_server/dns_server.c @@ -669,13 +669,29 @@ static NTSTATUS dns_startup_interfaces(struct dns_server *dns, struct loadparm_c return NT_STATUS_INTERNAL_ERROR; } - num_interfaces = iface_list_count(ifaces); + if (ifaces != NULL) { + num_interfaces = iface_list_count(ifaces); - for (i=0; ilp_ctx, &ifaces); + if (lpcfg_interfaces(task->lp_ctx) && lpcfg_bind_interfaces_only(task->lp_ctx)) { + load_interface_list(task, task->lp_ctx, &ifaces); - if (iface_list_count(ifaces) == 0) { - task_server_terminate(task, "dns: no network interfaces configured", false); - return; + if (iface_list_count(ifaces) == 0) { + task_server_terminate(task, "dns: no network interfaces configured", false); + return; + } } task_server_set_title(task, "task[dns]"); -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 8ba8020 s4 dns: Make debug output less noisy via 319b239 s4 dns: Check if signing user is allowed to update records from 44fd8e7 fileserver:sysquotas: remove wrong cast http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 8ba802058644910741dc80940420781450a924b7 Author: Kai Blin Date: Thu Sep 6 22:53:32 2012 +0200 s4 dns: Make debug output less noisy Autobuild-User(master): Kai Blin Autobuild-Date(master): Fri Sep 7 00:31:56 CEST 2012 on sn-devel-104 commit 319b239dc4aeb2c6a928a70fc7a7dbad56d273cd Author: Kai Blin Date: Thu Sep 6 22:40:56 2012 +0200 s4 dns: Check if signing user is allowed to update records This should fix bug #9142 --- Summary of changes: source4/dns_server/dns_crypto.c |4 +- source4/dns_server/dns_query.c |2 +- source4/dns_server/dns_server.c |2 +- source4/dns_server/dns_update.c | 86 -- 4 files changed, 67 insertions(+), 27 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_crypto.c b/source4/dns_server/dns_crypto.c index 7362adc..7604a05 100644 --- a/source4/dns_server/dns_crypto.c +++ b/source4/dns_server/dns_crypto.c @@ -121,7 +121,7 @@ WERROR dns_verify_tsig(struct dns_server *dns, /* The TSIG record needs to be the last additional record */ if (found_tsig && i + 1 != packet->arcount) { - DEBUG(0, ("TSIG record not the last additional record!\n")); + DEBUG(1, ("TSIG record not the last additional record!\n")); return DNS_ERR(FORMAT_ERROR); } @@ -218,7 +218,7 @@ WERROR dns_verify_tsig(struct dns_server *dns, } if (!NT_STATUS_IS_OK(status)) { - DEBUG(0, ("Verifying tsig failed: %s\n", nt_errstr(status))); + DEBUG(1, ("Verifying tsig failed: %s\n", nt_errstr(status))); return ntstatus_to_werror(status); } diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 98ebc63..54e0c7f 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -509,7 +509,7 @@ static WERROR handle_tkey(struct dns_server *dns, return WERR_NOMEM; } } else { - DEBUG(0, ("GSS key negotiation returned %s\n", nt_errstr(status))); + DEBUG(1, ("GSS key negotiation returned %s\n", nt_errstr(status))); ret_tkey->rdata.tkey_record.error = DNS_RCODE_BADKEY; } diff --git a/source4/dns_server/dns_server.c b/source4/dns_server/dns_server.c index d9851b1..be1fecc 100644 --- a/source4/dns_server/dns_server.c +++ b/source4/dns_server/dns_server.c @@ -147,7 +147,7 @@ static struct tevent_req *dns_process_send(TALLOC_CTX *mem_ctx, ret = dns_verify_tsig(dns, state, &state->state, &state->in_packet, in); if (!W_ERROR_IS_OK(ret)) { - DEBUG(0, ("Bailing out early!\n")); + DEBUG(1, ("Failed to verify TSIG!\n")); state->dns_err = werr_to_dns_err(ret); tevent_req_done(req); return tevent_req_post(req, ev); diff --git a/source4/dns_server/dns_update.c b/source4/dns_server/dns_update.c index 61850a1..2df0b58 100644 --- a/source4/dns_server/dns_update.c +++ b/source4/dns_server/dns_update.c @@ -31,6 +31,7 @@ #include "dsdb/common/util.h" #include "smbd/service_task.h" #include "dns_server/dns_server.h" +#include "auth/auth.h" static WERROR dns_rr_to_dnsp(TALLOC_CTX *mem_ctx, const struct dns_res_rec *rrec, @@ -381,7 +382,8 @@ done: static WERROR handle_one_update(struct dns_server *dns, TALLOC_CTX *mem_ctx, const struct dns_name_question *zone, - const struct dns_res_rec *update) + const struct dns_res_rec *update, + const struct dns_server_tkey *tkey) { struct dnsp_DnssrvRpcRecord *recs = NULL; uint16_t rcount = 0; @@ -389,6 +391,7 @@ static WERROR handle_one_update(struct dns_server *dns, uint16_t i; WERROR werror; bool needs_add = false; + uint32_t access_mask = 0; DEBUG(2, ("Looking at record: \n")); if (DEBUGLVL(2)) { @@ -421,9 +424,24 @@ static WERROR handle_one_update(struct dns_server *dns, rcount = 0; needs_add = true; werror = WERR_OK; + access_mask = SEC_ADS_CREATE_CHILD;
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 5e492f8 s4 dns: Allow configuring signed updates via 2b17566 s4 dns: Make sure to remember incoming tkey name via 53f602c s4 dns: Verify incoming TSIG signatures via 7fe5e2c s4 dns: Handle GSS-TSIG signature creation via 956f41b s4 dns: When we got a TKEY, we need to remember which key to use for signing via e81d026 s4 dns: TKEY record needs to remember incoming algorithm via c0e6a4b s4 dns: Move dns_find_tkey to an extra file via 22fda8c s4 dns: Create IDL entry for TSIG-like record needed for signature check from 58d8d94 s4-dns: Fix linking the dns service. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 5e492f8d324d269c2eb0e12f6dca2cb8133c4b8e Author: Kai Blin Date: Wed Sep 5 01:27:00 2012 +0200 s4 dns: Allow configuring signed updates Autobuild-User(master): Kai Blin Autobuild-Date(master): Wed Sep 5 20:42:46 CEST 2012 on sn-devel-104 commit 2b17566e8902a326253257e1665b3b7a49e1aa26 Author: Kai Blin Date: Wed Sep 5 01:26:16 2012 +0200 s4 dns: Make sure to remember incoming tkey name commit 53f602c3744c0952f3385a39d5984d5a47b9905c Author: Kai Blin Date: Wed Sep 5 08:34:49 2012 +0200 s4 dns: Verify incoming TSIG signatures commit 7fe5e2cdcb17cee06ebde2717439c0aa964ac026 Author: Kai Blin Date: Wed Sep 5 08:34:04 2012 +0200 s4 dns: Handle GSS-TSIG signature creation commit 956f41bddf946d5e1e35f06632f40e7ac71b6588 Author: Kai Blin Date: Wed Sep 5 08:29:38 2012 +0200 s4 dns: When we got a TKEY, we need to remember which key to use for signing commit e81d026576cd1df9eb406c8ef0b0f27b7188b8ea Author: Kai Blin Date: Wed Sep 5 08:27:28 2012 +0200 s4 dns: TKEY record needs to remember incoming algorithm Samba3 (and older windows versions) use gss.microsoft.com, win7 (and the RFC) use gss-tsig commit c0e6a4b1b07c7aff49f19c4d8cf3de1ff020afab Author: Kai Blin Date: Wed Sep 5 08:24:52 2012 +0200 s4 dns: Move dns_find_tkey to an extra file commit 22fda8cb155041556a51106e5b1f058378c2c05b Author: Kai Blin Date: Wed Sep 5 08:16:43 2012 +0200 s4 dns: Create IDL entry for TSIG-like record needed for signature check --- Summary of changes: librpc/idl/dns.idl | 14 ++ source4/dns_server/dns_crypto.c | 359 ++ source4/dns_server/dns_query.c | 110 ++-- source4/dns_server/dns_server.c | 20 ++ source4/dns_server/dns_server.h | 18 ++ source4/dns_server/dns_update.c |7 +- source4/dns_server/dns_utils.c |2 + source4/dns_server/wscript_build |2 +- 8 files changed, 472 insertions(+), 60 deletions(-) create mode 100644 source4/dns_server/dns_crypto.c Changeset truncated at 500 lines: diff --git a/librpc/idl/dns.idl b/librpc/idl/dns.idl index a92c418..984f2b3 100644 --- a/librpc/idl/dns.idl +++ b/librpc/idl/dns.idl @@ -192,6 +192,20 @@ interface dns uint8 other_data[other_size]; } dns_tsig_record; + typedef [flag(NDR_NOALIGN|NDR_BIG_ENDIAN|NDR_PAHEX),public] struct { + dns_string name; + dns_qclass rr_class; + uint32 ttl; + dns_string algorithm_name; + uint16 time_prefix; /* 0 until February 2106*/ + uint32 time; + uint16 fudge; + uint16 original_id; + uint16 error; + uint16 other_size; + uint8 other_data[other_size]; + } dns_fake_tsig_rec; + typedef [nodiscriminant,public,flag(NDR_NOALIGN)] union { [case(DNS_QTYPE_A)] ipv4address ipv4_record; [case(DNS_QTYPE_NS)]dns_string ns_record; diff --git a/source4/dns_server/dns_crypto.c b/source4/dns_server/dns_crypto.c new file mode 100644 index 000..7362adc --- /dev/null +++ b/source4/dns_server/dns_crypto.c @@ -0,0 +1,359 @@ +/* + Unix SMB/CIFS implementation. + + DNS server handler for signed packets + + Copyright (C) 2012 Kai Blin + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <http://www.gnu.org/licen
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 558fa4c s4 dns: Revert erroneous push from wrong branch from 92bd7b0 s3:smb2_create: check for SMB2_CREATE_TAG_DHNC first http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 558fa4c45a87704c57893d61a5431fc8bb51385a Author: Kai Blin Date: Wed Sep 5 11:07:55 2012 +0200 s4 dns: Revert erroneous push from wrong branch I've pushed the wrong branch for this, sorry about that. Autobuild-User(master): Kai Blin Autobuild-Date(master): Wed Sep 5 14:10:54 CEST 2012 on sn-devel-104 --- Summary of changes: librpc/idl/dns.idl | 14 -- source4/dns_server/dns_crypto.c | 359 -- source4/dns_server/dns_query.c | 110 ++-- source4/dns_server/dns_server.c | 23 --- source4/dns_server/dns_server.h | 18 -- source4/dns_server/dns_update.c |7 +- source4/dns_server/dns_utils.c |2 - source4/dns_server/wscript_build |2 +- 8 files changed, 60 insertions(+), 475 deletions(-) delete mode 100644 source4/dns_server/dns_crypto.c Changeset truncated at 500 lines: diff --git a/librpc/idl/dns.idl b/librpc/idl/dns.idl index 984f2b3..a92c418 100644 --- a/librpc/idl/dns.idl +++ b/librpc/idl/dns.idl @@ -192,20 +192,6 @@ interface dns uint8 other_data[other_size]; } dns_tsig_record; - typedef [flag(NDR_NOALIGN|NDR_BIG_ENDIAN|NDR_PAHEX),public] struct { - dns_string name; - dns_qclass rr_class; - uint32 ttl; - dns_string algorithm_name; - uint16 time_prefix; /* 0 until February 2106*/ - uint32 time; - uint16 fudge; - uint16 original_id; - uint16 error; - uint16 other_size; - uint8 other_data[other_size]; - } dns_fake_tsig_rec; - typedef [nodiscriminant,public,flag(NDR_NOALIGN)] union { [case(DNS_QTYPE_A)] ipv4address ipv4_record; [case(DNS_QTYPE_NS)]dns_string ns_record; diff --git a/source4/dns_server/dns_crypto.c b/source4/dns_server/dns_crypto.c deleted file mode 100644 index 7362adc..000 --- a/source4/dns_server/dns_crypto.c +++ /dev/null @@ -1,359 +0,0 @@ -/* - Unix SMB/CIFS implementation. - - DNS server handler for signed packets - - Copyright (C) 2012 Kai Blin - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see <http://www.gnu.org/licenses/>. -*/ - -#include "includes.h" -#include "lib/crypto/hmacmd5.h" -#include "system/network.h" -#include "librpc/ndr/libndr.h" -#include "librpc/gen_ndr/ndr_dns.h" -#include "dns_server/dns_server.h" -#include "libcli/util/ntstatus.h" -#include "auth/auth.h" -#include "auth/gensec/gensec.h" - -static WERROR dns_copy_tsig(TALLOC_CTX *mem_ctx, - struct dns_res_rec *old, - struct dns_res_rec *new_rec) -{ - new_rec->name = talloc_strdup(mem_ctx, old->name); - W_ERROR_HAVE_NO_MEMORY(new_rec->name); - - new_rec->rr_type = old->rr_type; - new_rec->rr_class = old->rr_class; - new_rec->ttl = old->ttl; - new_rec->length = old->length; - new_rec->rdata.tsig_record.algorithm_name = talloc_strdup(mem_ctx, - old->rdata.tsig_record.algorithm_name); - W_ERROR_HAVE_NO_MEMORY(new_rec->rdata.tsig_record.algorithm_name); - - new_rec->rdata.tsig_record.time_prefix = old->rdata.tsig_record.time_prefix; - new_rec->rdata.tsig_record.time = old->rdata.tsig_record.time; - new_rec->rdata.tsig_record.fudge = old->rdata.tsig_record.fudge; - new_rec->rdata.tsig_record.mac_size = old->rdata.tsig_record.mac_size; - new_rec->rdata.tsig_record.mac = talloc_memdup(mem_ctx, - old->rdata.tsig_record.mac, - old->rdata.tsig_record.mac_size); - W_ERROR_HAVE_NO_MEMORY(new_rec->rdat
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 2311a2c s4 dns: Allow configuring signed updates via b5dd26c s4 dns: Make sure to remember incoming tkey name via 140a8d8 more tsig_verify stuff via 17c91b5 drop me via cf4333b hack: dns_sign_tsig correct memcpy via a0c2453 HACK remove debug statement via f3e44c3 s4 dns: Verify incoming TSIG signatures via fc9de26 s4 dns: Handle GSS-TSIG signatures from 15e3991 build: Remove unused deps from vfs modules http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 2311a2c9f5fdcb6f8336dbdb972963a35890a200 Author: Kai Blin Date: Wed Sep 5 01:27:00 2012 +0200 s4 dns: Allow configuring signed updates Autobuild-User(master): Kai Blin Autobuild-Date(master): Wed Sep 5 10:45:22 CEST 2012 on sn-devel-104 commit b5dd26cc694230ce9526369eb2ac4175a2d90abb Author: Kai Blin Date: Wed Sep 5 01:26:16 2012 +0200 s4 dns: Make sure to remember incoming tkey name commit 140a8d86acd9fe1b00a2865552f16f6250280d32 Author: Kai Blin Date: Wed Sep 5 08:09:22 2012 +0200 more tsig_verify stuff commit 17c91b5db0363b61c5f41d62b1c8073e89b40f09 Author: Kai Blin Date: Wed Sep 5 08:08:49 2012 +0200 drop me commit cf4333b0cd675271628d89ec263b9a352fa63906 Author: Kai Blin Date: Wed Sep 5 08:08:24 2012 +0200 hack: dns_sign_tsig correct memcpy commit a0c2453405fe8e92e0871b79eec0ceb76eec0aaa Author: Kai Blin Date: Wed Sep 5 08:07:45 2012 +0200 HACK remove debug statement commit f3e44c390c0082e585aec83372cdcdde19d76016 Author: Kai Blin Date: Mon Sep 3 08:06:55 2012 +0200 s4 dns: Verify incoming TSIG signatures commit fc9de264972ba46cfd9e8fc67e25aa7ee1fd51a2 Author: Kai Blin Date: Sun Sep 2 21:43:52 2012 +0200 s4 dns: Handle GSS-TSIG signatures --- Summary of changes: librpc/idl/dns.idl | 14 ++ source4/dns_server/dns_crypto.c | 359 ++ source4/dns_server/dns_query.c | 110 ++-- source4/dns_server/dns_server.c | 23 +++ source4/dns_server/dns_server.h | 18 ++ source4/dns_server/dns_update.c |7 +- source4/dns_server/dns_utils.c |2 + source4/dns_server/wscript_build |2 +- 8 files changed, 475 insertions(+), 60 deletions(-) create mode 100644 source4/dns_server/dns_crypto.c Changeset truncated at 500 lines: diff --git a/librpc/idl/dns.idl b/librpc/idl/dns.idl index a92c418..984f2b3 100644 --- a/librpc/idl/dns.idl +++ b/librpc/idl/dns.idl @@ -192,6 +192,20 @@ interface dns uint8 other_data[other_size]; } dns_tsig_record; + typedef [flag(NDR_NOALIGN|NDR_BIG_ENDIAN|NDR_PAHEX),public] struct { + dns_string name; + dns_qclass rr_class; + uint32 ttl; + dns_string algorithm_name; + uint16 time_prefix; /* 0 until February 2106*/ + uint32 time; + uint16 fudge; + uint16 original_id; + uint16 error; + uint16 other_size; + uint8 other_data[other_size]; + } dns_fake_tsig_rec; + typedef [nodiscriminant,public,flag(NDR_NOALIGN)] union { [case(DNS_QTYPE_A)] ipv4address ipv4_record; [case(DNS_QTYPE_NS)]dns_string ns_record; diff --git a/source4/dns_server/dns_crypto.c b/source4/dns_server/dns_crypto.c new file mode 100644 index 000..7362adc --- /dev/null +++ b/source4/dns_server/dns_crypto.c @@ -0,0 +1,359 @@ +/* + Unix SMB/CIFS implementation. + + DNS server handler for signed packets + + Copyright (C) 2012 Kai Blin + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <http://www.gnu.org/licenses/>. +*/ + +#include "includes.h" +#include "lib/crypto/hmacmd5.h" +#include "system/network.h" +#include "librpc/ndr/libndr.h" +#include "librpc/gen_ndr/ndr_dns.h" +#include "dns_server/dns_server.h" +#include "libcli/util/ntstatus.h" +#include "auth/auth.h" +#include "auth/gensec/gensec.h" + +static WERROR dns_copy_tsig(TALLOC_CTX *
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via c256566 s4 dns: Store TKEYs in a ringbuffer from e4505fc tdb: return unpack error on strdup failure http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit c256566aa97e040a9b3007c779b1006d20462ccb Author: Kai Blin Date: Fri Aug 31 13:41:19 2012 +0200 s4 dns: Store TKEYs in a ringbuffer This stops us from potentially being DoSed by tons of TKEYs Autobuild-User(master): Kai Blin Autobuild-Date(master): Fri Aug 31 22:46:01 CEST 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_query.c | 125 ++- source4/dns_server/dns_server.c | 27 source4/dns_server/dns_server.h | 11 +++- 3 files changed, 106 insertions(+), 57 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index e9c3a24..530b7b2 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -36,7 +36,6 @@ #include "auth/auth.h" #include "auth/credentials/credentials.h" #include "auth/gensec/gensec.h" -#include "lib/util/dlinklist.h" static WERROR create_response_rr(const struct dns_name_question *question, const struct dnsp_DnssrvRpcRecord *rec, @@ -321,19 +320,73 @@ static WERROR handle_question(struct dns_server *dns, return WERR_OK; } -static NTSTATUS create_new_tkey(TALLOC_CTX *mem_ctx, - struct dns_server *dns, - struct dns_server_tkey **tkey, - const char* name) +static NTSTATUS accept_gss_ticket(TALLOC_CTX *mem_ctx, + struct dns_server *dns, + struct dns_server_tkey *tkey, + const DATA_BLOB *key, + DATA_BLOB *reply, + uint16_t *dns_auth_error) +{ + NTSTATUS status; + + status = gensec_update(tkey->gensec, mem_ctx, dns->task->event_ctx, + *key, reply); + + if (NT_STATUS_EQUAL(NT_STATUS_MORE_PROCESSING_REQUIRED, status)) { + *dns_auth_error = DNS_RCODE_OK; + return status; + } + + if (NT_STATUS_IS_OK(status)) { + + status = gensec_session_info(tkey->gensec, tkey, &tkey->session_info); + if (!NT_STATUS_IS_OK(status)) { + *dns_auth_error = DNS_RCODE_BADKEY; + return status; + } + *dns_auth_error = DNS_RCODE_OK; + } + + return status; +} + +static struct dns_server_tkey *find_tkey(struct dns_server_tkey_store *store, +const char *name) +{ + struct dns_server_tkey *tkey = NULL; + uint16_t i = 0; + + do { + struct dns_server_tkey *tmp_key = store->tkeys[i]; + + i++; + i %= TKEY_BUFFER_SIZE; + + if (tmp_key == NULL) { + continue; + } + if (dns_name_equal(name, tmp_key->name)) { + tkey = tmp_key; + break; + } + } while (i != 0); + + return tkey; +} + +static NTSTATUS create_tkey(struct dns_server *dns, + const char* name, + struct dns_server_tkey **tkey) { NTSTATUS status; - struct dns_server_tkey *k = talloc_zero(mem_ctx, struct dns_server_tkey); + struct dns_server_tkey_store *store = dns->tkeys; + struct dns_server_tkey *k = talloc_zero(store, struct dns_server_tkey); if (k == NULL) { return NT_STATUS_NO_MEMORY; } - k->name = talloc_strdup(mem_ctx, name); + k->name = talloc_strdup(k, name); if (k->name == NULL) { return NT_STATUS_NO_MEMORY; @@ -363,52 +416,16 @@ static NTSTATUS create_new_tkey(TALLOC_CTX *mem_ctx, return status; } - *tkey = k; - return NT_STATUS_OK; -} - -static NTSTATUS accept_gss_ticket(TALLOC_CTX *mem_ctx, - struct dns_server *dns, - struct dns_server_tkey *tkey, - const DATA_BLOB *key, - DATA_BLOB *reply, - uint16_t *dns_auth_error) -{ - NTSTATUS status; - - status = gensec_update(tkey->gensec, mem_ctx, dns->task->event_ctx, - *key, reply); - - if (NT_STATUS_EQUAL(NT_STATUS_MORE_PROCESSING_REQUIRED, status)) { - *dns_au
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 7204dc9 s4 dns: Negotiate GSSAPI-based TKEYs from d2c0387 s4-kdc: Give information on how long the password history is http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 7204dc9708e5f5164dcd9b7cc3fcb2ea27dcd62e Author: Kai Blin Date: Thu Aug 30 09:04:07 2012 +0200 s4 dns: Negotiate GSSAPI-based TKEYs Autobuild-User(master): Kai Blin Autobuild-Date(master): Fri Aug 31 10:38:35 CEST 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_query.c | 224 ++ source4/dns_server/dns_server.c | 18 +++ source4/dns_server/dns_server.h | 11 ++ source4/dns_server/wscript_build |2 +- 4 files changed, 254 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 5978fe9..e9c3a24 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -33,6 +33,10 @@ #include "libcli/dns/libdns.h" #include "lib/util/util_net.h" #include "lib/util/tevent_werror.h" +#include "auth/auth.h" +#include "auth/credentials/credentials.h" +#include "auth/gensec/gensec.h" +#include "lib/util/dlinklist.h" static WERROR create_response_rr(const struct dns_name_question *question, const struct dnsp_DnssrvRpcRecord *rec, @@ -317,6 +321,214 @@ static WERROR handle_question(struct dns_server *dns, return WERR_OK; } +static NTSTATUS create_new_tkey(TALLOC_CTX *mem_ctx, + struct dns_server *dns, + struct dns_server_tkey **tkey, + const char* name) +{ + NTSTATUS status; + struct dns_server_tkey *k = talloc_zero(mem_ctx, struct dns_server_tkey); + + if (k == NULL) { + return NT_STATUS_NO_MEMORY; + } + + k->name = talloc_strdup(mem_ctx, name); + + if (k->name == NULL) { + return NT_STATUS_NO_MEMORY; + } + + status = samba_server_gensec_start(k, + dns->task->event_ctx, + dns->task->msg_ctx, + dns->task->lp_ctx, + dns->server_credentials, + "dns", + &k->gensec); + if (!NT_STATUS_IS_OK(status)) { + DEBUG(1, ("Failed to start GENSEC server code: %s\n", nt_errstr(status))); + *tkey = NULL; + return status; + } + + gensec_want_feature(k->gensec, GENSEC_FEATURE_SIGN); + + status = gensec_start_mech_by_oid(k->gensec, GENSEC_OID_SPNEGO); + + if (!NT_STATUS_IS_OK(status)) { + DEBUG(1, ("Failed to start GENSEC server code: %s\n", + nt_errstr(status))); + *tkey = NULL; + return status; + } + + *tkey = k; + return NT_STATUS_OK; +} + +static NTSTATUS accept_gss_ticket(TALLOC_CTX *mem_ctx, + struct dns_server *dns, + struct dns_server_tkey *tkey, + const DATA_BLOB *key, + DATA_BLOB *reply, + uint16_t *dns_auth_error) +{ + NTSTATUS status; + + status = gensec_update(tkey->gensec, mem_ctx, dns->task->event_ctx, + *key, reply); + + if (NT_STATUS_EQUAL(NT_STATUS_MORE_PROCESSING_REQUIRED, status)) { + *dns_auth_error = DNS_RCODE_OK; + return status; + } + + if (NT_STATUS_IS_OK(status)) { + + status = gensec_session_info(tkey->gensec, tkey, &tkey->session_info); + if (!NT_STATUS_IS_OK(status)) { + *dns_auth_error = DNS_RCODE_BADKEY; + return status; + } + *dns_auth_error = DNS_RCODE_OK; + } + + return status; +} + +static struct dns_server_tkey *find_tkey(struct dns_server *dns, +const char *name) +{ + struct dns_server_tkey *tkey = NULL; + + for (tkey = dns->tkeys; tkey != NULL; tkey = tkey->next) { + if (dns_name_equal(name, tkey->name)) { + break; + } + } + + return tkey; +} + +static WERROR handle_tkey(struct dns_server *dns, + TALLOC_CTX *mem_ctx, + const struct d
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via cea3bdb wintest: enable dns forwarding for internal dns via 1318b5b wintest: get original nameserver for forwarding on a more general place via 5305570 wintest: extend get_is_dc function with additional expectations via 884e28f6 wintest: check netcats exitstatus instead of output via ed3ded1 wintest: set recursive queries for internal dns via b45d4be wintest: add option to select the dns backend via 09bee25 wintest: set nameserver on a more general place via 226dbc1 wintest: add option to use ntvfs instead of s3fs via 9fcd4a8 wintest: add working bbaumbach.conf file for use with VirtualBox from dd763d6 Fix bug #8974 - Kernel oplocks are broken when uid(file) != uid(process). http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit cea3bdb1031c95b874447676bcecfdd3b4731968 Author: Björn Baumbach Date: Thu Jun 21 13:45:18 2012 +0200 wintest: enable dns forwarding for internal dns Internal DNS will forward dns requests to the original nameserver (specified in resolv.conf). Signed-off-by: Kai Blin Autobuild-User(master): Kai Blin Autobuild-Date(master): Thu Jun 21 23:47:35 CEST 2012 on sn-devel-104 commit 1318b5bb2c6ebc2a810cb899a27daf5d90505559 Author: Björn Baumbach Date: Thu Jun 21 13:43:22 2012 +0200 wintest: get original nameserver for forwarding on a more general place Signed-off-by: Kai Blin commit 5305570758e93cbe84f58161d71d65b219dde467 Author: Björn Baumbach Date: Tue Jun 5 13:57:59 2012 +0200 wintest: extend get_is_dc function with additional expectations Windows Server 2003 r2 answers "wintest2k3 is not a DC." Signed-off-by: Kai Blin commit 884e28f66b01a8bf21f855f91875f22defa121ab Author: Björn Baumbach Date: Tue Jun 12 19:45:51 2012 +0200 wintest: check netcats exitstatus instead of output There are many netcat implementations with different output messages. Signed-off-by: Kai Blin commit ed3ded11220d16c5ebfefd7e165eeb32e185f452 Author: Björn Baumbach Date: Tue Jun 5 10:35:19 2012 +0200 wintest: set recursive queries for internal dns Need dns recursive queries = yes, since host expects answers with RA-bit. Signed-off-by: Kai Blin commit b45d4beca54428cb71994fed40d44c9ba06bb4d3 Author: Björn Baumbach Date: Thu May 31 14:15:47 2012 +0200 wintest: add option to select the dns backend This is an option to use the internal dns. Signed-off-by: Kai Blin commit 09bee254f028368e59a462ab5d487546da6f940a Author: Björn Baumbach Date: Fri Jun 1 16:16:16 2012 +0200 wintest: set nameserver on a more general place Signed-off-by: Kai Blin commit 226dbc116da7eb59fd59a9fb8a88c05a13b74e05 Author: Björn Baumbach Date: Thu May 31 11:13:59 2012 +0200 wintest: add option to use ntvfs instead of s3fs Signed-off-by: Kai Blin commit 9fcd4a83a5c75d227846467756c64d2bf5adde9a Author: Björn Baumbach Date: Wed May 30 15:00:07 2012 +0200 wintest: add working bbaumbach.conf file for use with VirtualBox Signed-off-by: Kai Blin --- Summary of changes: wintest/conf/bbaumbach.conf | 97 +++ wintest/test-s4-howto.py| 36 +++- wintest/wintest.py | 46 3 files changed, 158 insertions(+), 21 deletions(-) create mode 100644 wintest/conf/bbaumbach.conf Changeset truncated at 500 lines: diff --git a/wintest/conf/bbaumbach.conf b/wintest/conf/bbaumbach.conf new file mode 100644 index 000..aaacd32 --- /dev/null +++ b/wintest/conf/bbaumbach.conf @@ -0,0 +1,97 @@ +# Björn Baumbachs wintest config file +# Using VirtualBox in headless mode. Since it's not possible to +# startup VMs in gui mode. + +# where the git checkout is +SOURCETREE: /home/bbaumba/src/git/samba + +# where to install Samba to +PREFIX: /smbTest/wintest + +# debug level which will be put in smb.conf +DEBUGLEVEL : 1 + +# commands to control VMs +VM_POWEROFF : su bbaumba -c "VBoxManage controlvm ${VMNAME} poweroff" +VM_RESTORE: su bbaumba -c "VBoxManage snapshot ${VMNAME} restore ${SNAPSHOT} && VBoxManage startvm ${VMNAME} --type headless" +VM_RESET : su bbaumba -c "VBoxManage controlvm ${VMNAME} reset" + +# interfaces to listen on +INTERFACE : wintest + +# this is an additional IP that will be used for named to listen +# on. It should not be the primary IP of the interface +INTERFACE_IP : 192.168.4.77 +INTERFACE_NET: 192.168.4.77/24 + +# how to run bind9 +BIND9 : /usr/sbin/named +NAMED_CHECKCONF : /usr/sb
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via f3df298 s4 dns: Correctly handle A questions for CNAMEs via 754c60e s4 dns: Structure tests a bit better from 02d9ba6 s3:smbd: change user_struct->vuid to uint64_t http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f3df2988ba6928cde0bd89da321bbe74fd76f53f Author: Kai Blin Date: Fri Jun 1 08:05:54 2012 +0200 s4 dns: Correctly handle A questions for CNAMEs When an A/ lookup is made for a name that actually is a CNAME record, we need to return the CNAME record, and then do the A/ lookup for the name the CNAME points at. This still fails for CNAMEs pointing at records for domains we need to ask our forwarders for. Autobuild-User: Kai Blin Autobuild-Date: Wed Jun 6 15:23:55 CEST 2012 on sn-devel-104 commit 754c60e4175c8cd077766cd6ea762bd46cdd41af Author: Kai Blin Date: Wed May 30 08:08:53 2012 +0200 s4 dns: Structure tests a bit better --- Summary of changes: source4/dns_server/dns_query.c | 61 +++-- source4/scripting/python/samba/tests/dns.py | 79 +++ 2 files changed, 135 insertions(+), 5 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 0e63058..40df3a1 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -231,11 +231,11 @@ static WERROR handle_question(struct dns_server *dns, const struct dns_name_question *question, struct dns_res_rec **answers, uint16_t *ancount) { - struct dns_res_rec *ans; + struct dns_res_rec *ans = *answers; WERROR werror; unsigned int ri; struct dnsp_DnssrvRpcRecord *recs; - uint16_t rec_count, ai = 0; + uint16_t rec_count, ai = *ancount; struct ldb_dn *dn = NULL; werror = dns_name2dn(dns, mem_ctx, question->name, &dn); @@ -244,16 +244,67 @@ static WERROR handle_question(struct dns_server *dns, werror = dns_lookup_records(dns, mem_ctx, dn, &recs, &rec_count); W_ERROR_NOT_OK_RETURN(werror); - ans = talloc_zero_array(mem_ctx, struct dns_res_rec, rec_count); - W_ERROR_HAVE_NO_MEMORY(ans); + ans = talloc_realloc(mem_ctx, ans, struct dns_res_rec, rec_count + ai); + if (ans == NULL) { + return WERR_NOMEM; + } for (ri = 0; ri < rec_count; ri++) { + if ((recs[ri].wType == DNS_TYPE_CNAME) && + ((question->question_type == DNS_QTYPE_A) || +(question->question_type == DNS_QTYPE_))) { + struct dns_name_question *new_q = + talloc(mem_ctx, struct dns_name_question); + + if (new_q == NULL) { + return WERR_NOMEM; + } + + /* We reply with one more record, so grow the array */ + ans = talloc_realloc(mem_ctx, ans, struct dns_res_rec, +rec_count + 1); + if (ans == NULL) { + TALLOC_FREE(new_q); + return WERR_NOMEM; + } + + /* First put in the CNAME record */ + werror = create_response_rr(question, &recs[ri], &ans, &ai); + if (!W_ERROR_IS_OK(werror)) { + return werror; + } + + /* And then look up the name it points at.. */ + + /* First build up the new question */ + new_q->question_type = question->question_type; + new_q->question_class = question->question_class; + if (new_q->question_type == DNS_QTYPE_A) { + new_q->name = talloc_strdup(new_q, recs[ri].data.ipv4); + } else if (new_q->question_type == DNS_QTYPE_) { + new_q->name = talloc_strdup(new_q, recs[ri].data.ipv6); + } + if (new_q->name == NULL) { + TALLOC_FREE(new_q); + return WERR_NOMEM; + } + /* and then call the lookup again */ + werror = handle_question(dns, mem_ctx, new_q, &ans, &ai); + if (!W_ERROR_IS_OK(werror)) { + return werror; + } + + + continu
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via aa01908 libcli/dns: Rename UDP-based calls to reflect their use via 42e1b94 Add myself as libcli/dns maintainer via 6a1ad76 s4-dns: Use W_ERROR_HAVE_NO_MEMORY in create_response_rr via 9d128bb s4-dns: Use proper talloc hierarchy for NS records in create_response_rr via ffc568e s4-dns: Use proper talloc hierarchy for records in create_response_rr via d5ce36b s4-dns: Remove sync dns_process via d4998cc s4-dns: Make the TCP dns server async via 230f933b s4-dns: Make the UDP dns server async via 4dbbd30 s4-dns: Remove sync dns_server_process_query via 2b6b7c6 s4-dns: Make dns_process_send asyn via 28b5219 s4-dns: Remove unused sync ask_forwarder wrapper via 03b3521 s4-dns: Make dns_server_process_query async via e2c1a8b s4-dns: Make ask_forwarder async via 54cde76 lib: add tevent_req_poll_werror via 6cdbce2 s4-dns: Create a proper talloc hierarchy in create_response_rr via 1171c56 s4-dns: Add debug output for unmappable WERROR to DNS errcode via 0b2743c s4-dns: Fix some typos via 5bc261f librpc: Fix some typos via da74d54 s4-dns: Remove some break; statements via 577a065 s4-dns: Fix an unlikely potential memleak via 1bdaf4b s4-dns: Use talloc_asprintf_append_buffer in create_response_rr via 1bbdf22 s4-dns: Add some NULL checks to create_response_rr from 40e47d0 s4:dbchecker - handle the "none" case correctly http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit aa0190825d4dcd9d6680638a06df5b4b7d89fd29 Author: Kai Blin Date: Tue May 29 23:05:14 2012 +0200 libcli/dns: Rename UDP-based calls to reflect their use Autobuild-User: Kai Blin Autobuild-Date: Wed May 30 02:35:27 CEST 2012 on sn-devel-104 commit 42e1b94f88dd47e4999af751b6d6c3278de3e422 Author: Kai Blin Date: Fri May 25 07:54:39 2012 +0200 Add myself as libcli/dns maintainer commit 6a1ad76c5ef7f77475192cb17a26dd0ecc26aade Author: Kai Blin Date: Wed May 30 00:30:29 2012 +0200 s4-dns: Use W_ERROR_HAVE_NO_MEMORY in create_response_rr commit 9d128bbb628bb2240cc95695c114d8befa331a6e Author: Kai Blin Date: Wed May 30 00:23:33 2012 +0200 s4-dns: Use proper talloc hierarchy for NS records in create_response_rr commit ffc568eb4202e50d7ac203d491a6716bdea74e9a Author: Kai Blin Date: Wed May 30 00:23:14 2012 +0200 s4-dns: Use proper talloc hierarchy for records in create_response_rr commit d5ce36b1487d679ef22198427d298ecad38b8af6 Author: Volker Lendecke Date: Tue May 29 10:03:13 2012 +0200 s4-dns: Remove sync dns_process Signed-off-by: Kai Blin commit d4998ccce73e1ca782b8bd40430be1a625a4c8fb Author: Volker Lendecke Date: Mon May 28 18:42:54 2012 +0200 s4-dns: Make the TCP dns server async Signed-off-by: Kai Blin commit 230f933babe72536a1bbb930b6c9d71df8b2b903 Author: Volker Lendecke Date: Mon May 28 18:42:54 2012 +0200 s4-dns: Make the UDP dns server async Signed-off-by: Kai Blin commit 4dbbd304e65cc9687fa4eaf1a1f3422588720ac4 Author: Volker Lendecke Date: Mon May 28 18:23:50 2012 +0200 s4-dns: Remove sync dns_server_process_query Signed-off-by: Kai Blin commit 2b6b7c64e137145dc5c3786eb8acb85645c51ba2 Author: Volker Lendecke Date: Thu May 24 17:02:57 2012 +0200 s4-dns: Make dns_process_send asyn Signed-off-by: Kai Blin commit 28b5219ad9abcefbee7c466ae42901d0e0d207ca Author: Volker Lendecke Date: Thu May 24 16:46:29 2012 +0200 s4-dns: Remove unused sync ask_forwarder wrapper Signed-off-by: Kai Blin commit 03b35211ab7ca659edf1f23fe84b49f0b3ee6ab5 Author: Volker Lendecke Date: Thu May 24 14:53:47 2012 +0200 s4-dns: Make dns_server_process_query async Signed-off-by: Kai Blin commit e2c1a8b87ae9fc563711e9fe5d02b915eec2cd3b Author: Volker Lendecke Date: Thu May 24 13:49:41 2012 +0200 s4-dns: Make ask_forwarder async Signed-off-by: Kai Blin commit 54cde76e376b7e6a781ff2841234d7f37eb6ea93 Author: Volker Lendecke Date: Thu May 24 13:49:26 2012 +0200 lib: add tevent_req_poll_werror Signed-off-by: Kai Blin commit 6cdbce266b6ecccf181429949104df700d58351c Author: Volker Lendecke Date: Tue May 29 15:20:21 2012 +0200 s4-dns: Create a proper talloc hierarchy in create_response_rr Pair-Programmed-With: Michael Adam Signed-off-by: Kai Blin commit 1171c562f6ba074413b730086c97787661ec9634 Author: Volker Lendecke Date: Tue May 29 09:45:44 2012 +0200 s4-dns: Add debug output for unmappable WERROR to DNS errcode Signed-off-by: Kai Blin commit 0b2743c71e509d40a587e278a4227950205bf50c Author: Volker Lendecke Date: Tue May 29 08:53:44 2012 +0200 s4-dns: Fix some typos Sig
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via f01c6cf s4 dns: unify error handling when bailing out via 7420698 s4 dns: Add TSIG and TKEY records to idl from e42e87d s3-docs: Fix several typos. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f01c6cf707087141fe244a1d90c5cdcb69322820 Author: Kai Blin Date: Wed Mar 28 12:19:51 2012 +0200 s4 dns: unify error handling when bailing out Autobuild-User: Kai Blin Autobuild-Date: Tue May 8 15:48:25 CEST 2012 on sn-devel-104 commit 74206984daa9c707a38675df88d6bbe660d876bc Author: Kai Blin Date: Tue Mar 13 08:04:14 2012 +0100 s4 dns: Add TSIG and TKEY records to idl --- Summary of changes: librpc/idl/dns.idl | 67 -- source4/dns_server/dns_server.c | 23 ++--- 2 files changed, 67 insertions(+), 23 deletions(-) Changeset truncated at 500 lines: diff --git a/librpc/idl/dns.idl b/librpc/idl/dns.idl index e012162..a92c418 100644 --- a/librpc/idl/dns.idl +++ b/librpc/idl/dns.idl @@ -46,17 +46,23 @@ interface dns /* rcode values */ typedef [public] enum { - DNS_RCODE_OK = 0x0, - DNS_RCODE_FORMERR = 0x1, - DNS_RCODE_SERVFAIL = 0x2, - DNS_RCODE_NXDOMAIN = 0x3, - DNS_RCODE_NOTIMP = 0x4, - DNS_RCODE_REFUSED = 0x5, - DNS_RCODE_YXDOMAIN = 0x6, - DNS_RCODE_YXRRSET = 0x7, - DNS_RCODE_NXRRSET = 0x8, - DNS_RCODE_NOTAUTH = 0x9, - DNS_RCODE_NOTZONE = 0xA + DNS_RCODE_OK = 0x00, + DNS_RCODE_FORMERR = 0x01, + DNS_RCODE_SERVFAIL = 0x02, + DNS_RCODE_NXDOMAIN = 0x03, + DNS_RCODE_NOTIMP = 0x04, + DNS_RCODE_REFUSED = 0x05, + DNS_RCODE_YXDOMAIN = 0x06, + DNS_RCODE_YXRRSET = 0x07, + DNS_RCODE_NXRRSET = 0x08, + DNS_RCODE_NOTAUTH = 0x09, + DNS_RCODE_NOTZONE = 0x0A, + DNS_RCODE_BADSIG = 0x10, + DNS_RCODE_BADKEY = 0x11, + DNS_RCODE_BADTIME = 0x12, + DNS_RCODE_BADMODE = 0x13, + DNS_RCODE_BADNAME = 0x14, + DNS_RCODE_BADALG = 0x15 } dns_rcode; typedef [public,enum16bit] enum { @@ -105,12 +111,24 @@ interface dns DNS_QTYPE_NSEC = 0x002F, DNS_QTYPE_DNSKEY = 0x0030, DNS_QTYPE_DHCID = 0x0031, + DNS_QTYPE_TKEY = 0x00F9, + DNS_QTYPE_TSIG = 0x00FA, DNS_QTYPE_AXFR = 0x00FC, DNS_QTYPE_MAILB = 0x00FD, DNS_QTYPE_MAILA = 0x00FE, DNS_QTYPE_ALL= 0x00FF } dns_qtype; + typedef [public,enum16bit] enum { + DNS_TKEY_MODE_NULL = 0x, + DNS_TKEY_MODE_SERVER = 0x0001, + DNS_TKEY_MODE_DH = 0x0002, + DNS_TKEY_MODE_GSSAPI = 0x0003, + DNS_TKEY_MODE_CLIENT = 0x0004, + DNS_TKEY_MODE_DELETE = 0x0005, + DNS_TKEY_MODE_LAST = 0x + } dns_tkey_mode; + typedef [public] struct { dns_string name; dns_qtype question_type; @@ -149,6 +167,31 @@ interface dns dns_string target; } dns_srv_record; + typedef [public] struct { + dns_string algorithm; + uint32 inception; + uint32 expiration; + dns_tkey_mode mode; + uint16 error; + uint16 key_size; + uint8 key_data[key_size]; + uint16 other_size; + uint8 other_data[other_size]; + } dns_tkey_record; + + typedef [public] struct { + dns_string algorithm_name; + uint16 time_prefix; /* 0 until February 2106*/ + uint32 time; + uint16 fudge; + uint16 mac_size; + uint8 mac[mac_size]; + uint16 original_id; + uint16 error; + uint16 other_size; + uint8 other_data[other_size]; + } dns_tsig_record; + typedef [nodiscriminant,public,flag(NDR_NOALIGN)] union { [case(DNS_QTYPE_A)] ipv4address ipv4_record; [case(DNS_QTYPE_NS)]dns_string ns_record; @@ -159,6 +202,8 @@ interface dns [case(DNS_QTYPE_TXT)] dns_txt_record txt_record; [case(DNS_QTYPE_)] ipv6address ipv6_record; [case(DNS_QTYPE_SRV)] dns_srv_record srv_record
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 60eb162 s4 dns: Allow updating PTR records. from 1e24997 s3: Avoid a crash with debug level 10 http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 60eb1621d2c3224a2c7e8bec947741446ecbc4b1 Author: Kai Blin Date: Fri Mar 30 17:19:48 2012 +0200 s4 dns: Allow updating PTR records. Autobuild-User: Kai Blin Autobuild-Date: Fri Mar 30 19:26:52 CEST 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_update.c |4 1 files changed, 4 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_update.c b/source4/dns_server/dns_update.c index d6b7640..3473a70 100644 --- a/source4/dns_server/dns_update.c +++ b/source4/dns_server/dns_update.c @@ -331,6 +331,10 @@ static WERROR dns_rr_to_dnsp(TALLOC_CTX *mem_ctx, rrec->rdata.srv_record.target); W_ERROR_HAVE_NO_MEMORY(r->data.srv.nameTarget); break; + case DNS_QTYPE_PTR: + r->data.ptr = talloc_strdup(mem_ctx, rrec->rdata.ptr_record); + W_ERROR_HAVE_NO_MEMORY(r->data.ptr); + break; case DNS_QTYPE_MX: r->data.mx.wPriority = rrec->rdata.mx_record.preference; r->data.mx.nameTarget = talloc_strdup(mem_ctx, -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 26f7a67 s4 dns: Only do recursive queries when allowed/desired via 06dd4d8 s4 dns: Check smb.conf if we should allow recursion via 533b2e6 s4 dns: Allow changing the dns operation flags in handlers via 8d9da67 s4 dns: Only forward for zones we don't own via a991391 s4 dns: Forward questions we can't answer to another server via 10b14fa s4 dns: Add a simple dns lookup helper via 7566e6a s4 dns: Add a simple async client library from 95ebb11 selftest.py: Add get_interface. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 26f7a676f9a0f6f8c5ae3bef9247c675734f35cd Author: Kai Blin Date: Tue Mar 27 15:00:01 2012 +0200 s4 dns: Only do recursive queries when allowed/desired If recursive queries are switched off in smb.conf or the client doesn't ask for recursion, don't recurse. Autobuild-User: Kai Blin Autobuild-Date: Tue Mar 27 17:39:26 CEST 2012 on sn-devel-104 commit 06dd4d8ee1c5440809fa87fd8a1f3cfac8e9036a Author: Kai Blin Date: Tue Mar 27 14:42:15 2012 +0200 s4 dns: Check smb.conf if we should allow recursion commit 533b2e6612bd6497c1d53c31912bccba0260a3e9 Author: Kai Blin Date: Tue Mar 27 13:59:03 2012 +0200 s4 dns: Allow changing the dns operation flags in handlers commit 8d9da67185aac48d7d0bc1e7b90262ae9afc6a64 Author: Kai Blin Date: Tue Mar 27 13:36:16 2012 +0200 s4 dns: Only forward for zones we don't own commit a99139160555072339f8f9cc5912c570158fc236 Author: Kai Blin Date: Tue Mar 27 08:42:22 2012 +0200 s4 dns: Forward questions we can't answer to another server This makes use of libdns and currently hardcodes the forward server, but it works. :) commit 10b14fa1c03fa9d686e94be20a2700954ae090fa Author: Kai Blin Date: Mon Mar 26 20:47:42 2012 +0200 s4 dns: Add a simple dns lookup helper commit 7566e6a5347b9d6b2b0b8b27f9211599febd8da1 Author: Kai Blin Date: Sun Mar 11 10:13:51 2012 +0100 s4 dns: Add a simple async client library --- Summary of changes: lib/param/loadparm.c | 21 + libcli/dns/dns.c | 172 ++ libcli/dns/libdns.h | 53 libcli/dns/wscript_build |5 + source4/dns_server/dns_query.c | 109 ++-- source4/dns_server/dns_server.c | 21 - source4/dns_server/dns_server.h |7 ++ source4/dns_server/dns_update.c |1 + source4/dns_server/dns_utils.c | 28 ++ source4/dns_server/wscript_build |2 +- utils/samba-dig.c| 160 +++ utils/wscript_build |7 ++ wscript_build|2 + 13 files changed, 575 insertions(+), 13 deletions(-) create mode 100644 libcli/dns/dns.c create mode 100644 libcli/dns/libdns.h create mode 100644 libcli/dns/wscript_build create mode 100644 utils/samba-dig.c create mode 100644 utils/wscript_build Changeset truncated at 500 lines: diff --git a/lib/param/loadparm.c b/lib/param/loadparm.c index bb59a79..e3792b6 100644 --- a/lib/param/loadparm.c +++ b/lib/param/loadparm.c @@ -1256,6 +1256,22 @@ static struct parm_struct parm_table[] = { .special= NULL, .enum_list = enum_dns_update_settings }, + { + .label = "dns forwarder", + .type = P_STRING, + .p_class= P_GLOBAL, + .offset = GLOBAL_VAR(dns_forwarder), + .special= NULL, + .enum_list = NULL + }, + { + .label = "dns recursive queries", + .type = P_BOOL, + .p_class= P_GLOBAL, + .offset = GLOBAL_VAR(dns_recursive_queries), + .special= NULL, + .enum_list = NULL + }, {NULL, P_BOOL, P_NONE, 0, NULL, NULL, 0} }; @@ -1536,7 +1552,10 @@ FN_GLOBAL_INTEGER(srv_minprotocol, srv_minprotocol) FN_GLOBAL_INTEGER(cli_maxprotocol, cli_maxprotocol) FN_GLOBAL_INTEGER(cli_minprotocol, cli_minprotocol) FN_GLOBAL_BOOL(paranoid_server_security, paranoid_server_security) + FN_GLOBAL_INTEGER(allow_dns_updates, allow_dns_updates) +FN_GLOBAL_CONST_STRING(dns_forwarder, dns_forwarder) +FN_GLOBAL_BOOL(dns_recursive_queries, dns_recursive_queries) FN_GLOBAL_INTEGER(server_signing, server_signing) FN_GLOBAL_INTEGER(client_signing, client_signing) @@ -3403,6 +3422,8 @@ struct loadparm_context *loadparm_init(TALLOC_CTX *mem_ctx) lpcfg_do_global_parameter(lp_ctx, "nsupdate command", "/usr/bin/nsupdate -g");
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 26a0e7a s4 dns: Test deleting records and fix a small bu via 1e6ef24 s4 dns: Be less chatty during tests via a4bc7dc s4 dns: Clean up tests a bit via 98ae359 s4 dns: Support TXT updates, add tests via e6c6f49 s4 dns: Support TXT queries via f9f1d98 s3 selftest: Allow DNS updates during testing from ce4531e tdb_wrap: Move to specific directory. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 26a0e7a3f5ba7f8d6af2d2b8d7a6acf1323e8c57 Author: Kai Blin Date: Sun Mar 11 00:25:57 2012 +0100 s4 dns: Test deleting records and fix a small bu Autobuild-User: Kai Blin Autobuild-Date: Sun Mar 11 02:27:45 CET 2012 on sn-devel-104 commit 1e6ef242ec65e4f8e9c8ffa44a09581b28c2599a Author: Kai Blin Date: Sun Mar 11 00:25:05 2012 +0100 s4 dns: Be less chatty during tests commit a4bc7dc281237c88682de796691cb458e4802e02 Author: Kai Blin Date: Sat Mar 10 23:49:18 2012 +0100 s4 dns: Clean up tests a bit commit 98ae3592ad058619b4953c08a0cb91e6fb44e573 Author: Kai Blin Date: Sat Mar 10 23:48:44 2012 +0100 s4 dns: Support TXT updates, add tests commit e6c6f4959558d89f811c3da281b10e3525660179 Author: Kai Blin Date: Sat Mar 10 23:47:29 2012 +0100 s4 dns: Support TXT queries commit f9f1d98e747e9126b9d301052f639bbc25db7a88 Author: Kai Blin Date: Sat Mar 10 23:43:44 2012 +0100 s3 selftest: Allow DNS updates during testing --- Summary of changes: selftest/target/Samba4.pm |4 +- source4/dns_server/dns_query.c | 11 +++ source4/dns_server/dns_update.c | 51 +--- source4/scripting/python/samba/tests/dns.py | 123 ++- 4 files changed, 174 insertions(+), 15 deletions(-) Changeset truncated at 500 lines: diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index 698cd12..d9385c8 100644 --- a/selftest/target/Samba4.pm +++ b/selftest/target/Samba4.pm @@ -1090,6 +1090,8 @@ sub provision_dc($$) my ($self, $prefix) = @_; print "PROVISIONING DC..."; +my $extra_conf_options = "netbios aliases = localDC1-a +allow dns updates = True"; my $ret = $self->provision($prefix, "domain controller", "localdc", @@ -1097,7 +1099,7 @@ sub provision_dc($$) "samba.example.com", "2008", "locDCpass1", - undef, "netbios aliases = localDC1-a"); + undef, $extra_conf_options); return undef unless(defined $ret); unless($self->add_wins_config("$prefix/private")) { diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 42aa11f..4277659 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -35,6 +35,8 @@ static WERROR create_response_rr(const struct dns_name_question *question, { struct dns_res_rec *ans = *answers; uint16_t ai = *ancount; + char *tmp; + uint32_t i; ZERO_STRUCT(ans[ai]); @@ -69,7 +71,16 @@ static WERROR create_response_rr(const struct dns_name_question *question, case DNS_QTYPE_PTR: ans[ai].rdata.ptr_record = talloc_strdup(ans, rec->data.ptr); break; + case DNS_QTYPE_TXT: + tmp = talloc_asprintf(ans, "\"%s\"", rec->data.txt.str[0]); + for (i=1; idata.txt.count; i++) { + tmp = talloc_asprintf_append(tmp, " \"%s\"", +rec->data.txt.str[i]); + } + ans[ai].rdata.txt_record.txt = tmp; + break; default: + DEBUG(0, ("Got unhandled type %u query.\n", rec->wType)); return DNS_ERR(NOT_IMPLEMENTED); } diff --git a/source4/dns_server/dns_update.c b/source4/dns_server/dns_update.c index 62cf9e5..3d7ecce 100644 --- a/source4/dns_server/dns_update.c +++ b/source4/dns_server/dns_update.c @@ -285,6 +285,10 @@ static WERROR dns_rr_to_dnsp(TALLOC_CTX *mem_ctx, const struct dns_res_rec *rrec, struct dnsp_DnssrvRpcRecord *r) { + char *tmp; + char *txt_record_txt; + char *saveptr = NULL; + if (rrec->rr_type == DNS_QTYPE_ALL) { return DNS_ERR(FORMAT_ERROR); } @@ -334,15 +338,30 @@ static WERROR dns_rr_to_dnsp(TALLOC_CTX *mem_ctx, W_ERROR_HAVE_
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 9a93f43 s4 dns: Add support for PTR queries. from 1930781 s4-librpc: Remove unused new_ev http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 9a93f43cebcb6b677548919f57badc1a857cb13b Author: Kai Blin Date: Fri Mar 9 10:43:27 2012 +0100 s4 dns: Add support for PTR queries. Autobuild-User: Kai Blin Autobuild-Date: Fri Mar 9 12:27:38 CET 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_query.c |6 +- 1 files changed, 5 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index 5320e21..42aa11f 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -66,6 +66,9 @@ static WERROR create_response_rr(const struct dns_name_question *question, ans[ai].rdata.soa_record.expire = rec->data.soa.expire; ans[ai].rdata.soa_record.minimum = rec->data.soa.minimum; break; + case DNS_QTYPE_PTR: + ans[ai].rdata.ptr_record = talloc_strdup(ans, rec->data.ptr); + break; default: return DNS_ERR(NOT_IMPLEMENTED); } @@ -109,7 +112,8 @@ static WERROR handle_question(struct dns_server *dns, (recs[ri].wType != question->question_type)) { continue; } - create_response_rr(question, &recs[ri], &ans, &ai); + werror = create_response_rr(question, &recs[ri], &ans, &ai); + W_ERROR_NOT_OK_RETURN(werror); } if (ai == 0) { -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via c7f6714 s4 dns: Fix TCP handling in the DNS server from 1f62df5 s3: Move a talloc_strdup out of the main code path http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit c7f67142c0693e73355e1a5748f729fad04415e0 Author: Kai Blin Date: Tue Mar 6 08:49:16 2012 +0100 s4 dns: Fix TCP handling in the DNS server Autobuild-User: Kai Blin Autobuild-Date: Tue Mar 6 21:17:19 CET 2012 on sn-devel-104 --- Summary of changes: source4/dns_server/dns_server.c | 26 ++-- source4/lib/stream/packet.c | 12 + source4/lib/stream/packet.h |1 + source4/scripting/python/samba/tests/dns.py | 34 +++ 4 files changed, 60 insertions(+), 13 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_server.c b/source4/dns_server/dns_server.c index 25873c2..cf43590 100644 --- a/source4/dns_server/dns_server.c +++ b/source4/dns_server/dns_server.c @@ -233,13 +233,13 @@ static void dns_tcp_call_loop(struct tevent_req *subreq) return; } - DEBUG(10,("Received krb5 TCP packet of length %lu from %s\n", + DEBUG(10,("Received DNS TCP packet of length %lu from %s\n", (long) call->in.length, tsocket_address_string(dns_conn->conn->remote_address, call))); /* skip length header */ - call->in.data += 4; - call->in.length -= 4; + call->in.data += 2; + call->in.length -= 2; /* Call dns */ status = dns_process(dns_conn->dns_socket->dns, call, &call->in, &call->out); @@ -251,9 +251,9 @@ static void dns_tcp_call_loop(struct tevent_req *subreq) } /* First add the length of the out buffer */ - RSIVAL(call->out_hdr, 0, call->out.length); + RSSVAL(call->out_hdr, 0, call->out.length); call->out_iov[0].iov_base = (char *) call->out_hdr; - call->out_iov[0].iov_len = 4; + call->out_iov[0].iov_len = 2; call->out_iov[1].iov_base = (char *) call->out.data; call->out_iov[1].iov_len = call->out.length; @@ -271,14 +271,14 @@ static void dns_tcp_call_loop(struct tevent_req *subreq) tevent_req_set_callback(subreq, dns_tcp_call_writev_done, call); /* -* The krb5 tcp pdu's has the length as 4 byte (initial_read_size), -* packet_full_request_u32 provides the pdu length then. +* The dns tcp pdu's has the length as 2 byte (initial_read_size), +* packet_full_request_u16 provides the pdu length then. */ subreq = tstream_read_pdu_blob_send(dns_conn, dns_conn->conn->event.ctx, dns_conn->tstream, - 4, /* initial_read_size */ - packet_full_request_u32, + 2, /* initial_read_size */ + packet_full_request_u16, dns_conn); if (subreq == NULL) { dns_tcp_terminate_connection(dns_conn, "dns_tcp_call_loop: " @@ -358,14 +358,14 @@ static void dns_tcp_accept(struct stream_connection *conn) conn->private_data = dns_conn; /* -* The krb5 tcp pdu's has the length as 4 byte (initial_read_size), -* packet_full_request_u32 provides the pdu length then. +* The dns tcp pdu's has the length as 2 byte (initial_read_size), +* packet_full_request_u16 provides the pdu length then. */ subreq = tstream_read_pdu_blob_send(dns_conn, dns_conn->conn->event.ctx, dns_conn->tstream, - 4, /* initial_read_size */ - packet_full_request_u32, + 2, /* initial_read_size */ + packet_full_request_u16, dns_conn); if (subreq == NULL) { dns_tcp_terminate_connection(dns_conn, "dns_tcp_accept: " diff --git a/source4/lib/stream/packet.c b/source4/lib/stream/packet.c index 3a7f600..b36d650 100644 --- a/source4/lib/stream/packet.c +++ b/source4/lib/stream/packet.c @@ -612,3 +612,15 @@ _PUBLIC_ NTSTATUS packet_full_request_u32(void *private_data, DATA_BLOB blob, si } return NT_STATUS_OK; } + +_PUBLIC_ NTSTATUS packet_full_request_u16(void *
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 803dc38 s4:provision: add "+dns" to server services if the dns backend is SAMBA_INTERNAL via 83c149d s4:provision: add a server services line to the smb.conf template for the dc via f489c68 s4:provision: add the possibility to provision "server services" in smb.conf via a876d51 s4:provision: improve a message from 0f79184 samba: check for AES encryption type defines. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 803dc389d1ade89708a3fedc91dd2c271f4a495b Author: Michael Adam Date: Sun Jan 8 01:02:58 2012 +0100 s4:provision: add "+dns" to server services if the dns backend is SAMBA_INTERNAL Signed-off-by: Kai Blin Autobuild-User: Kai Blin Autobuild-Date: Tue Jan 10 21:17:45 CET 2012 on sn-devel-104 commit 83c149de4d7ba91f799959bc411516fd163917df Author: Michael Adam Date: Thu Jan 5 00:45:12 2012 +0100 s4:provision: add a server services line to the smb.conf template for the dc Signed-off-by: Kai Blin commit f489c681ea4dcdf13c62876cb0e21ca93882599b Author: Michael Adam Date: Thu Jan 5 00:44:39 2012 +0100 s4:provision: add the possibility to provision "server services" in smb.conf Signed-off-by: Kai Blin commit a876d519fedc50ad4958ae772a2b836f00dcea48 Author: Michael Adam Date: Thu Jan 5 00:05:26 2012 +0100 s4:provision: improve a message Signed-off-by: Kai Blin --- Summary of changes: .../scripting/python/samba/provision/__init__.py | 22 +++ source4/setup/provision.smb.conf.dc|2 + 2 files changed, 19 insertions(+), 5 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/scripting/python/samba/provision/__init__.py b/source4/scripting/python/samba/provision/__init__.py index 5c4866c..295e272 100644 --- a/source4/scripting/python/samba/provision/__init__.py +++ b/source4/scripting/python/samba/provision/__init__.py @@ -554,7 +554,8 @@ def guess_names(lp=None, hostname=None, domain=None, dnsdomain=None, def make_smbconf(smbconf, hostname, domain, realm, serverrole, - targetdir, sid_generator="internal", eadb=False, lp=None): + targetdir, sid_generator="internal", eadb=False, lp=None, + server_services=None): """Create a new smb.conf file based on a couple of basic settings. """ assert smbconf is not None @@ -603,6 +604,11 @@ def make_smbconf(smbconf, hostname, domain, realm, serverrole, privdir = lp.get("private dir") lp.set("posix:eadb", os.path.abspath(os.path.join(privdir, "eadb.tdb"))) +if server_services is not None: +server_services_line = "server services = " + " ".join(server_services) +else: +server_services_line = "" + if targetdir is not None: privatedir_line = "private dir = " + os.path.abspath(os.path.join(targetdir, "private")) lockdir_line = "lock dir = " + os.path.abspath(targetdir) @@ -632,7 +638,8 @@ def make_smbconf(smbconf, hostname, domain, realm, serverrole, "PRIVATEDIR_LINE": privatedir_line, "LOCKDIR_LINE": lockdir_line, "STATEDIR_LINE": statedir_line, -"CACHEDIR_LINE": cachedir_line +"CACHEDIR_LINE": cachedir_line, +"SERVER_SERVICES_LINE": server_services_line }) # reload the smb.conf @@ -1586,6 +1593,10 @@ def provision(logger, session_info, credentials, smbconf=None, if not os.path.exists(os.path.dirname(smbconf)): os.makedirs(os.path.dirname(smbconf)) +server_services = None +if dns_backend == "SAMBA_INTERNAL": +server_services = [ "+dns" ] + # only install a new smb.conf if there isn't one there already if os.path.exists(smbconf): # if Samba Team members can't figure out the weird errors @@ -1596,10 +1607,11 @@ def provision(logger, session_info, credentials, smbconf=None, if data is None or data == "": make_smbconf(smbconf, hostname, domain, realm, serverrole, targetdir, sid_generator, useeadb, - lp=lp) + lp=lp, server_services=server_services) else: make_smbconf(smbconf, hostname, domain, realm, serverrole, - targetdir, sid_generator, useeadb, lp=lp) + targetdir, sid_generator, useeadb, lp=lp, + server_services=server_services) if lp is None:
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via b1fdf40 s4 dns: Allow updates based on smb.conf setting via afa98bd s4 dns: Add some debug output via d8a499a s4 dns: Actually handle the update request via c191ad7 s4 dns: Implement RFC-compatible update prescan via 02c9e18 s4 dns: Update prerequisite checking conforming to RFC via 589d995 s4 dns: Give better test output on RCODE mismatch via 8b82bad s4 dns: Move record lookup to dns_utils.c via 0922953 s4 dns: Implement dns record comparison function via db2573e s4 dns: Implement dns name equality check via a00709e s4 dns: Fix some typos in comments and a whitespace from b939144 check_name() not needed in mkdir. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit b1fdf4065e4569e58ffceb44e9f4105fa1f8740e Author: Kai Blin Date: Fri Dec 16 14:25:57 2011 +0100 s4 dns: Allow updates based on smb.conf setting Autobuild-User: Kai Blin Autobuild-Date: Sat Dec 17 04:19:40 CET 2011 on sn-devel-104 commit afa98bdc51c635cb7d7cc8c63497598e522610fd Author: Kai Blin Date: Fri Dec 16 14:22:51 2011 +0100 s4 dns: Add some debug output commit d8a499a27b1cc19189be7cf51f01888389346950 Author: Kai Blin Date: Fri Dec 16 14:21:52 2011 +0100 s4 dns: Actually handle the update request commit c191ad7e130c637faef23e7cec9d37c097da5a8b Author: Kai Blin Date: Fri Dec 16 14:07:11 2011 +0100 s4 dns: Implement RFC-compatible update prescan commit 02c9e18094f68d9014fe56c4d1b1c51fd22bd1b5 Author: Kai Blin Date: Fri Dec 16 13:45:22 2011 +0100 s4 dns: Update prerequisite checking conforming to RFC commit 589d995276f4868a1801d5d41f9a527a6323dbb9 Author: Kai Blin Date: Fri Dec 16 11:36:47 2011 +0100 s4 dns: Give better test output on RCODE mismatch commit 8b82bad0065895e0417f095c6b9ed2ada31fbdaa Author: Kai Blin Date: Fri Dec 16 09:43:47 2011 +0100 s4 dns: Move record lookup to dns_utils.c commit 0922953b10f3495e5d62867025e7e99ebc3e6613 Author: Kai Blin Date: Fri Dec 16 09:24:18 2011 +0100 s4 dns: Implement dns record comparison function commit db2573eadfd9389391f6daf73432de7f73b46e81 Author: Kai Blin Date: Fri Dec 16 09:21:51 2011 +0100 s4 dns: Implement dns name equality check commit a00709eff1c3f9e53fcfbbc93ac498cb182c9ac7 Author: Kai Blin Date: Fri Dec 16 09:13:31 2011 +0100 s4 dns: Fix some typos in comments and a whitespace --- Summary of changes: lib/param/loadparm.c | 12 + lib/param/param.h |1 + lib/param/param_enums.c|8 + librpc/idl/dns.idl |7 +- source3/param/loadparm.c |1 + source4/dns_server/dns_query.c | 43 +-- source4/dns_server/dns_server.c|8 +- source4/dns_server/dns_server.h| 17 +- source4/dns_server/dns_update.c| 624 ++-- .../libnet/grouptest.h => dns_server/dns_update.h} | 11 +- source4/dns_server/dns_utils.c | 183 ++ source4/scripting/python/samba/tests/dns.py| 100 +++- 12 files changed, 922 insertions(+), 93 deletions(-) copy source4/{torture/libnet/grouptest.h => dns_server/dns_update.h} (81%) Changeset truncated at 500 lines: diff --git a/lib/param/loadparm.c b/lib/param/loadparm.c index 8ed9ced..2c59a3e 100644 --- a/lib/param/loadparm.c +++ b/lib/param/loadparm.c @@ -65,6 +65,7 @@ #include "s3_param.h" #include "lib/util/bitmap.h" #include "libcli/smb/smb_constants.h" +#include "source4/dns_server/dns_update.h" #define standard_sub_basic talloc_strdup @@ -1223,6 +1224,14 @@ static struct parm_struct parm_table[] = { .special= NULL, .enum_list = NULL }, + { + .label = "allow dns updates", + .type = P_ENUM, + .p_class= P_GLOBAL, + .offset = GLOBAL_VAR(allow_dns_updates), + .special= NULL, + .enum_list = enum_dns_update_settings + }, {NULL, P_BOOL, P_NONE, 0, NULL, NULL, 0} }; @@ -1503,6 +1512,7 @@ FN_GLOBAL_INTEGER(srv_minprotocol, srv_minprotocol) FN_GLOBAL_INTEGER(cli_maxprotocol, cli_maxprotocol) FN_GLOBAL_INTEGER(cli_minprotocol, cli_minprotocol) FN_GLOBAL_BOOL(paranoid_server_security, paranoid_server_security) +FN_GLOBAL_INTEGER(allow_dns_updates, allow_dns_updates) FN_GLOBAL_INTEGER(server_signing, server_signing) FN_GLOBAL_INTEGER(client_signing, client_signing) @@ -3362,6 +3372,8 @@ struct loadparm_context *loadparm_init(TALLOC_CTX *
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via c01efc1 s4 dns: Update requests with QCLASS != IN or ALL trigger NOTIMPLEMENTED errors via 358a81e s4 dns: Add test to prove two updates in one packet are a FORMERR via 509acc7 s4 dns: More explicitly use the first question of an update packet only via 3fbb76c s4 dns: Get rid of const qualifier for prereqs, we do need to allocate those from 85f8d97 Revert "Install (platform-independent) python scripts to the PYTHONDIR rather than PYTHONARCHDIR." http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit c01efc1207b097517623d71b2ed9a24bb9c255de Author: Kai Blin Date: Fri Dec 9 01:26:39 2011 +0100 s4 dns: Update requests with QCLASS != IN or ALL trigger NOTIMPLEMENTED errors Autobuild-User: Kai Blin Autobuild-Date: Fri Dec 9 03:32:28 CET 2011 on sn-devel-104 commit 358a81eff5279a69270964226b553fb5243ecb84 Author: Kai Blin Date: Fri Dec 9 01:14:35 2011 +0100 s4 dns: Add test to prove two updates in one packet are a FORMERR commit 509acc71dd8534539021b0ec57dd83a841119793 Author: Kai Blin Date: Fri Dec 9 00:59:34 2011 +0100 s4 dns: More explicitly use the first question of an update packet only commit 3fbb76c119eaa1becb2df72d54cd4685771628df Author: Kai Blin Date: Fri Dec 9 00:58:32 2011 +0100 s4 dns: Get rid of const qualifier for prereqs, we do need to allocate those --- Summary of changes: source4/dns_server/dns_server.h |6 ++-- source4/dns_server/dns_update.c | 13 --- source4/scripting/python/samba/tests/dns.py | 30 +++ 3 files changed, 42 insertions(+), 7 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/dns_server/dns_server.h b/source4/dns_server/dns_server.h index 28351e8..d658b2a 100644 --- a/source4/dns_server/dns_server.h +++ b/source4/dns_server/dns_server.h @@ -49,9 +49,9 @@ WERROR dns_server_process_query(struct dns_server *dns, WERROR dns_server_process_update(struct dns_server *dns, TALLOC_CTX *mem_ctx, struct dns_name_packet *in, -const struct dns_res_rec *prereqs, uint16_t prereq_count, -struct dns_res_rec **updates, uint16_t *update_count, -struct dns_res_rec **additional, uint16_t *arcount); +struct dns_res_rec *prereqs, uint16_t prereq_count, +struct dns_res_rec **updates,uint16_t *update_count, +struct dns_res_rec **additional, uint16_t *arcount); uint8_t werr_to_dns_err(WERROR werror); bool dns_name_match(const char *zone, const char *name, size_t *host_part_len); diff --git a/source4/dns_server/dns_update.c b/source4/dns_server/dns_update.c index a9fabf6..55589d2 100644 --- a/source4/dns_server/dns_update.c +++ b/source4/dns_server/dns_update.c @@ -126,9 +126,9 @@ static WERROR update_prescan(const struct dns_name_question *zone, WERROR dns_server_process_update(struct dns_server *dns, TALLOC_CTX *mem_ctx, struct dns_name_packet *in, -const struct dns_res_rec *prereqs, uint16_t prereq_count, -struct dns_res_rec **updates, uint16_t *update_count, -struct dns_res_rec **additional, uint16_t *arcount) +struct dns_res_rec *prereqs, uint16_t prereq_count, +struct dns_res_rec **updates,uint16_t *update_count, +struct dns_res_rec **additional, uint16_t *arcount) { struct dns_name_question *zone; const struct dns_server_zone *z; @@ -140,7 +140,12 @@ WERROR dns_server_process_update(struct dns_server *dns, return DNS_ERR(FORMAT_ERROR); } - zone = in->questions; + zone = &in->questions[0]; + + if (zone->question_class != DNS_QCLASS_IN && + zone->question_class != DNS_QCLASS_ANY) { + return DNS_ERR(NOT_IMPLEMENTED); + } if (zone->question_type != DNS_QTYPE_SOA) { return DNS_ERR(FORMAT_ERROR); diff --git a/source4/scripting/python/samba/tests/dns.py b/source4/scripting/python/samba/tests/dns.py index 9f53225..60003fc 100644 --- a/source4/scripting/python/samba/tests/dns.py +++ b/source4/scripting/python/samba/tests/dns.py @@ -187,6 +187,36 @@ class DNSTest(TestCase): self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) self.assertEquals(response.ancount, 1) +def test_two_updates(self):
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via c326b37 s4 dns: Test SOA queries from 05bc4de Revert making public of the samba-module library. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit c326b37358260ba4f3a95463acdbf02ddae0ab97 Author: Kai Blin Date: Sat Dec 3 19:08:09 2011 +0100 s4 dns: Test SOA queries Autobuild-User: Kai Blin Autobuild-Date: Sat Dec 3 20:52:51 CET 2011 on sn-devel-104 --- Summary of changes: source4/scripting/python/samba/tests/dns.py | 32 +++ 1 files changed, 32 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/scripting/python/samba/tests/dns.py b/source4/scripting/python/samba/tests/dns.py index df10b71..9f53225 100644 --- a/source4/scripting/python/samba/tests/dns.py +++ b/source4/scripting/python/samba/tests/dns.py @@ -154,6 +154,38 @@ class DNSTest(TestCase): response = self.dns_transaction_udp(p) self.assert_dns_rcode_equals(response, dns.DNS_RCODE_NOTIMP) +# Only returns an authority section entry in BIND and Win DNS +# FIXME: Enable one Samba implements this feature +#def test_soa_hostname_query(self): +#"create a SOA query for a hostname" +#p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +#questions = [] +# +#name = "%s.%s" % (os.getenv('DC_SERVER'), self.get_dns_domain()) +#q = self.make_name_question(name, dns.DNS_QTYPE_SOA, dns.DNS_QCLASS_IN) +#questions.append(q) +# +#self.finish_name_packet(p, questions) +#response = self.dns_transaction_udp(p) +#self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) +#self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) +## We don't get SOA records for single hosts +#self.assertEquals(response.ancount, 0) + +def test_soa_domain_query(self): +"create a SOA query for a domain" +p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +questions = [] + +name = self.get_dns_domain() +q = self.make_name_question(name, dns.DNS_QTYPE_SOA, dns.DNS_QCLASS_IN) +questions.append(q) + +self.finish_name_packet(p, questions) +response = self.dns_transaction_udp(p) +self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) +self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) +self.assertEquals(response.ancount, 1) if __name__ == "__main__": import unittest -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 9f1eb8a s4 dns: Test QCLASS_NONE query via 8685a35 s4 dns: Test QTYPE_ALL query via 16d9ebb s4 dns: Check more of the returned values for the A query via 1a599da s4 dns: Move dns_transaction_udp to other helper functions from 12123e7 pidl:Samba4/NDR/Parser: don't generate code for [ignore] pointers http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 9f1eb8ab8ef17a48653f3af51cfd2e678b032595 Author: Kai Blin Date: Thu Nov 24 12:14:55 2011 +0100 s4 dns: Test QCLASS_NONE query Autobuild-User: Kai Blin Autobuild-Date: Thu Nov 24 14:10:45 CET 2011 on sn-devel-104 commit 8685a35e9c3ce9d84ef8c1b9af12213701e50fa8 Author: Kai Blin Date: Thu Nov 24 12:11:26 2011 +0100 s4 dns: Test QTYPE_ALL query commit 16d9ebb396db2552de77706b644f299a3c2be79d Author: Kai Blin Date: Thu Nov 24 12:10:40 2011 +0100 s4 dns: Check more of the returned values for the A query commit 1a599da550fb54fd6fb4cc2db827e7ea435ad51d Author: Kai Blin Date: Thu Nov 24 12:09:58 2011 +0100 s4 dns: Move dns_transaction_udp to other helper functions --- Summary of changes: source4/scripting/python/samba/tests/dns.py | 69 ++- 1 files changed, 56 insertions(+), 13 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/scripting/python/samba/tests/dns.py b/source4/scripting/python/samba/tests/dns.py index 25505d9..df10b71 100644 --- a/source4/scripting/python/samba/tests/dns.py +++ b/source4/scripting/python/samba/tests/dns.py @@ -66,6 +66,20 @@ class DNSTest(TestCase): "Helper to get dns domain" return os.getenv('REALM', 'example.com').lower() +def dns_transaction_udp(self, packet, host=os.getenv('DC_SERVER_IP')): +"send a DNS query and read the reply" +s = None +try: +send_packet = ndr.ndr_pack(packet) +s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM, 0) +s.connect((host, 53)) +s.send(send_packet, 0) +recv_packet = s.recv(2048, 0) +return ndr.ndr_unpack(dns.name_packet, recv_packet) +finally: +if s is not None: +s.close() + def test_one_a_query(self): "create a query packet containing one query record" p = self.make_name_packet(dns.DNS_OPCODE_QUERY) @@ -80,6 +94,9 @@ class DNSTest(TestCase): response = self.dns_transaction_udp(p) self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) +self.assertEquals(response.ancount, 1) +self.assertEquals(response.answers[0].rdata, + os.getenv('DC_SERVER_IP')) def test_two_queries(self): "create a query packet containing two query records" @@ -98,19 +115,45 @@ class DNSTest(TestCase): response = self.dns_transaction_udp(p) self.assert_dns_rcode_equals(response, dns.DNS_RCODE_FORMERR) -def dns_transaction_udp(self, packet, host=os.getenv('DC_SERVER_IP')): -"send a DNS query and read the reply" -s = None -try: -send_packet = ndr.ndr_pack(packet) -s = socket.socket(socket.AF_INET, socket.SOCK_DGRAM, 0) -s.connect((host, 53)) -s.send(send_packet, 0) -recv_packet = s.recv(2048, 0) -return ndr.ndr_unpack(dns.name_packet, recv_packet) -finally: -if s is not None: -s.close() +def test_qtype_all_query(self): +"create a QTYPE_ALL query" +p = self.make_name_packet(dns.DNS_OPCODE_QUERY) +questions = [] + +name = "%s.%s" % (os.getenv('DC_SERVER'), self.get_dns_domain()) +q = self.make_name_question(name, dns.DNS_QTYPE_ALL, dns.DNS_QCLASS_IN) +print "asking for ", q.name +questions.append(q) + +self.finish_name_packet(p, questions) +response = self.dns_transaction_udp(p) + +num_answers = 1 +dc_ipv6 = os.getenv('DC_SERVER_IPV6') +if dc_ipv6 is not None: +num_answers += 1 + +self.assert_dns_rcode_equals(response, dns.DNS_RCODE_OK) +self.assert_dns_opcode_equals(response, dns.DNS_OPCODE_QUERY) +self.assertEquals(response.ancount, num_answers) +self.assertEquals(response.answers[0].rdata, + os.getenv('DC_SERVER_IP')) +if dc_ipv6 is not None: +self.assertEquals(response.answers[1].rdata, dc_ipv6) + +def test_qclass_none_query(self): +"create a QCLASS_NONE quer
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 81b4db7 s3 libaddns: Prevent a crash when dns_create_update fails from b16f539 s4-dns: added --no-credentials option to samba_dnsupdate http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 81b4db74a704fbc57e7fed8b8a75fc6de18a4e8d Author: Kai Blin Date: Tue Nov 22 11:26:04 2011 +0100 s3 libaddns: Prevent a crash when dns_create_update fails When dns_create_update() fails, it does not initialize *req, and then TALLOC_FREE(req) in the error handling crashes if we're lucky. Instead of going into the generic error handling, treat the failure in dns_create_update() like dns_create_update_request() and just pass on the error. Thanks to Harry Mason for reporting this issue. Autobuild-User: Kai Blin Autobuild-Date: Tue Nov 22 14:29:07 CET 2011 on sn-devel-104 --- Summary of changes: lib/addns/dnsrecord.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/addns/dnsrecord.c b/lib/addns/dnsrecord.c index 045fd46..de70bca 100644 --- a/lib/addns/dnsrecord.c +++ b/lib/addns/dnsrecord.c @@ -377,7 +377,7 @@ DNS_ERROR dns_create_probe(TALLOC_CTX *mem_ctx, const char *zone, uint16 i; err = dns_create_update(mem_ctx, zone, &req); - if (!ERR_DNS_IS_OK(err)) goto error; + if (!ERR_DNS_IS_OK(err)) return err; err = dns_create_name_not_in_use_record(req, host, QTYPE_CNAME, &rec); if (!ERR_DNS_IS_OK(err)) goto error; -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 468fa95 s4 dns: Reduce test output noise by upping log level for dns_name_packet logging via e5ebda4 s4 dns: Add a first test case via ef4bda5 s4 dns: Turn on internal DNS server during testing via bd8aafc socket_wrapper: Added python interface to socket_wrapper from f7c8af7 samba.tests.dsdb: Import TestCase from samba.tests. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 468fa95df2a682c39bd46c8e451961994b91f3c4 Author: Kai Blin Date: Tue Nov 15 08:38:27 2011 +0100 s4 dns: Reduce test output noise by upping log level for dns_name_packet logging Autobuild-User: Kai Blin Autobuild-Date: Thu Nov 17 20:10:05 CET 2011 on sn-devel-104 commit e5ebda41563ed6152bae9ffcf873679878de Author: Kai Blin Date: Fri Nov 11 00:32:09 2011 +0100 s4 dns: Add a first test case commit ef4bda5c767215f09c035192587a9a29e8a3754a Author: Kai Blin Date: Tue Nov 8 00:34:01 2011 +0100 s4 dns: Turn on internal DNS server during testing commit bd8aafc530ba473acefd53665b73a47d1ebbb3a5 Author: Amitay Isaacs Date: Fri Oct 14 17:24:16 2011 +1100 socket_wrapper: Added python interface to socket_wrapper The socket_wrapper does not support setting blocking flag or timeouts on the sockets. To use socket module in python, use from samba import socket Signed-off-by: Kai Blin --- Summary of changes: lib/socket_wrapper/py_socket_wrapper.c | 876 +++ lib/socket_wrapper/socket.py| 52 ++ lib/socket_wrapper/wscript_build| 10 + selftest/target/Samba4.pm |2 +- source4/dns_server/dns_server.c |9 +- source4/scripting/python/samba/tests/dns.py | 117 source4/selftest/tests.py |3 + 7 files changed, 1065 insertions(+), 4 deletions(-) create mode 100644 lib/socket_wrapper/py_socket_wrapper.c create mode 100644 lib/socket_wrapper/socket.py create mode 100644 source4/scripting/python/samba/tests/dns.py Changeset truncated at 500 lines: diff --git a/lib/socket_wrapper/py_socket_wrapper.c b/lib/socket_wrapper/py_socket_wrapper.c new file mode 100644 index 000..405a43a --- /dev/null +++ b/lib/socket_wrapper/py_socket_wrapper.c @@ -0,0 +1,876 @@ +/* + * Copyright (C) Amitay Isaacs 2011 + * + * All rights reserved. + * + * Redistribution and use in source and binary forms, with or without + * modification, are permitted provided that the following conditions + * are met: + * + * 1. Redistributions of source code must retain the above copyright + *notice, this list of conditions and the following disclaimer. + * + * 2. Redistributions in binary form must reproduce the above copyright + *notice, this list of conditions and the following disclaimer in the + *documentation and/or other materials provided with the distribution. + * + * 3. Neither the name of the author nor the names of its contributors + *may be used to endorse or promote products derived from this software + *without specific prior written permission. + * + * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND + * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE + * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE + * ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE + * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL + * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS + * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) + * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT + * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY + * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF + * SUCH DAMAGE. + * + */ + +/* + Python interface to socket wrapper library. + + Passes all socket communication over unix domain sockets if the environment + variable SOCKET_WRAPPER_DIR is set. +*/ + +#include +#include +#include "replace/replace.h" +#include "system/network.h" +#include "socket_wrapper.h" + +#ifndef Py_RETURN_NONE +#define Py_RETURN_NONE return Py_INCREF(Py_None), Py_None +#endif + +#ifndef Py_TYPE /* Py_TYPE is only available on Python > 2.6 */ +#define Py_TYPE(ob)(((PyObject*)(ob))->ob_type) +#endif + +#ifndef PY_CHECK_TYPE +#define PY_CHECK_TYPE(type, var, fail) \ + if (!PyObject_TypeCheck(var, type)) {\ + PyErr_Format(PyExc_TypeError, __location__ ": Expected type '%s' for '%s' of type '%s'", (type)->tp_name, #var, Py_TYPE(var)->tp_name); \ +
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 468fcfd dns: Fix offset check in ndr_pull_component via 7f24a2b nbt: Fix offset check in ndr_pull_component via a243473 s4 dns: the opcode is called OPCODE_UPDATE in the RFC, not OPCODE_REGISTER via 57bf64b s4 dns: Handle QCLASS_NONE queries via 61913f8 s4 dns: Support DNS_QTYPE_ALL queries via 23000bc dns: Build the python bindings from 9b4c300 s3:smbd: also send the server name in the negprot response http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 468fcfd8be4a246d9860272a286eb0fe7555a819 Author: Kai Blin Date: Thu Sep 29 19:31:07 2011 -0700 dns: Fix offset check in ndr_pull_component Autobuild-User: Kai Blin Autobuild-Date: Fri Nov 4 17:25:16 CET 2011 on sn-devel-104 commit 7f24a2b9136dae2c1dd1feced8c92801b25b5fb3 Author: Kai Blin Date: Thu Sep 29 19:30:39 2011 -0700 nbt: Fix offset check in ndr_pull_component commit a243473b490c7345333eba7ad3f2033dfdbafdaa Author: Kai Blin Date: Tue Sep 27 19:51:55 2011 -0700 s4 dns: the opcode is called OPCODE_UPDATE in the RFC, not OPCODE_REGISTER commit 57bf64b37569c93fecfbdd3e9fe0c4f0acfb679e Author: Kai Blin Date: Tue Sep 27 18:05:38 2011 -0700 s4 dns: Handle QCLASS_NONE queries commit 61913f85062eb6425bc6eb0a3f2e10aadd075a36 Author: Kai Blin Date: Tue Sep 27 17:36:42 2011 -0700 s4 dns: Support DNS_QTYPE_ALL queries commit 23000bcf2e6cfdb362d7cdbedd6a95d5422080da Author: Kai Blin Date: Mon Sep 26 22:25:51 2011 -0700 dns: Build the python bindings --- Summary of changes: librpc/idl/dns.idl |2 +- librpc/ndr/ndr_dns.c|2 +- librpc/ndr/ndr_nbt.c|2 +- librpc/wscript_build|7 ++- source4/dns_server/dns_query.c | 173 ++ source4/dns_server/dns_server.c |2 +- source4/librpc/wscript_build|6 ++ 7 files changed, 80 insertions(+), 114 deletions(-) Changeset truncated at 500 lines: diff --git a/librpc/idl/dns.idl b/librpc/idl/dns.idl index 08a1699..a60c314 100644 --- a/librpc/idl/dns.idl +++ b/librpc/idl/dns.idl @@ -36,7 +36,7 @@ interface dns DNS_OPCODE_QUERY = (0x0<<11), DNS_OPCODE_IQUERY = (0x1<<11), DNS_OPCODE_STATUS = (0x2<<11), - DNS_OPCODE_REGISTER = (0x5<<11), + DNS_OPCODE_UPDATE = (0x5<<11), DNS_OPCODE_RELEASE= (0x6<<11), DNS_OPCODE_WACK = (0x7<<11), DNS_OPCODE_REFRESH= (0x8<<11), diff --git a/librpc/ndr/ndr_dns.c b/librpc/ndr/ndr_dns.c index 1004db0..27d8493 100644 --- a/librpc/ndr/ndr_dns.c +++ b/librpc/ndr/ndr_dns.c @@ -88,7 +88,7 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr, "reserved lenght field: 0x%02x", (len &0xC)); } - if (*offset + len + 2 > ndr->data_size) { + if (*offset + len + 1 > ndr->data_size) { return ndr_pull_error(ndr, NDR_ERR_STRING, "BAD DNS NAME component, "\ "length too long"); diff --git a/librpc/ndr/ndr_nbt.c b/librpc/ndr/ndr_nbt.c index 02297d3..f2a1ca3 100644 --- a/librpc/ndr/ndr_nbt.c +++ b/librpc/ndr/ndr_nbt.c @@ -76,7 +76,7 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr, return ndr_pull_error(ndr, NDR_ERR_STRING, "BAD NBT NAME component"); } - if (*offset + len + 2 > ndr->data_size) { + if (*offset + len + 1 > ndr->data_size) { return ndr_pull_error(ndr, NDR_ERR_STRING, "BAD NBT NAME component"); } diff --git a/librpc/wscript_build b/librpc/wscript_build index f0b461d..f35fd02 100644 --- a/librpc/wscript_build +++ b/librpc/wscript_build @@ -378,6 +378,11 @@ bld.SAMBA_SUBSYSTEM('RPC_NDR_AUDIOSRV', public_deps='NDR_AUDIOSRV dcerpc-binding' ) +bld.SAMBA_SUBSYSTEM('RPC_NDR_DNS', + source='gen_ndr/ndr_dns_c.c', + public_deps='dcerpc-binding NDR_DNS' + ) + bld.SAMBA_SUBSYSTEM('RPC_NDR_ECHO', source='gen_ndr/ndr_echo_c.c', public_deps='dcerpc-binding NDR_ECHO' @@ -583,7 +588,7 @@ bld.SAMBA_LIBRARY('dcerpc-samba', source=&
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 55e448f s4 provision/dns: Move DNS-related setup to sambadns module via eeb370f s4 provision/dns: Move secretsdb_setup_dns to the AD DNS specific setup from e308927 s3:selftest: improve logging in the registry upgrade test http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 55e448fe2d1ce63f1262bb02f8e0dd36e916ca32 Author: Kai Blin Date: Fri Oct 21 11:56:10 2011 +0200 s4 provision/dns: Move DNS-related setup to sambadns module Autobuild-User: Kai Blin Autobuild-Date: Fri Nov 4 09:15:54 CET 2011 on sn-devel-104 commit eeb370f77a2cdbafe0b87a2af2299a8c5cdfcf6f Author: Kai Blin Date: Fri Oct 21 11:04:07 2011 +0200 s4 provision/dns: Move secretsdb_setup_dns to the AD DNS specific setup --- Summary of changes: .../scripting/python/samba/provision/__init__.py | 216 +- .../scripting/python/samba/provision/sambadns.py | 250 +++- 2 files changed, 252 insertions(+), 214 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/scripting/python/samba/provision/__init__.py b/source4/scripting/python/samba/provision/__init__.py index a44bb8e..a8a5a57 100644 --- a/source4/scripting/python/samba/provision/__init__.py +++ b/source4/scripting/python/samba/provision/__init__.py @@ -74,7 +74,7 @@ from samba.provision.backend import ( LDBBackend, OpenLDAPBackend, ) -from samba.provision.sambadns import setup_ad_dns +from samba.provision.sambadns import setup_ad_dns, create_dns_update_list import samba.param import samba.registry @@ -922,29 +922,6 @@ def secretsdb_self_join(secretsdb, domain, secretsdb.add(msg) -def secretsdb_setup_dns(secretsdb, names, private_dir, realm, -dnsdomain, dns_keytab_path, dnspass): -"""Add DNS specific bits to a secrets database. - -:param secretsdb: Ldb Handle to the secrets database -:param machinepass: Machine password -""" -try: -os.unlink(os.path.join(private_dir, dns_keytab_path)) -except OSError: -pass - -setup_ldb(secretsdb, setup_path("secrets_dns.ldif"), { -"REALM": realm, -"DNSDOMAIN": dnsdomain, -"DNS_KEYTAB": dns_keytab_path, -"DNSPASS_B64": b64encode(dnspass), -"HOSTNAME": names.hostname, -"DNSNAME" : '%s.%s' % ( -names.netbiosname.lower(), names.dnsdomain.lower()) -}) - - def setup_secretsdb(paths, session_info, backend_credentials, lp): """Setup the secrets database. @@ -1616,40 +1593,15 @@ def provision_fill(samdb, secrets_ldb, logger, names, paths, # It might be that this attribute does not exist in this schema raise -secretsdb_setup_dns(secrets_ldb, names, -paths.private_dir, realm=names.realm, -dnsdomain=names.dnsdomain, -dns_keytab_path=paths.dns_keytab, dnspass=dnspass) - -setup_ad_dns(samdb, names, logger, hostip=hostip, hostip6=hostip6, - dns_backend=dns_backend, os_level=dom_for_fun_level) +setup_ad_dns(samdb, secrets_ldb, names, paths, lp, logger, + hostip=hostip, hostip6=hostip6, dns_backend=dns_backend, + dnspass=dnspass, os_level=dom_for_fun_level, + targetdir=targetdir, site=DEFAULTSITE) domainguid = samdb.searchone(basedn=samdb.get_default_basedn(), attribute="objectGUID") assert isinstance(domainguid, str) -create_dns_dir(logger, paths) - -# Only make a zone file on the first DC, it should be -# replicated with DNS replication -if dns_backend == "BIND9_FLATFILE": -create_zone_file(lp, logger, paths, targetdir, - dnsdomain=names.dnsdomain, hostip=hostip, hostip6=hostip6, - hostname=names.hostname, realm=names.realm, - domainguid=domainguid, ntdsguid=names.ntdsguid) - -create_named_conf(paths, realm=names.realm, - dnsdomain=names.dnsdomain, dns_backend=dns_backend) - -create_named_txt(paths.namedtxt, - realm=names.realm, dnsdomain=names.dnsdomain, - dnsname = "%s.%s" % (names.hostname, names.dnsdomain), - private_dir=paths.private_dir, - keytab_name=paths.dns_keytab) -logger.info("See %s for an example configuration include file for BIND", paths
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 8c07686 s4 provision: DNS backend should be set by caller via d58f266 s4 provision/dns: Clean up os level handling via 6382721 s4 provision/dns: Clean up backend handling via b42b812 s4 provision: Default to win2k3 domain function level via 41d4862 s4 provision: Reword opinionated dns backend help text, add NONE backend via 292554c s4 provision: Rename bind9 flatfile backend to BIND9_FLATFILE from 009b97d provision: fix the doc http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 8c076862ad0b1b14bb6addef323c5678368051af Author: Kai Blin Date: Sat Oct 15 13:54:45 2011 +0200 s4 provision: DNS backend should be set by caller Autobuild-User: Kai Blin Autobuild-Date: Mon Oct 17 09:51:12 CEST 2011 on sn-devel-104 commit d58f266d19750484b72ad0e18de3e83c88e81169 Author: Kai Blin Date: Sat Oct 15 13:52:57 2011 +0200 s4 provision/dns: Clean up os level handling commit 6382721ce0559bd60a9abd08b0a9353db9f7d731 Author: Kai Blin Date: Sat Oct 15 13:48:28 2011 +0200 s4 provision/dns: Clean up backend handling commit b42b81249c5f6006e743b186a3d58a3763aeabe8 Author: Kai Blin Date: Sat Oct 15 12:36:50 2011 +0200 s4 provision: Default to win2k3 domain function level commit 41d48626e24324c726793856c3c907c0dd89f3a1 Author: Kai Blin Date: Sat Oct 15 12:27:55 2011 +0200 s4 provision: Reword opinionated dns backend help text, add NONE backend commit 292554c396d0a848bb73423e08a5f30eba1d4907 Author: Kai Blin Date: Sat Oct 15 12:17:14 2011 +0200 s4 provision: Rename bind9 flatfile backend to BIND9_FLATFILE --- Summary of changes: source4/scripting/python/samba/join.py |6 ++- .../scripting/python/samba/provision/__init__.py |8 +--- .../scripting/python/samba/provision/sambadns.py | 41 source4/scripting/python/samba/upgrade.py |8 +++- source4/scripting/python/samba/upgradehelpers.py |3 +- source4/setup/provision| 16 ++-- 6 files changed, 52 insertions(+), 30 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/scripting/python/samba/join.py b/source4/scripting/python/samba/join.py index 731f0b5..6a8ac97 100644 --- a/source4/scripting/python/samba/join.py +++ b/source4/scripting/python/samba/join.py @@ -584,7 +584,8 @@ class dc_join(object): serverdn=ctx.server_dn, domain=ctx.domain_name, hostname=ctx.myname, domainsid=ctx.domsid, machinepass=ctx.acct_pass, serverrole="domain controller", -sitename=ctx.site, lp=ctx.lp, ntdsguid=ctx.ntds_guid) +sitename=ctx.site, lp=ctx.lp, ntdsguid=ctx.ntds_guid, +dns_backend="NONE") print "Provision OK for domain DN %s" % presult.domaindn ctx.local_samdb = presult.samdb ctx.lp = presult.lp @@ -622,7 +623,8 @@ class dc_join(object): domainguid=domguid, targetdir=ctx.targetdir, samdb_fill=FILL_SUBDOMAIN, machinepass=ctx.acct_pass, serverrole="domain controller", - lp=ctx.lp, hostip=ctx.names.hostip, hostip6=ctx.names.hostip6) + lp=ctx.lp, hostip=ctx.names.hostip, hostip6=ctx.names.hostip6, + dns_backend="BIND9_FLATFILE") print("Provision OK for domain %s" % ctx.names.dnsdomain) diff --git a/source4/scripting/python/samba/provision/__init__.py b/source4/scripting/python/samba/provision/__init__.py index a3633ab..5e7e374 100644 --- a/source4/scripting/python/samba/provision/__init__.py +++ b/source4/scripting/python/samba/provision/__init__.py @@ -1625,10 +1625,6 @@ def provision_fill(samdb, secrets_ldb, logger, names, paths, dnsdomain=names.dnsdomain, dns_keytab_path=paths.dns_keytab, dnspass=dnspass) -# Default DNS backend is BIND9 using txt files for zone information -if not dns_backend: -dns_backend = "BIND9" - setup_ad_dns(samdb, names, logger, hostip=hostip, hostip6=hostip6, dns_backend=dns_backend, os_level=dom_for_fun_level) @@ -1640,7 +1636,7 @@ def provision_fill(samdb, secrets_ldb, logger, names, paths, # Only make a zone file on the first DC, it should be # replicated with DNS replication -if dns_backend == "BIND9": +if dns_backend == "BIND9_FLATFILE": create_zone_file(lp, logger
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 002694c s3 waf: Use upper case uselib_store parameter, otherwise the following checks won't find it from 7fff4e7 s3:dbwrap: remove m_all marshall buffer from ctdb transaction. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 002694c38d6b4e9231c19e8f830697f02d814923 Author: Kai Blin Date: Wed Oct 12 08:17:02 2011 +0200 s3 waf: Use upper case uselib_store parameter, otherwise the following checks won't find it Autobuild-User: Kai Blin Autobuild-Date: Wed Oct 12 09:49:50 CEST 2011 on sn-devel-104 --- Summary of changes: source3/wscript |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 47ef847..82434a5 100644 --- a/source3/wscript +++ b/source3/wscript @@ -487,7 +487,7 @@ msg.msg_acctrightslen = sizeof(fd); # gssapi_krb5 and other libraries to its --libs output. That breaks the use # of an in-tree heimdal kerberos conf.check_cfg(path=conf.env.CUPS_CONFIG, args="--cflags --ldflags", - package="", uselib_store="cups") + package="", uselib_store="CUPS") conf.CHECK_HEADERS('cups/cups.h cups/language.h', lib='cups') conf.CHECK_FUNCS_IN('httpConnect httpConnectEncrypt', 'cups') if conf.CONFIG_SET('HAVE_CUPS_CUPS_H') and conf.CONFIG_SET('HAVE_CUPS_LANGUAGE_H'): @@ -554,7 +554,7 @@ msg.msg_acctrightslen = sizeof(fd); conf.find_program('krb5-config', var='KRB5_CONFIG') if conf.env.KRB5_CONFIG: conf.check_cfg(path="krb5-config", args="--cflags --libs", - package="gssapi", uselib_store="krb5") + package="gssapi", uselib_store="KRB5") conf.CHECK_HEADERS('krb5.h krb5/locate_plugin.h', lib='krb5') conf.CHECK_HEADERS('gssapi.h gssapi/gssapi_generic.h gssapi/gssapi.h gssapi/gssapi_ext.h gssapi/gssapi_krb5.h com_err.h', lib='krb5') -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 1dbcb61 dns: Move the dns_srv_record to the correct place in the idl file via f163bd1 dns: Add support for TXT record to idl file via d5dcb9e wscript: Also generate ctags for python files via 5c890ad s4 provision: Set server role default when called from command line to 'dc' from 95bb2c2 s3:registry: fix the test for a REG_SZ blob possibly being a zero terminated ucs2 string http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 1dbcb61c79a0c06fdcfa36bb9304fb0fb66d7ff8 Author: Kai Blin Date: Thu Sep 29 19:34:08 2011 -0700 dns: Move the dns_srv_record to the correct place in the idl file Autobuild-User: Kai Blin Autobuild-Date: Sun Oct 2 13:35:49 CEST 2011 on sn-devel-104 commit f163bd1dac691d396725ac27e4493f6d217a66ce Author: Kai Blin Date: Thu Sep 29 19:32:57 2011 -0700 dns: Add support for TXT record to idl file commit d5dcb9eef1aaf78ae24bca90235acc263bc04a26 Author: Kai Blin Date: Wed Sep 28 12:07:27 2011 -0700 wscript: Also generate ctags for python files commit 5c890ad17ff84bd6ed1dfb26df3cac439fcf37c3 Author: Kai Blin Date: Fri Sep 30 16:23:39 2011 -0700 s4 provision: Set server role default when called from command line to 'dc' --- Summary of changes: librpc/idl/dns.idl | 16 +++- source4/setup/provision |3 +++ wscript |2 +- 3 files changed, 15 insertions(+), 6 deletions(-) Changeset truncated at 500 lines: diff --git a/librpc/idl/dns.idl b/librpc/idl/dns.idl index 66390b8..08a1699 100644 --- a/librpc/idl/dns.idl +++ b/librpc/idl/dns.idl @@ -132,17 +132,22 @@ interface dns } dns_soa_record; typedef [public] struct { + uint16 preference; + dns_string exchange; + } dns_mx_record; + + typedef [public] struct { + [value(strlen(txt))] uint8 length; + [charset(DOS)] uint8 txt[length]; + } dns_txt_record; + + typedef [public] struct { uint16 priority; uint16 weight; uint16 port; dns_string target; } dns_srv_record; - typedef [public] struct { - uint16 preference; - dns_string exchange; - } dns_mx_record; - typedef [nodiscriminant,public,flag(NDR_NOALIGN)] union { [case(DNS_QTYPE_A)] ipv4address ipv4_record; [case(DNS_QTYPE_NS)]dns_string ns_record; @@ -150,6 +155,7 @@ interface dns [case(DNS_QTYPE_SOA)] dns_soa_record soa_record; [case(DNS_QTYPE_PTR)] dns_string ptr_record; [case(DNS_QTYPE_MX)]dns_mx_recordmx_record; + [case(DNS_QTYPE_TXT)] dns_txt_record txt_record; [case(DNS_QTYPE_)] ipv6address ipv6_record; [case(DNS_QTYPE_SRV)] dns_srv_record srv_record; [default]; diff --git a/source4/setup/provision b/source4/setup/provision index 315de78..d05af51 100755 --- a/source4/setup/provision +++ b/source4/setup/provision @@ -198,6 +198,9 @@ elif opts.server_role == "member": else: server_role = opts.server_role +if server_role is None: +server_role = "domain controller" + if opts.function_level is None: dom_for_fun_level = None elif opts.function_level == "2000": diff --git a/wscript b/wscript index 8454146..1b50baf 100755 --- a/wscript +++ b/wscript @@ -146,7 +146,7 @@ def ctags(ctx): "build 'tags' file using ctags" import Utils source_root = os.path.dirname(Utils.g_module.root_path) -cmd = 'ctags $(find %s -name "*.[ch]" | grep -v "*_proto\.h" | egrep -v \.inst\.)' % source_root +cmd = 'ctags --python-kinds=-i $(find %s -name "*.[ch]" | grep -v "*_proto\.h" | egrep -v \.inst\.) $(find %s -name "*.py")' % (source_root, source_root) print("Running: %s" % cmd) os.system(cmd) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 1210b8a dns: Do as BIND and MS DNS and drop quries with qdcount != 1 via f98ebcf dns: The QCLASS is called IN, not IP via da0cae0 s3 net: Fix a discard const warning via df88e66 errormap: Add unix_to_werror() function from e8ed54d s3:libsmb: remove unused TALLOC_FREE(subreq) calls in http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 1210b8abe73f39f85f363cbbfa2a990e2ccd4517 Author: Kai Blin Date: Mon Sep 26 22:31:46 2011 -0700 dns: Do as BIND and MS DNS and drop quries with qdcount != 1 Autobuild-User: Kai Blin Autobuild-Date: Wed Sep 28 03:37:22 CEST 2011 on sn-devel-104 commit f98ebcf43f9b77266ef900a12b019f62d107096a Author: Kai Blin Date: Mon Sep 26 23:37:06 2011 -0700 dns: The QCLASS is called IN, not IP commit da0cae010a4a4050bb1d740a3df68776cc3c7b0e Author: Kai Blin Date: Sun Sep 25 13:24:50 2011 -0700 s3 net: Fix a discard const warning commit df88e66250375fec2d0991bf379f4fe6f2550a7c Author: Kai Blin Date: Wed Jan 26 22:17:43 2011 +0100 errormap: Add unix_to_werror() function While this function technically is closest to the map_nt_status_from_unix() function, I think it is better to keep the new function in line with our usual fooerror_to_barerror() naming scheme. Signed-off-by: Kai Blin --- Summary of changes: libcli/util/error.h|5 + libcli/util/errormap.c |5 + librpc/idl/dns.idl |2 +- source3/utils/net_dns.c|2 +- source4/dns_server/dns_query.c | 28 +--- 5 files changed, 29 insertions(+), 13 deletions(-) Changeset truncated at 500 lines: diff --git a/libcli/util/error.h b/libcli/util/error.h index 5c4dc10..0972601 100644 --- a/libcli/util/error.h +++ b/libcli/util/error.h @@ -45,4 +45,9 @@ NTSTATUS map_nt_error_from_unix_common(int unix_error); NTSTATUS nt_status_squash(NTSTATUS nt_status); +/* +convert a Unix error to a WERROR + */ +WERROR unix_to_werror(int unix_error); + #endif /* _SAMBA_ERROR_H */ diff --git a/libcli/util/errormap.c b/libcli/util/errormap.c index f96d83f..714e62c 100644 --- a/libcli/util/errormap.c +++ b/libcli/util/errormap.c @@ -1238,3 +1238,8 @@ WERROR ntstatus_to_werror(NTSTATUS error) return W_ERROR(NT_STATUS_V(error) & 0x); } +/* Convert a Unix error code to a WERROR. */ +WERROR unix_to_werror(int unix_error) +{ + return ntstatus_to_werror(map_nt_error_from_unix_common(unix_error)); +} diff --git a/librpc/idl/dns.idl b/librpc/idl/dns.idl index 90ac47a..66390b8 100644 --- a/librpc/idl/dns.idl +++ b/librpc/idl/dns.idl @@ -60,7 +60,7 @@ interface dns } dns_rcode; typedef [public,enum16bit] enum { - DNS_QCLASS_IP = 0x0001, + DNS_QCLASS_IN = 0x0001, DNS_QCLASS_NONE = 0x00FE, DNS_QCLASS_ANY = 0x00FF } dns_qclass; diff --git a/source3/utils/net_dns.c b/source3/utils/net_dns.c index f146f29..559c14d 100644 --- a/source3/utils/net_dns.c +++ b/source3/utils/net_dns.c @@ -166,7 +166,7 @@ int get_my_ip_address( struct sockaddr_storage **pp_ss ) continue; /* Don't register loopback addresses */ - if (is_loopback_addr((struct sockaddr *)nic_sa_storage)) { + if (is_loopback_addr((const struct sockaddr *)nic_sa_storage)) { continue; } diff --git a/source4/dns_server/dns_query.c b/source4/dns_server/dns_query.c index f730a70..2153ad9 100644 --- a/source4/dns_server/dns_query.c +++ b/source4/dns_server/dns_query.c @@ -86,7 +86,7 @@ static WERROR handle_question(struct dns_server *dns, ZERO_STRUCT(ans[ai]); ans[ai].name = talloc_strdup(ans, question->name); ans[ai].rr_type = DNS_QTYPE_CNAME; - ans[ai].rr_class = DNS_QCLASS_IP; + ans[ai].rr_class = DNS_QCLASS_IN; ans[ai].ttl = recs[ri].dwTtlSeconds; ans[ai].length = UINT16_MAX; ans[ai].rdata.cname_record = talloc_strdup(ans, recs[ri].data.cname); @@ -104,7 +104,7 @@ static WERROR handle_question(struct dns_server *dns, ZERO_STRUCT(ans[ai]); ans[ai].name = talloc_strdup(ans, question->name); ans[ai].rr_type = DNS_QTYPE_A; - ans[ai].rr_class = DNS_QCLASS_IP; + ans[ai].rr_class = DNS_QCLASS_IN; ans[ai].ttl = recs[r
[SCM] Samba Website Repository - branch master updated
The branch, master has been updated via f3d7d2b Remove outdated information about mirroring via 89d6998 Fix samba-cvs mailing list description from e52a1f9 Remove table wrapper; tested with firefox and IE http://gitweb.samba.org/?p=samba-web.git;a=shortlog;h=master - Log - commit f3d7d2bdb16bbdf6c66e14436bad0c60c5dfc0ef Author: Kai Blin Date: Sun Sep 25 22:15:16 2011 -0700 Remove outdated information about mirroring Signed-off-by: Kai Blin commit 89d69985f398ed25dd171429e666f3e8c2accad8 Author: Kai Blin Date: Sun Sep 25 22:14:49 2011 -0700 Fix samba-cvs mailing list description Signed-off-by: Kai Blin --- Summary of changes: archives.html |2 +- mirroring.html | 188 2 files changed, 1 insertions(+), 189 deletions(-) delete mode 100755 mirroring.html Changeset truncated at 500 lines: diff --git a/archives.html b/archives.html index e0e1498..2f4cfc1 100755 --- a/archives.html +++ b/archives.html @@ -37,7 +37,7 @@ http://lists.samba.org/pipermail/samba-cvs/";>samba-cvs - Samba CVS and Subversion commit messages + Samba CVS, Subversion and Git commit messages http://lists.samba.org/pipermail/samba-docs/";>samba-docs diff --git a/mirroring.html b/mirroring.html deleted file mode 100755 index 8bb505a..000 --- a/mirroring.html +++ /dev/null @@ -1,188 +0,0 @@ - - Mirroring Samba - - -Mirroring Samba - -Quite a few sites like to mirror the Samba ftp site, and sometimes the -web site. The problem with these mirrors is that they can cost us an -enormous amount in network charges. To try to minimise the costs, -please consider the following. - -Is It Needed? - -If this mirror is for your personal use, then please -reconsider. Otherwise, check to see if there is -another mirror site within reasonable proximity to you already. -If there is, then think about whether your mirror is really needed. - -Ask First - -If you decide to go ahead and setup a mirror, then please contact -us so we can add you to the list of available mirrors. Write to -mailto:webmas...@samba.org";>webmas...@samba.org. - -Not Too Often - -Please don't be tempted to run your mirror script on an hourly -basis. Once a day really is good enough for Samba. - -Join the mirr...@samba.org List - -If you want to mirror this site, then please join the -mirr...@samba.org mailing list so you can be notified of -changes in the site that require your attention. The list has very low -traffic so it should not be a burden. See -http://lists.samba.org/pipermail/mirrors/";> -http://lists.samba.org/pipermail/mirrors/ for information on how to join the list. - -You may also use this list to ask questions about mirroring problems -with this site. - -Use Anonymous rsync - -Please do NOT use ftp mirror scripts or web robots to mirror our -site. Some of these mirroring systems are very inefficient. Not -only do they take a long time to run, but they also use a lot more -bandwidth than is necessary. Web mirror scripts are particularly bad. - -If you do attempt to use a web robot then our automatic web robot -detector will probably catch you and ban your entire site. - -You can use anonymous rsync to obtain a copy of the [sambaftp] -(minus the Binary_Packages download area) and [sambawww] repository. -Please note that official mirror can make use of the [sambaftp-mirror] -repository which includes the Binary_Packages/ directory. However, in -order to do so, you must first obtain the current username and password -for the share. To do this, please send email to mailto:webmas...@samba.org";>webmas...@samba.org. - - -You can read more about rsync at http://rsync.samba.org/";>http://rsync.samba.org/, -but basically what you want to do is ftp://samba.org/pub/rsync/";>download rsync, compile -it for your system then run something like this to do a mirror run: - - -rsync -az --delete --force mirror.samba.org::sambaftp/ ~ftp/pub/samba - - -This will also give you a much better quality mirror than other -mirroring systems. The timestamps will be right to the second, -symbolic links will be preserved, and all the permissions will be -right. - -Mirroring Web Pages - -If you want to mirror the Samba web pages, then it is especially -important that you do not use a web robot. We have had endless -problems with robots using enormous amounts of bandwidth by following -infinite loops in the web pages or downloading stuff that it just isn't -useful to have on a mirror site. - -Instead, please join the mirrors mailing list mentioned above and ask -on that list. Then, if you go ahead, please use rsync like this: - - -rsync -az --delete --exclude=ftp mirror.samba.org::sambawww/ /wwwmirrors/samba/ - - -To complete the web mirror you will
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via b567694 addns: Remove unused empty header file via b02bbf2 net: Don't register link local addresses with DNS via 7466612 addns: Allow creating records during updates via 8eb80a9 libcli/smb: Get rid of set but unused variable from 649bfc4 s4 winbind: Don't drop workgroup name for getpw* http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit b567694bb0ee6aa233f639efd6ac495c44e2e172 Author: Kai Blin Date: Sat Sep 24 22:40:43 2011 -0700 addns: Remove unused empty header file Autobuild-User: Kai Blin Autobuild-Date: Sun Sep 25 09:15:09 CEST 2011 on sn-devel-104 commit b02bbf237cfd36cd736cefc78f1e3ba3278dc7bf Author: Kai Blin Date: Sat Sep 24 18:18:14 2011 -0700 net: Don't register link local addresses with DNS commit 7466612392272e70c60114fc035b62b16f6194aa Author: Kai Blin Date: Sat Sep 24 18:17:11 2011 -0700 addns: Allow creating records during updates commit 8eb80a9d832e08bb356507a870522b0b7180a10a Author: Kai Blin Date: Sat Sep 24 18:28:52 2011 -0700 libcli/smb: Get rid of set but unused variable --- Summary of changes: lib/addns/addns.h | 30 lib/addns/dns.h |4 +++ lib/addns/dnsrecord.c | 60 ++--- lib/util/util_net.c | 23 +++ lib/util/util_net.h |1 + libcli/smb/smb2_create_blob.c |4 ++- source3/Makefile.in |1 - source3/utils/net_dns.c |5 +++ 8 files changed, 92 insertions(+), 36 deletions(-) delete mode 100644 lib/addns/addns.h Changeset truncated at 500 lines: diff --git a/lib/addns/addns.h b/lib/addns/addns.h deleted file mode 100644 index 6ef9329..000 --- a/lib/addns/addns.h +++ /dev/null @@ -1,30 +0,0 @@ -/* - Public Interface file for Linux DNS client library implementation - - Copyright (C) 2006 Krishna Ganugapati - Copyright (C) 2006 Gerald Carter - - ** NOTE! The following LGPL license applies to the libaddns - ** library. This does NOT imply that all of Samba is released - ** under the LGPL - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, see <http://www.gnu.org/licenses/>. -*/ - -#ifndef _ADDNS_H -#define _ADDNS_H - - -#endif /* _ADDNS_H */ - diff --git a/lib/addns/dns.h b/lib/addns/dns.h index 6ccdbb6..d98a27e 100644 --- a/lib/addns/dns.h +++ b/lib/addns/dns.h @@ -205,6 +205,7 @@ #define QTYPE_MD3 #define QTYPE_CNAME5 #define QTYPE_SOA 6 +#define QTYPE_ 28 #define QTYPE_ANY 255 #defineQTYPE_TKEY 249 #define QTYPE_TSIG 250 @@ -408,6 +409,9 @@ DNS_ERROR dns_create_name_not_in_use_record(TALLOC_CTX *mem_ctx, DNS_ERROR dns_create_a_record(TALLOC_CTX *mem_ctx, const char *host, uint32 ttl, const struct sockaddr_storage *pss, struct dns_rrec **prec); +DNS_ERROR dns_create__record(TALLOC_CTX *mem_ctx, const char *host, +uint32 ttl, const struct sockaddr_storage *pss, +struct dns_rrec **prec); DNS_ERROR dns_unmarshall_tkey_record(TALLOC_CTX *mem_ctx, struct dns_rrec *rec, struct dns_tkey_record **ptkey); DNS_ERROR dns_create_tsig_record(TALLOC_CTX *mem_ctx, const char *keyname, diff --git a/lib/addns/dnsrecord.c b/lib/addns/dnsrecord.c index 2240d08..045fd46 100644 --- a/lib/addns/dnsrecord.c +++ b/lib/addns/dnsrecord.c @@ -127,8 +127,7 @@ DNS_ERROR dns_create_a_record(TALLOC_CTX *mem_ctx, const char *host, struct in_addr ip; if (pss->ss_family != AF_INET) { - /* Silently ignore this. */ - return ERROR_DNS_SUCCESS; + return ERROR_DNS_INVALID_PARAMETER; } ip = ((const struct sockaddr_in *)pss)->sin_addr; @@ -147,13 +146,54 @@ DNS_ERROR dns_create_a_record(TALLOC_CTX *mem_ctx, const char *host, return err; } +DNS_ERROR dns_create__record(TALLOC_CTX *mem_ctx, const char *host, +uint32 ttl, const struct sockaddr_storage *pss, +struct dns_rrec *
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 649bfc4 s4 winbind: Don't drop workgroup name for getpw* from ca8c25a Fix bug 8480 - acl_xattr can free an invalid pointer if no blob is loaded. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 649bfc474dc85c921c2739008eb2b645fd7e2baf Author: Kai Blin Date: Sat Sep 24 10:45:59 2011 -0700 s4 winbind: Don't drop workgroup name for getpw* Autobuild-User: Kai Blin Autobuild-Date: Sat Sep 24 22:49:50 CEST 2011 on sn-devel-104 --- Summary of changes: source4/winbind/wb_cmd_getpwnam.c |9 - source4/winbind/wb_cmd_getpwuid.c |9 - 2 files changed, 16 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/winbind/wb_cmd_getpwnam.c b/source4/winbind/wb_cmd_getpwnam.c index ac72359..0ba4cb6 100644 --- a/source4/winbind/wb_cmd_getpwnam.c +++ b/source4/winbind/wb_cmd_getpwnam.c @@ -108,6 +108,7 @@ static void cmd_getpwnam_recv_user_info(struct composite_context *ctx) ctx->async.private_data, struct cmd_getpwnam_state); struct libnet_UserInfo *user_info; struct winbindd_pw *pw; + char *username_with_domain; DEBUG(5, ("cmd_getpwnam_recv_user_info called\n")); @@ -120,7 +121,13 @@ static void cmd_getpwnam_recv_user_info(struct composite_context *ctx) state->ctx->status = libnet_UserInfo_recv(ctx, state, user_info); if(!composite_is_ok(state->ctx)) return; - WBSRV_SAMBA3_SET_STRING(pw->pw_name, user_info->out.account_name); + username_with_domain = talloc_asprintf(pw, "%s%s%s", + state->workgroup_name, + lpcfg_winbind_separator(state->service->task->lp_ctx), + user_info->out.account_name); + if(composite_nomem(username_with_domain, state->ctx)) return; + + WBSRV_SAMBA3_SET_STRING(pw->pw_name, username_with_domain); WBSRV_SAMBA3_SET_STRING(pw->pw_passwd, "*"); WBSRV_SAMBA3_SET_STRING(pw->pw_gecos, user_info->out.full_name); WBSRV_SAMBA3_SET_STRING(pw->pw_dir, diff --git a/source4/winbind/wb_cmd_getpwuid.c b/source4/winbind/wb_cmd_getpwuid.c index f6f3cb2..73bbb59 100644 --- a/source4/winbind/wb_cmd_getpwuid.c +++ b/source4/winbind/wb_cmd_getpwuid.c @@ -129,6 +129,7 @@ static void cmd_getpwuid_recv_user_info(struct composite_context *ctx) struct cmd_getpwuid_state); struct libnet_UserInfo *user_info; struct winbindd_pw *pw; + char *username_with_domain; DEBUG(5, ("cmd_getpwuid_recv_user_info called\n")); @@ -141,7 +142,13 @@ static void cmd_getpwuid_recv_user_info(struct composite_context *ctx) state->ctx->status = libnet_UserInfo_recv(ctx, state, user_info); if (!composite_is_ok(state->ctx)) return; - WBSRV_SAMBA3_SET_STRING(pw->pw_name, user_info->out.account_name); + username_with_domain = talloc_asprintf(pw, "%s%s%s", + state->workgroup, + lpcfg_winbind_separator(state->service->task->lp_ctx), + user_info->out.account_name); + if(composite_nomem(username_with_domain, state->ctx)) return; + + WBSRV_SAMBA3_SET_STRING(pw->pw_name, username_with_domain); WBSRV_SAMBA3_SET_STRING(pw->pw_passwd, "*"); WBSRV_SAMBA3_SET_STRING(pw->pw_gecos, user_info->out.full_name); WBSRV_SAMBA3_SET_STRING(pw->pw_dir, -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 749d022 s4 provision: Add some of the AD-specific DNS records to the directory via a8d3bdb s4 provision: split up DNS provisioning into generic and samba-specific ldifs from 0b8184d s4:torture/smb2: s/smb2cli_unlock/test_smb2_unlock http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 749d022a0c68dd7d9f62b034e37fbe509dba2c46 Author: Kai Blin Date: Mon Jun 27 11:25:39 2011 +0200 s4 provision: Add some of the AD-specific DNS records to the directory Signed-off-by: Kai Blin Autobuild-User: Kai Blin Autobuild-Date: Thu Jul 7 02:29:53 CEST 2011 on sn-devel-104 commit a8d3bdb48da71dd65385e4355e46a595ef32dbe0 Author: Kai Blin Date: Sun Jun 26 00:36:25 2011 +0200 s4 provision: split up DNS provisioning into generic and samba-specific ldifs Signed-off-by: Kai Blin --- Summary of changes: .../scripting/python/samba/provision/__init__.py |8 +- .../scripting/python/samba/provision/sambadns.py | 231 source4/setup/provision_dns_add.ldif | 23 +-- source4/setup/provision_dns_add_samba.ldif | 17 ++ 4 files changed, 258 insertions(+), 21 deletions(-) create mode 100644 source4/scripting/python/samba/provision/sambadns.py create mode 100644 source4/setup/provision_dns_add_samba.ldif Changeset truncated at 500 lines: diff --git a/source4/scripting/python/samba/provision/__init__.py b/source4/scripting/python/samba/provision/__init__.py index 5aabd36..f2b8c04 100644 --- a/source4/scripting/python/samba/provision/__init__.py +++ b/source4/scripting/python/samba/provision/__init__.py @@ -74,6 +74,8 @@ from samba.provision.backend import ( LDBBackend, OpenLDAPBackend, ) +from samba.provision.sambadns import setup_ad_dns + import samba.param import samba.registry from samba.schema import Schema @@ -1101,9 +1103,9 @@ def setup_self_join(samdb, names, machinepass, dnspass, "RIDALLOCATIONEND": str(next_rid + 100 + 499), }) -# This is partially Samba4 specific and should be replaced by the correct +# This is Samba4 specific and should be replaced by the correct # DNS AD-style setup -setup_add_ldif(samdb, setup_path("provision_dns_add.ldif"), { +setup_add_ldif(samdb, setup_path("provision_dns_add_samba.ldif"), { "DNSDOMAIN": names.dnsdomain, "DOMAINDN": names.domaindn, "DNSPASS_B64": b64encode(dnspass.encode('utf-16-le')), @@ -1761,6 +1763,8 @@ def provision(logger, session_info, credentials, smbconf=None, dnsdomain=names.dnsdomain, dns_keytab_path=paths.dns_keytab, dnspass=dnspass) +setup_ad_dns(samdb, names=names, hostip=hostip, hostip6=hostip6) + domainguid = samdb.searchone(basedn=domaindn, attribute="objectGUID") assert isinstance(domainguid, str) diff --git a/source4/scripting/python/samba/provision/sambadns.py b/source4/scripting/python/samba/provision/sambadns.py new file mode 100644 index 000..6b8561e --- /dev/null +++ b/source4/scripting/python/samba/provision/sambadns.py @@ -0,0 +1,231 @@ +# Unix SMB/CIFS implementation. +# backend code for provisioning DNS for a Samba4 server +# +# Copyright (C) Kai Blin 2011 +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. +# + +"""DNS-related provisioning""" + +import os +import ldb +import samba +from samba.ndr import ndr_pack +from samba import read_and_sub_file +from samba.dcerpc import dnsp + +class ARecord(dnsp.DnssrvRpcRecord): +def __init__(self, ip_addr, serial=1, ttl=3600): +super(ARecord, self).__init__() +self.wType = dnsp.DNS_TYPE_A +self.dwSerial = serial +self.dwTtlSeconds = ttl +self.data = ip_addr + +class Record(dnsp.DnssrvRpcRecord): +def __init__(self, ip6_addr, serial=1, ttl=3600): +super(Record, self).__init__() +self.wType = dnsp.DNS_TYPE_ +self.dwSerial = serial +self.dwTtlSeconds = ttl +
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 05d00ed nsswitch: Fix build check logic from ecc030e selftest: Polish selftest-vars.sh a little so it can be used again http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 05d00ed479e99dea28aead113a3de33546b44526 Author: Kai Blin Date: Sun May 8 21:50:34 2011 +0200 nsswitch: Fix build check logic Only build pam_winbind.so if we want pam modules _and_ have the libs Autobuild-User: Kai Blin Autobuild-Date: Sun May 8 23:56:33 CEST 2011 on sn-devel-104 --- Summary of changes: nsswitch/wscript_build |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/nsswitch/wscript_build b/nsswitch/wscript_build index 83b10a7..47f6fbc 100644 --- a/nsswitch/wscript_build +++ b/nsswitch/wscript_build @@ -21,7 +21,7 @@ bld.SAMBA_LIBRARY('nss_winbind', vnum='2') -if bld.CONFIG_SET('WITH_PAM_MODULES') or bld.CONFIG_SET('HAVE_PAM_START'): +if bld.CONFIG_SET('WITH_PAM_MODULES') and bld.CONFIG_SET('HAVE_PAM_START'): bld.SAMBA_LIBRARY('pamwinbind', source='pam_winbind.c', deps='intl talloc wbclient winbind-client LIBINIPARSER pam', -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 4b78956 s4 samba-tool: Implement "testparm" command from 2d22bbf s3-selftest Look only under source3 for smb.conf files http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 4b7895698557149504773f4e74e8d4eb81c3b093 Author: Kai Blin Date: Wed Mar 23 23:06:18 2011 +0100 s4 samba-tool: Implement "testparm" command This is a port of the existing "testparm" python script to a samba-tool command. Autobuild-User: Kai Blin Autobuild-Date: Tue Apr 5 07:49:13 CEST 2011 on sn-devel-104 --- Summary of changes: source4/scripting/python/samba/netcmd/__init__.py |2 + source4/scripting/python/samba/netcmd/testparm.py | 206 + 2 files changed, 208 insertions(+), 0 deletions(-) create mode 100755 source4/scripting/python/samba/netcmd/testparm.py Changeset truncated at 500 lines: diff --git a/source4/scripting/python/samba/netcmd/__init__.py b/source4/scripting/python/samba/netcmd/__init__.py index aa74f65..cf514d5 100644 --- a/source4/scripting/python/samba/netcmd/__init__.py +++ b/source4/scripting/python/samba/netcmd/__init__.py @@ -213,3 +213,5 @@ from samba.netcmd.gpo import cmd_gpo commands["gpo2"] = cmd_gpo() from samba.netcmd.ldapcmp import cmd_ldapcmp commands["ldapcmp"] = cmd_ldapcmp() +from samba.netcmd.testparm import cmd_testparm +commands["testparm"] = cmd_testparm() diff --git a/source4/scripting/python/samba/netcmd/testparm.py b/source4/scripting/python/samba/netcmd/testparm.py new file mode 100755 index 000..ec44858 --- /dev/null +++ b/source4/scripting/python/samba/netcmd/testparm.py @@ -0,0 +1,206 @@ +#!/usr/bin/env python +# vim: expandtab ft=python +# +# Unix SMB/CIFS implementation. +# Test validity of smb.conf +# Copyright (C) Karl Auer 1993, 1994-1998 +# +# Extensively modified by Andrew Tridgell, 1995 +# Converted to popt by Jelmer Vernooij (jel...@nl.linux.org), 2002 +# Updated for Samba4 by Andrew Bartlett 2006 +# Converted to Python by Jelmer Vernooij 2010 +# +# This program is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3 of the License, or +# (at your option) any later version. +# +# This program is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with this program. If not, see <http://www.gnu.org/licenses/>. +# +# Testbed for loadparm.c/params.c +# +# This module simply loads a specified configuration file and +# if successful, dumps it's contents to stdout. Note that the +# operation is performed with DEBUGLEVEL at 3. +# +# Useful for a quick 'syntax check' of a configuration file. +# + +import os +import sys +import logging + +import samba +import samba.getopt as options +from samba.netcmd import Command, CommandError, Option + +class cmd_testparm(Command): +"""Syntax check the configuration file""" + +synopsis = "" + +takes_optiongroups = { +"sambaopts": options.SambaOptions, +"versionopts": options.VersionOptions +} + +takes_options = [ +Option("--section-name", type=str, + help="Limit testparm to a named section"), +Option("--parameter-name", type=str, + help="Limit testparm to a named parameter"), +Option("--client-name", type=str, + help="Client DNS name for 'hosts allow' checking " +"(should match reverse lookup)"), +Option("--client-ip", type=str, + help="Client IP address for 'hosts allow' checking"), +Option("--suppress-prompt", action="store_true", default=False, + help="Suppress prompt for enter"), +Option("-v", "--verbose", action="store_true", + default=False, help="Show default options too"), +# We need support for smb.conf macros before this will work again +Option("--server", type=str, help="Set %%L macro to servername"), +# These are harder to do with the new code structure +Option("--show-all-parameters", action="store_true", default=False, + help="Show the parameters, type, possible val
[SCM] Samba Website Repository - branch master updated
The branch, master has been updated via 02f252a Add Samba-S-only logo to have an almost square logo < 65x65 pixels for the GSoC website from b5245a3 Announce Samba 3.5.8. http://gitweb.samba.org/?p=samba-web.git;a=shortlog;h=master - Log - commit 02f252aff7e9a7e40b98de13e8f420a48c4b36cc Author: Kai Blin Date: Wed Mar 30 22:37:26 2011 +0200 Add Samba-S-only logo to have an almost square logo < 65x65 pixels for the GSoC website Signed-off-by: Kai Blin --- Summary of changes: style/2010/samba_2010_logo_transparent_s_only.png | Bin 0 -> 7993 bytes .../samba_2010_logo_transparent_s_only_64x52.png | Bin 0 -> 1048 bytes 2 files changed, 0 insertions(+), 0 deletions(-) create mode 100644 style/2010/samba_2010_logo_transparent_s_only.png create mode 100644 style/2010/samba_2010_logo_transparent_s_only_64x52.png Changeset truncated at 500 lines: diff --git a/style/2010/samba_2010_logo_transparent_s_only.png b/style/2010/samba_2010_logo_transparent_s_only.png new file mode 100644 index 000..988d7b9 Binary files /dev/null and b/style/2010/samba_2010_logo_transparent_s_only.png differ diff --git a/style/2010/samba_2010_logo_transparent_s_only_64x52.png b/style/2010/samba_2010_logo_transparent_s_only_64x52.png new file mode 100644 index 000..b39556d Binary files /dev/null and b/style/2010/samba_2010_logo_transparent_s_only_64x52.png differ -- Samba Website Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 278c6f8 errormap: Add unix_to_werror() function from 67e578a Allow "security = share" with SMB2. We already handle this in smb2/smb2_server.c http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 278c6f8fc538ad8ee069f0682229fad34abb3513 Author: Kai Blin Date: Wed Jan 26 22:17:43 2011 +0100 errormap: Add unix_to_werror() function While this function technically is closest to the map_nt_status_from_unix() function, I think it is better to keep the new function in line with our usual fooerror_to_barerror() naming scheme. Signed-off-by: Kai Blin Autobuild-User: Kai Blin Autobuild-Date: Wed Jan 26 23:07:24 CET 2011 on sn-devel-104 --- Summary of changes: libcli/util/error.h|5 + source3/lib/errmap_unix.c |6 ++ source4/libcli/util/errormap.c |6 ++ 3 files changed, 17 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/libcli/util/error.h b/libcli/util/error.h index 5a7cc1b..77a2f5a 100644 --- a/libcli/util/error.h +++ b/libcli/util/error.h @@ -46,4 +46,9 @@ WERROR ntstatus_to_werror(NTSTATUS error); */ NTSTATUS map_nt_error_from_unix(int unix_error); +/* +convert a Unix error code to a WERROR +*/ +WERROR unix_to_werror(int unix_error); + #endif /* _SAMBA_ERROR_H */ diff --git a/source3/lib/errmap_unix.c b/source3/lib/errmap_unix.c index 91a620e..b4a98f9 100644 --- a/source3/lib/errmap_unix.c +++ b/source3/lib/errmap_unix.c @@ -141,6 +141,12 @@ NTSTATUS map_nt_error_from_unix(int unix_error) return NT_STATUS_ACCESS_DENIED; } +/* Convert a Unix error code to a WERROR. */ +WERROR unix_to_werror(int unix_error) +{ + return ntstatus_to_werror(map_nt_error_from_unix(unix_error)); +} + /* Return a UNIX errno from a NT status code */ static const struct { NTSTATUS status; diff --git a/source4/libcli/util/errormap.c b/source4/libcli/util/errormap.c index 8fcf60b..29f2331 100644 --- a/source4/libcli/util/errormap.c +++ b/source4/libcli/util/errormap.c @@ -1383,6 +1383,12 @@ NTSTATUS map_nt_error_from_unix(int unix_error) return NT_STATUS_UNSUCCESSFUL; } +/* Convert a Unix error code to WERROR */ +WERROR unix_to_werror(int unix_error) +{ + return ntstatus_to_werror(map_nt_error_from_unix(unix_error)); +} + NTSTATUS ndr_map_error2ntstatus(enum ndr_err_code ndr_err) { switch (ndr_err) { -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 1f2518d s4 libcli: Add libcli_echo lib and torture test via 9df1b40 s4: Implement UDP echo server example from 5fcbb16 s4:pyrpc_util: s/typename/type_name to avoid c++ warnings http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 1f2518df5a4f21bb7a2bd2abc601517d7988c507 Author: Kai Blin Date: Mon Nov 15 23:01:57 2010 +0100 s4 libcli: Add libcli_echo lib and torture test Autobuild-User: Kai Blin Autobuild-Date: Thu Dec 9 23:57:03 CET 2010 on sn-devel-104 commit 9df1b408c1b2432728ecc3d114854535f168b47a Author: Kai Blin Date: Sun Nov 7 10:05:56 2010 +0100 s4: Implement UDP echo server example This is a simple UDP-based echo server. It is mainly intended as an example on how to do server service tasks in s4. --- Summary of changes: libcli/echo/echo.c| 204 ++ libcli/echo/libecho.h | 56 ++ libcli/echo/tests/echo.c | 93 ++ libcli/echo/tests/wscript_build |8 + libcli/echo/wscript_build |7 + selftest/target/Samba4.pm |1 + source4/echo_server/echo_server.c | 345 + source4/echo_server/echo_server.h | 33 source4/echo_server/wscript_build |9 + source4/selftest/tests.py |2 + source4/wscript_build |2 + 11 files changed, 760 insertions(+), 0 deletions(-) create mode 100644 libcli/echo/echo.c create mode 100644 libcli/echo/libecho.h create mode 100644 libcli/echo/tests/echo.c create mode 100644 libcli/echo/tests/wscript_build create mode 100644 libcli/echo/wscript_build create mode 100644 source4/echo_server/echo_server.c create mode 100644 source4/echo_server/echo_server.h create mode 100644 source4/echo_server/wscript_build Changeset truncated at 500 lines: diff --git a/libcli/echo/echo.c b/libcli/echo/echo.c new file mode 100644 index 000..46d1e28 --- /dev/null +++ b/libcli/echo/echo.c @@ -0,0 +1,204 @@ +/* + Unix SMB/CIFS implementation. + + Echo example async client library + + Copyright (C) 2010 Kai Blin + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program. If not, see <http://www.gnu.org/licenses/>. +*/ + +#include "replace.h" +#include "system/network.h" +#include +#include "lib/tsocket/tsocket.h" +#include "libcli/util/ntstatus.h" +#include "libcli/echo/libecho.h" +#include "lib/util/tevent_ntstatus.h" +#include "libcli/util/error.h" + +/* + * Following the Samba convention for async functions, set up a state struct + * for this set of calls. The state is always called function_name_state for + * the set of async functions related to function_name_send(). + */ +struct echo_request_state { + struct tevent_context *ev; + ssize_t orig_len; + struct tdgram_context *dgram; + char *message; +}; + +/* Declare callback functions used below. */ +static void echo_request_get_reply(struct tevent_req *subreq); +static void echo_request_done(struct tevent_req *subreq); + +struct tevent_req *echo_request_send(TALLOC_CTX *mem_ctx, +struct tevent_context *ev, +const char *server_addr_string, +const char *message) +{ + struct tevent_req *req, *subreq; + struct echo_request_state *state; + struct tsocket_address *local_addr, *server_addr; + struct tdgram_context *dgram; + int ret; + + /* +* Creating the initial tevent_req is the only place where returning +* NULL is allowed. Everything after that should return a more +* meaningful error using tevent_req_post(). +*/ + req = tevent_req_create(mem_ctx, &state, struct echo_request_state); + if (req == NULL) { + return NULL; + } + + /* +* We need to dispatch new async functions in the callbacks, hold +* on to the event context. +*/ + state->ev = ev; + + /* libecho uses connected UDP sockets, take care of this here */ + ret = tsocket_address_inet_from_strings(state, "ip"
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 6e27ff3 s3 docs: Reword posix locking text to answer a common question from bf9c3ee s3: Attempt to please autobuild http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 6e27ff36b6b112d3b9eb6e4955b717190ab9fb0d Author: Kai Blin Date: Tue Nov 30 15:58:05 2010 +0100 s3 docs: Reword posix locking text to answer a common question vl recently pointed me to a valid reason to use posix locking = no. Fix the smb.conf manpage to explain this reason, as this question comes up on the samba mailing list from time to time as well. Autobuild-User: Kai Blin Autobuild-Date: Wed Dec 1 10:37:30 CET 2010 on sn-devel-104 --- Summary of changes: docs-xml/smbdotconf/locking/posixlocking.xml |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/docs-xml/smbdotconf/locking/posixlocking.xml b/docs-xml/smbdotconf/locking/posixlocking.xml index e5a89f5..25476f0 100644 --- a/docs-xml/smbdotconf/locking/posixlocking.xml +++ b/docs-xml/smbdotconf/locking/posixlocking.xml @@ -8,7 +8,8 @@ daemon maintains an database of file locks obtained by SMB clients. The default behavior is to map this internal database to POSIX locks. This means that file locks obtained by SMB clients are consistent with those seen by POSIX compliant applications accessing the files via a non-SMB - method (e.g. NFS or local file access). You should never need to disable this parameter. + method (e.g. NFS or local file access). It is very unlikely that you need to set this parameter + to "no", unless you are sharing from an NFS mount, which is not a good idea in the first place. yes -- Samba Shared Repository
[SCM] Samba Shared Repository - branch v3-6-test updated
The branch, v3-6-test has been updated via 8268e03 s3 docs: Reword posix locking text to answer a common question from e6d3146 s3: Fix bug 7832 http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-6-test - Log - commit 8268e030235b6cb5e6288a53133bba1faa9e63b1 Author: Kai Blin Date: Tue Nov 30 15:58:05 2010 +0100 s3 docs: Reword posix locking text to answer a common question vl recently pointed me to a valid reason to use posix locking = no. Fix the smb.conf manpage to explain this reason, as this question comes up on the samba mailing list from time to time as well. (cherry picked from commit fd17979293ecb37bdb16c5078fefb3f63cfb3730) --- Summary of changes: docs-xml/smbdotconf/locking/posixlocking.xml |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/docs-xml/smbdotconf/locking/posixlocking.xml b/docs-xml/smbdotconf/locking/posixlocking.xml index e5a89f5..25476f0 100644 --- a/docs-xml/smbdotconf/locking/posixlocking.xml +++ b/docs-xml/smbdotconf/locking/posixlocking.xml @@ -8,7 +8,8 @@ daemon maintains an database of file locks obtained by SMB clients. The default behavior is to map this internal database to POSIX locks. This means that file locks obtained by SMB clients are consistent with those seen by POSIX compliant applications accessing the files via a non-SMB - method (e.g. NFS or local file access). You should never need to disable this parameter. + method (e.g. NFS or local file access). It is very unlikely that you need to set this parameter + to "no", unless you are sharing from an NFS mount, which is not a good idea in the first place. yes -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 3f43b7e tevent: Fix docstring, tevent_req_is_in_progress does not destroy private data from 27df2e5 s4-test: added testing of w2k3 DC join to test-howto.py http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 3f43b7e54205298766d38f250afe0c9285ed427d Author: Kai Blin Date: Wed Nov 17 07:07:08 2010 +0100 tevent: Fix docstring, tevent_req_is_in_progress does not destroy private data Autobuild-User: Kai Blin Autobuild-Date: Wed Nov 17 07:23:51 UTC 2010 on sn-devel-104 --- Summary of changes: lib/tevent/tevent.h |2 -- 1 files changed, 0 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/tevent/tevent.h b/lib/tevent/tevent.h index 40fbbe6..82c1483 100644 --- a/lib/tevent/tevent.h +++ b/lib/tevent/tevent.h @@ -924,8 +924,6 @@ struct tevent_req *tevent_req_post(struct tevent_req *req, * * It is typically used by sync wrapper functions. * - * This function destroys the attached private data. - * * @param[in] req The request to poll. * * @return The boolean form of "is in progress". -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 6cd9234 net: Add and fix some German translation from 16e73c6 s4:objectclass LDB module - implement the "objectClass" change restrictions on Windows 2000 forest function level http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 6cd92340b6b2003dbe3380819626a1f443b3456c Author: André Hentschel Date: Sun Nov 14 23:09:03 2010 +0100 net: Add and fix some German translation typo spotted by Michael Wood Signed-off-by: Kai Blin Autobuild-User: Kai Blin Autobuild-Date: Mon Nov 15 21:44:39 UTC 2010 on sn-devel-104 --- Summary of changes: source3/locale/net/de.po |8 1 files changed, 4 insertions(+), 4 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/locale/net/de.po b/source3/locale/net/de.po index 36a4bb5..85b195e 100644 --- a/source3/locale/net/de.po +++ b/source3/locale/net/de.po @@ -3066,7 +3066,7 @@ msgstr "\t-e oder --encrypt\t\t\tSMB Ãbertragung verschlüsseln (nur UNIX erwe #: ../../utils/net_help_common.c:54 msgid "\t-k or --kerberos\t\tUse kerberos (active directory) authentication\n" -msgstr "\t-k oder --kerberos\t\tKerberos benutzen (active directory) authentication\n" +msgstr "\t-k oder --kerberos\t\tKerberos Authentifizierung benutzen (Active Directory)\n"y #: ../../utils/net_idmap.c:26 msgid "Out of memory!\n" @@ -6161,12 +6161,12 @@ msgstr "\t[%s:%s]: REG_SZ: %s\n" #: ../../utils/net_rpc_printer.c:96 #, c-format msgid "\t[%s:%s]: REG_BINARY: unknown length value not displayed\n" -msgstr "" +msgstr "\t[%s:%s]: REG_BINARY: unbekannte Länge, Daten werden nicht angezeigt\n" #: ../../utils/net_rpc_printer.c:120 #, c-format msgid "\t%s: unknown type %d\n" -msgstr "" +msgstr "\t%s: unbekannter Typ %d\n" #: ../../utils/net_rpc_printer.c:254 #, c-format @@ -6544,7 +6544,7 @@ msgstr "" #: ../../utils/net_rpc_registry.c:1173 ../../utils/net_rpc_registry.c:1179 #, c-format msgid "Closing %s..." -msgstr "" +msgstr "SchlieÃe %s..." #: ../../utils/net_rpc_registry.c:1214 msgid "net rpc registry getsd \n" -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via b73a05e s4 net: rename to samba-tool in order to not clash with s3 net from 5634f55 build: remove warnings about redifinition of boolean use -KPIC on suncc http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit b73a05e4e184238614d73c1519f2880cd946908d Author: Kai Blin Date: Sat Oct 23 19:27:26 2010 -0700 s4 net: rename to samba-tool in order to not clash with s3 net Autobuild-User: Kai Blin Autobuild-Date: Thu Oct 28 07:25:16 UTC 2010 on sn-devel-104 --- Summary of changes: selftest/target/Samba4.pm | 22 +- source4/samba_tool/drs/drs.c| 361 source4/samba_tool/drs/drs.h| 87 source4/samba_tool/drs/drs_bind.c | 136 ++ source4/samba_tool/drs/drs_kcc.c| 170 source4/samba_tool/drs/drs_replicate.c | 252 +++ source4/samba_tool/drs/drs_showrepl.c | 605 ++ source4/samba_tool/gpo.c| 618 +++ source4/samba_tool/password.c | 171 source4/samba_tool/samba_tool.c | 387 + source4/samba_tool/samba_tool.h | 39 ++ source4/samba_tool/vampire.c| 130 ++ source4/samba_tool/wscript_build| 17 + source4/selftest/skip |2 +- source4/selftest/tests.py |2 +- source4/setup/tests/blackbox_group.sh | 78 ++-- source4/setup/tests/blackbox_newuser.sh | 22 +- source4/setup/tests/blackbox_setpassword.sh | 10 +- source4/setup/tests/blackbox_spn.sh | 24 +- source4/torture/drs/python/delete_object.py |8 +- source4/torture/drs/python/fsmo.py |6 +- source4/utils/net/config.mk | 50 --- source4/utils/net/drs/net_drs.c | 361 source4/utils/net/drs/net_drs.h | 87 source4/utils/net/drs/net_drs_bind.c| 136 -- source4/utils/net/drs/net_drs_kcc.c | 170 source4/utils/net/drs/net_drs_replicate.c | 252 --- source4/utils/net/drs/net_drs_showrepl.c| 605 -- source4/utils/net/net.c | 387 - source4/utils/net/net.h | 39 -- source4/utils/net/net_gpo.c | 618 --- source4/utils/net/net_password.c| 171 source4/utils/net/net_vampire.c | 130 -- source4/utils/net/wscript_build | 18 - source4/utils/tests/test_net.sh | 40 -- source4/utils/tests/test_samba_tool.sh | 40 ++ source4/wscript_build |2 +- testprogs/blackbox/test_export_keytab.sh| 10 +- testprogs/blackbox/test_kinit.sh| 18 +- testprogs/blackbox/test_ktpass.sh |4 +- testprogs/blackbox/test_passwords.sh| 36 +- testprogs/blackbox/test_pkinit.sh |4 +- 42 files changed, 3137 insertions(+), 3188 deletions(-) create mode 100644 source4/samba_tool/drs/drs.c create mode 100644 source4/samba_tool/drs/drs.h create mode 100644 source4/samba_tool/drs/drs_bind.c create mode 100644 source4/samba_tool/drs/drs_kcc.c create mode 100644 source4/samba_tool/drs/drs_replicate.c create mode 100644 source4/samba_tool/drs/drs_showrepl.c create mode 100644 source4/samba_tool/gpo.c create mode 100644 source4/samba_tool/password.c create mode 100644 source4/samba_tool/samba_tool.c create mode 100644 source4/samba_tool/samba_tool.h create mode 100644 source4/samba_tool/vampire.c create mode 100644 source4/samba_tool/wscript_build delete mode 100644 source4/utils/net/config.mk delete mode 100644 source4/utils/net/drs/net_drs.c delete mode 100644 source4/utils/net/drs/net_drs.h delete mode 100644 source4/utils/net/drs/net_drs_bind.c delete mode 100644 source4/utils/net/drs/net_drs_kcc.c delete mode 100644 source4/utils/net/drs/net_drs_replicate.c delete mode 100644 source4/utils/net/drs/net_drs_showrepl.c delete mode 100644 source4/utils/net/net.c delete mode 100644 source4/utils/net/net.h delete mode 100644 source4/utils/net/net_gpo.c delete mode 100644 source4/utils/net/net_password.c delete mode 100644 source4/utils/net/net_vampire.c delete mode 100644 source4/utils/net/wscript_build delete mode 100755 source4/utils/tests/test_net.sh create mode 100755 source4/utils/tests/test_samba_tool.sh Changeset truncated at 500 lines: diff --git a/selftest/target/Samba4.pm b/selftest/target/Samba4.pm index ba96f08..168fe42 100644 --- a/selftest/target/Samba4.pm +++ b/selftest/target/Samba4.pm @@ -880,11 +880,11 @@ sub provision_member($$$) return undef
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 6486733 ndr: Make sure ndr_dns.c has no lines wider than 80 chars from f8d4995 tls: Inform the user if the cert/ca/private key can't be saved http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 64867330493c676cfe6a34ea462be45c638966ee Author: Kai Blin Date: Wed Oct 27 22:15:10 2010 +0200 ndr: Make sure ndr_dns.c has no lines wider than 80 chars Autobuild-User: Kai Blin Autobuild-Date: Wed Oct 27 21:17:50 UTC 2010 on sn-devel-104 --- Summary of changes: librpc/ndr/ndr_dns.c | 237 +- librpc/ndr/ndr_dns.h | 20 +++- 2 files changed, 153 insertions(+), 104 deletions(-) Changeset truncated at 500 lines: diff --git a/librpc/ndr/ndr_dns.c b/librpc/ndr/ndr_dns.c index ee2f1ce..1004db0 100644 --- a/librpc/ndr/ndr_dns.c +++ b/librpc/ndr/ndr_dns.c @@ -39,7 +39,9 @@ /** print a dns string */ -_PUBLIC_ void ndr_print_dns_string(struct ndr_print *ndr, const char *name, const char *s) +_PUBLIC_ void ndr_print_dns_string(struct ndr_print *ndr, + const char *name, + const char *s) { ndr_print_string(ndr, name, s); } @@ -57,7 +59,7 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr, while (loops < 5) { if (*offset >= ndr->data_size) { return ndr_pull_error(ndr, NDR_ERR_STRING, - "BAD DNS NAME component, bad offset"); + "BAD DNS NAME component, bad offset"); } len = ndr->data[*offset]; if (len == 0) { @@ -70,7 +72,8 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr, /* its a label pointer */ if (1 + *offset >= ndr->data_size) { return ndr_pull_error(ndr, NDR_ERR_STRING, - "BAD DNS NAME component, bad label offset"); + "BAD DNS NAME component, " \ + "bad label offset"); } *max_offset = MAX(*max_offset, *offset + 2); *offset = ((len&0x3F)<<8) | ndr->data[1 + *offset]; @@ -81,13 +84,17 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr, if ((len & 0xC0) != 0) { /* its a reserved length field */ return ndr_pull_error(ndr, NDR_ERR_STRING, - "BAD DNS NAME component, reserved lenght field: 0x%02x", (len &0xC)); + "BAD DNS NAME component, " \ + "reserved lenght field: 0x%02x", + (len &0xC)); } if (*offset + len + 2 > ndr->data_size) { return ndr_pull_error(ndr, NDR_ERR_STRING, - "BAD DNS NAME component, length too long"); + "BAD DNS NAME component, "\ + "length too long"); } - *component = (uint8_t*)talloc_strndup(ndr, (const char *)&ndr->data[1 + *offset], len); + *component = (uint8_t*)talloc_strndup(ndr, + (const char *)&ndr->data[1 + *offset], len); NDR_ERR_HAVE_NO_MEMORY(*component); *offset += len + 1; *max_offset = MAX(*max_offset, *offset); @@ -95,13 +102,16 @@ static enum ndr_err_code ndr_pull_component(struct ndr_pull *ndr, } /* too many pointers */ - return ndr_pull_error(ndr, NDR_ERR_STRING, "BAD DNS NAME component, too many pointers"); + return ndr_pull_error(ndr, NDR_ERR_STRING, + "BAD DNS NAME component, too many pointers"); } /** pull a dns_string from the wire */ -_PUBLIC_ enum ndr_err_code ndr_pull_dns_string(struct ndr_pull *ndr, int ndr_flags, const char **s) +_PUBLIC_ enum ndr_err_code ndr_pull_dns_string(struct ndr_pull *ndr, + int ndr_flags, + const char **s) { uint32_t offset = ndr->offset; uint32_t max_offset = offset; @@ -115,14 +125,18 @@ _PUBLIC_ enum ndr_err_code ndr_pull_dns
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 72c8ccd s4 dns: Implement update record prescan logic via 005a656 s4 dns: Add stub checking if updates are allowed via 1e670df s4 dns: Add a prerequisites check for updates via cfa4796 s4 dns: Switch to WERROR via 682a2e9 s4 dns: Split up the code into multiple files for easier development via cebce2b s4 dns: More work on updates via fb18175 s4 dns: Map between NTSTATUS and dns error codes via a6305c4 s4 dns: Better error handling when parsing invalid or unknown records via 69a5229 s4 dns: start handling update requests, return correct error codes via eb4f101 s4 dns: Allow more components as part of a domain name via 063727a s4 dns: Handle CNAME records via 32a1b71 s4 dns: Parse srv and soa records via 615857d s4 dns: Look up all names in the ldb database. via 678634a s4 dns: Look up records in the ldb database via 80f3088 s4 dns: Fix a data corruption in the dns_string parsing via 1c25cc7 dnsp: Can't have two memebers of a union with the same name via a7b833e s4 dns: Reply to a name request with an A record. via 719a6bb ndr dns: Add simple parser via 96195b2 s4 dns: Add a boilerplate DNS server implementation via caf4196 dns/nbt: Fix spelling of the "authoritative" flag. via 9786871 idl: Add idl describing DNS structures via 4ffdf09 netlogon.idl: Switch to explicit constants to remove dependency on nbt.idl via eeac222 s4 dns: Import DNS win32 error codes from MS-ERREF via e7358e7 s4 dsdb kcc: Prefer msDS-hasMasterNCs over hasMasterNCs when replicating via f26c9b3 s4 socket: increase the debuglevel to make add interface debug messages less verbose from 821a202 s4:rpc_server/netlogon: netr_ServerAuthenticate3 should return NO_TRUST_SAM_ACCOUNT http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 72c8ccd408070bcb3defba34865d31a1ea6311fe Author: Kai Blin Date: Sun Oct 3 12:21:00 2010 +0200 s4 dns: Implement update record prescan logic Autobuild-User: Kai Blin Autobuild-Date: Sat Oct 23 10:58:18 UTC 2010 on sn-devel-104 commit 005a65660d1d5a39cccdabca1970b7e56537df17 Author: Kai Blin Date: Sun Oct 3 00:40:32 2010 +0200 s4 dns: Add stub checking if updates are allowed commit 1e670dff6a0b9b5e42849817deb3c79e4ea30f57 Author: Kai Blin Date: Mon Oct 11 23:40:18 2010 +0200 s4 dns: Add a prerequisites check for updates commit cfa47965fe2aacf861a107c0db4daa5d43180471 Author: Kai Blin Date: Mon Oct 11 23:39:44 2010 +0200 s4 dns: Switch to WERROR commit 682a2e93daddbd95e617dde9dcdc7dee7a739929 Author: Kai Blin Date: Fri Oct 1 12:59:22 2010 -0700 s4 dns: Split up the code into multiple files for easier development commit cebce2b9a40db1f5d28e20b6eda7010e9c530a5d Author: Kai Blin Date: Mon Oct 11 23:50:16 2010 +0200 s4 dns: More work on updates commit fb181752c5a8704140e36977c2723d4d3c4c8166 Author: Kai Blin Date: Mon Oct 11 23:22:55 2010 +0200 s4 dns: Map between NTSTATUS and dns error codes commit a6305c4a168e7d3ac06f824dce05767bc7e9b9c0 Author: Kai Blin Date: Thu Sep 30 20:35:00 2010 -0700 s4 dns: Better error handling when parsing invalid or unknown records commit 69a52290ce81c62f1d6af717c4bd9b6281f0886f Author: Kai Blin Date: Thu Sep 30 18:21:53 2010 -0700 s4 dns: start handling update requests, return correct error codes commit eb4f101200f18fdf7482e14c4471d6e90b166af0 Author: Kai Blin Date: Thu Sep 30 18:20:42 2010 -0700 s4 dns: Allow more components as part of a domain name commit 063727a88b10cbd27892d0e165fe18958849f7df Author: Kai Blin Date: Thu Sep 30 17:05:23 2010 -0700 s4 dns: Handle CNAME records commit 32a1b71ec8e51a2e9486c174e4b23e3942e14079 Author: Stefan Metzmacher Date: Fri Oct 1 01:41:29 2010 +0200 s4 dns: Parse srv and soa records Signed-off-by: Kai Blin commit 615857d9899906b3505397b22e769538315a27ef Author: Kai Blin Date: Thu Sep 30 16:35:04 2010 -0700 s4 dns: Look up all names in the ldb database. commit 678634abfb590a6819b125a04777c509e83e4a3f Author: Kai Blin Date: Mon Oct 11 22:32:25 2010 +0200 s4 dns: Look up records in the ldb database commit 80f30889e9c947e6ddf31efd5d07d32d1a806209 Author: Kai Blin Date: Mon Oct 11 22:31:14 2010 +0200 s4 dns: Fix a data corruption in the dns_string parsing commit 1c25cc705762366e2525e61df3d193b2ea2106bf Author: Kai Blin Date: Mon Oct 11 22:29:05 2010 +0200 dnsp: Can't have two memebers of a union with the same name commit a7b833ec7e19bc3251ade69af101631013d60419 Author: Kai Blin Date: Wed Sep 29 17:24:53 2010 -0700 s4 dns: Reply to a name request with an A record. The first real answer to a DNS request. Still uses hard
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 5ad0ed2 libwbclient: Remove half-finished async implementation from f768b32 libcli/security Provide a common, top level libcli/security/security.h http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 5ad0ed21814e721cc36b72bf2ed13d9b37c4b7d2 Author: Kai Blin Date: Tue Oct 12 06:13:57 2010 +0200 libwbclient: Remove half-finished async implementation The old approach on doing async libwbclient was never really finished. Go ahead and remove this implementation. Autobuild-User: Kai Blin Autobuild-Date: Tue Oct 12 07:05:31 UTC 2010 on sn-devel-104 --- Summary of changes: nsswitch/libwbclient/config.mk | 14 - nsswitch/libwbclient/tests/wbclient.c | 103 nsswitch/libwbclient/wbc_idmap_async.c | 448 - nsswitch/libwbclient/wbc_pam_async.c | 484 -- nsswitch/libwbclient/wbc_sid_async.c | 291 --- nsswitch/libwbclient/wbc_util_async.c | 836 nsswitch/libwbclient/wscript_build |8 - source4/torture/winbind/config.mk |2 +- source4/torture/winbind/wscript_build |2 +- 9 files changed, 2 insertions(+), 2186 deletions(-) delete mode 100644 nsswitch/libwbclient/wbc_idmap_async.c delete mode 100644 nsswitch/libwbclient/wbc_pam_async.c delete mode 100644 nsswitch/libwbclient/wbc_sid_async.c delete mode 100644 nsswitch/libwbclient/wbc_util_async.c Changeset truncated at 500 lines: diff --git a/nsswitch/libwbclient/config.mk b/nsswitch/libwbclient/config.mk index 1c7a4b3..2b7b0f4 100644 --- a/nsswitch/libwbclient/config.mk +++ b/nsswitch/libwbclient/config.mk @@ -8,17 +8,3 @@ LIBWBCLIENT_OBJ_FILES = $(addprefix $(libwbclientsrcdir)/, wbc_guid.o \ wbc_pwd.o \ wbc_sid.o \ wbc_util.o ) - -[SUBSYSTEM::LIBWBCLIENT_ASYNC] -PUBLIC_DEPENDENCIES = LIBASYNC_REQ \ - LIBTEVENT \ - LIBTALLOC \ - UTIL_TEVENT \ - LIBWBCLIENT - -LIBWBCLIENT_ASYNC_OBJ_FILES = $(addprefix $(libwbclientsrcdir)/, wbc_async.o \ - wbc_idmap_async.o \ - wbc_pam_async.o \ - wbc_sid_async.o \ - wbc_util_async.o \ - wb_reqtrans.o ) diff --git a/nsswitch/libwbclient/tests/wbclient.c b/nsswitch/libwbclient/tests/wbclient.c index 948081b..200805e 100644 --- a/nsswitch/libwbclient/tests/wbclient.c +++ b/nsswitch/libwbclient/tests/wbclient.c @@ -23,7 +23,6 @@ #include "lib/util/data_blob.h" #include "lib/util/time.h" #include "nsswitch/libwbclient/wbclient.h" -#include "nsswitch/libwbclient/wbc_async.h" #include "torture/smbtorture.h" #include "torture/winbind/proto.h" #include "lib/util/util_net.h" @@ -46,17 +45,6 @@ #define torture_assert_wbc_ok(torture_ctx,expr,cmt) \ torture_assert_wbc_equal(torture_ctx,expr,WBC_ERR_SUCCESS,cmt) - -static void wbc_debug_torture(void *private_data, enum wbcDebugLevel level, - const char *fmt, va_list ap) PRINTF_ATTRIBUTE(3,0); -static void wbc_debug_torture(void *private_data, enum wbcDebugLevel level, - const char *fmt, va_list ap) -{ - struct torture_context *tctx = talloc_get_type_abort(private_data, - struct torture_context); - torture_comment(tctx, "%s", talloc_vasprintf(tctx, fmt, ap)); -} - static bool test_wbc_ping(struct torture_context *tctx) { torture_assert_wbc_ok(tctx, wbcPing(), @@ -65,24 +53,6 @@ static bool test_wbc_ping(struct torture_context *tctx) return true; } -static bool test_wbc_ping_async(struct torture_context *tctx) -{ - struct wb_context *wb_ctx; - struct tevent_req *req; - - wb_ctx = wb_context_init(tctx, NULL); - - req = wbcPing_send(tctx, tctx->ev, wb_ctx); - torture_assert(tctx, req, "wbcPing_send failed"); - - if(!tevent_req_poll(req, tctx->ev)) { - return false; - } - torture_assert_wbc_ok(tctx, wbcPing_recv(req), "wbcPing_recv failed"); - return true; -} - - static bool test_wbc_pingdc(struct torture_context *tctx) { torture_assert_wbc_equal(tctx, wbcPingDc("random_string", NULL), WBC_ERR_NOT_IMPLEMENTED,
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via b5f2633 dnsp: Add support for parsing HINFO records via 65d2cfd dnsp: Parse TXT records via da21f78 dnsp: Add MX record parsing via 8ff715c dnsp: Allow parsing of records via ee7ee2c ndr: Implement push function for IPv6 addresses via 013780b ndr: Add support for pulling/printing an ipv6address type via 10a4ea7 IDL: More types for the DNSP IDL file from 6320cfa s4:dsdb/common/util.c - change the usage of the RECYCLED control http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit b5f2633f7aca375c597a88bcb061563c94efb7ca Author: Kai Blin Date: Mon Aug 16 21:22:52 2010 +0200 dnsp: Add support for parsing HINFO records Autobuild-User: Kai Blin Autobuild-Date: Mon Oct 4 19:41:38 UTC 2010 on sn-devel-104 commit 65d2cfdcf1517b2e99df0556eb5bcfbc0c49a453 Author: Kai Blin Date: Fri Aug 13 11:09:09 2010 +0200 dnsp: Parse TXT records commit da21f78099884ce425dfbb99c8c246f6fcd98a3a Author: Kai Blin Date: Thu Aug 12 15:46:42 2010 +0200 dnsp: Add MX record parsing commit 8ff715c3d9ca2d6cc8880fa3040b1d1dbc942590 Author: Kai Blin Date: Tue Aug 10 15:34:27 2010 +0200 dnsp: Allow parsing of records commit ee7ee2c4c2f4c75c355cc06ce29d1ef59b2ae581 Author: Kai Blin Date: Tue Sep 28 20:33:54 2010 -0700 ndr: Implement push function for IPv6 addresses Thanks to Julien Kerihuel for providing the patch that pushed me to finish my own IPv6 patches. commit 013780b1e1942522dfee59d973a341b5f18ace67 Author: Kai Blin Date: Tue Aug 10 15:32:59 2010 +0200 ndr: Add support for pulling/printing an ipv6address type commit 10a4ea7219bb8a1b880b1f0ae4fb39b5f479bab3 Author: Kai Blin Date: Mon Aug 9 07:26:16 2010 +0200 IDL: More types for the DNSP IDL file --- Summary of changes: librpc/idl/dnsp.idl | 40 ++- librpc/ndr/libndr.h |2 + librpc/ndr/ndr_basic.c | 59 - librpc/ndr/ndr_dnsp.c| 52 ++ librpc/ndr/ndr_dnsp.h|4 ++ pidl/lib/Parse/Pidl/NDR.pm |4 ++- pidl/lib/Parse/Pidl/Samba4/Python.pm | 11 ++ pidl/lib/Parse/Pidl/Typelist.pm |6 ++- 8 files changed, 171 insertions(+), 7 deletions(-) Changeset truncated at 500 lines: diff --git a/librpc/idl/dnsp.idl b/librpc/idl/dnsp.idl index 1f0629c..7c013db 100644 --- a/librpc/idl/dnsp.idl +++ b/librpc/idl/dnsp.idl @@ -40,6 +40,7 @@ interface dnsp DNS_TYPE_HINFO = 0xD, DNS_TYPE_MINFO = 0xE, DNS_TYPE_MX= 0xF, + DNS_TYPE_TXT = 0x10, DNS_TYPE_RP= 0x11, DNS_TYPE_AFSDB = 0x12, DNS_TYPE_X25 = 0x13, @@ -64,9 +65,44 @@ interface dnsp DNS_TYPE_WINSR = 0xFF02 } dns_record_type; + typedef [public] struct { + uint32 serial; + uint32 refresh; + uint32 retry; + uint32 expire; + uint32 minimum; + dnsp_name mname; + dnsp_name rname; + } dnsp_soa; + + typedef [public] struct { + uint16 wPriority; + dnsp_name nameTarget; + } dnsp_mx; + + typedef [public] struct { + dnsp_string cpu; + dnsp_string os; + } dnsp_hinfo; + + typedef [public] struct { + uint16 wPriority; + uint16 wWeight; + uint16 wPort; + dnsp_name nameTarget; + } dnsp_srv; + typedef [nodiscriminant] union { - [case(DNS_TYPE_A)] [flag(NDR_BIG_ENDIAN)] ipv4address ip; - [case(DNS_TYPE_NS)] dnsp_name ns; + [case(DNS_TYPE_A)] [flag(NDR_BIG_ENDIAN)] ipv4address ip; + [case(DNS_TYPE_NS)] dnsp_name ns; + [case(DNS_TYPE_CNAME)] dnsp_name cname; + [case(DNS_TYPE_SOA)] [flag(NDR_BIG_ENDIAN)] dnsp_soa soa; + [case(DNS_TYPE_MX)] [flag(NDR_BIG_ENDIAN)] dnsp_mx mx; + [case(DNS_TYPE_TXT)]dnsp_string txt; + [case(DNS_TYPE_PTR)]dnsp_name ptr; + [case(DNS_TYPE_HINFO)] dnsp_hinfo hinfo; + [case(DNS_TYPE_)] ipv6address ip; + [case(DNS_TYPE_SRV)] [flag(NDR_BIG_ENDIAN)] dnsp_srv srv; [default] [flag(NDR_REMAINING)] DATA_BLOB data; } dnsRecordData; diff --git
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 0b0a717 s3 waf: more correctly generate symbols for pdb/vfs/auth/etc. modules from 0bc3e15 selftest Don't run 'speed' tests for very long http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 0b0a717255e8249b31570c2289f7b73ddc678ea9 Author: Kai Blin Date: Thu Sep 23 16:29:06 2010 -0700 s3 waf: more correctly generate symbols for pdb/vfs/auth/etc. modules --- Summary of changes: source3/wscript_build | 40 +++- 1 files changed, 27 insertions(+), 13 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index 73a6c22..75c7e0b 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -605,7 +605,7 @@ IDMAP_SRC = 'winbindd/idmap.c winbindd/idmap_util.c ${IDMAP_RW_SRC} ${IDMAP_STAT #FIXME: set NSS_INFO_STATIC during configuration NSS_INFO_STATIC = '' NSS_INFO_TEMPLATE_SRC = 'winbindd/nss_info_template.c' -NSS_INFO_SRC = 'winbindd/nss_info.c ${NSS_INFO_STATIC}' +NSS_INFO_SRC = 'winbindd/nss_info.c' IDMAP_HASH_SRC = '''winbindd/idmap_hash/idmap_hash.c winbindd/idmap_hash/mapfile.c''' @@ -778,7 +778,7 @@ SMBD_SRC_SRV = '''smbd/server_reload.c smbd/files.c smbd/connection.c smbd/smb2_setinfo.c smbd/smb2_break.c ../libcli/smb/smb2_create_blob.c - ${MANGLE_SRC} ${VFS_STATIC}''' + ${MANGLE_SRC}''' SMBD_SRC_BASE = '''${SMBD_SRC_SRV} ${RPC_SERVER_SRC} @@ -797,7 +797,6 @@ SMBD_SRC_BASE = '''${SMBD_SRC_SRV} ${RPC_CLIENT_SCHANNEL_SRC} rpc_client/init_netlogon.c rpc_client/init_samr.c -${AUTH_SRC} ${PRIVILEGES_BASIC_SRC} ${REGFIO_SRC} ${REG_API_REGF_SRC} @@ -1169,17 +1168,14 @@ for prefix in bld.env.MODULE_PREFIXES: static_key = "%s_STATIC" % prefix.upper() shared_key = "%s_SHARED" % prefix.upper() -# Set up the static modules -static_src = locals()[static_key] for module in bld.env[static_key]: -static_src += "${%s_SRC} " % module -# for some reason static_src doesn't seem to be a reference, so save it -# back to the locals -locals()[static_key] = static_src +bld.SAMBA_SUBSYSTEM(module, +source="${%s_SRC}" % module, +vars=locals()) # Set up subsystems for the shared modules for module in bld.env[shared_key]: -bld.SAMBA_SUBSYSTEM(module, +bld.SAMBA_MODULE(module, source="${%s_SRC}" % module, vars=locals()) @@ -1236,6 +1232,13 @@ bld.SAMBA_SUBSYSTEM('ASN1_UTIL', deps='talloc', local_include=False) +bld.SAMBA_SUBSYSTEM('AUTH', +source=AUTH_SRC, +deps='''AUTH_SAM AUTH_UNIX AUTH_WINBIND AUTH_WBC +AUTH_SERVER AUTH_DOMAIN AUTH_BUILTIN +AUTH_NETLOGOND''', +vars=locals()) + bld.SAMBA_SUBSYSTEM('AVAHI', source=AVAHI_SRC, deps='avahi-common avahi-client', @@ -1250,7 +1253,8 @@ bld.SAMBA_SUBSYSTEM('TLDAP', bld.SAMBA_SUBSYSTEM('PASSDB', source=PASSDB_SRC, -deps='GROUPDB TLDAP SECRETS SMBLDAP', +deps='''GROUPDB TLDAP SECRETS SMBLDAP PDB_SMBPASSWD +PDB_TDBSAM PDB_WBC_SAM PDB_LDAP''', vars=locals()) bld.SAMBA_SUBSYSTEM('PARAM_WITHOUT_REG', @@ -1321,9 +1325,17 @@ bld.SAMBA_SUBSYSTEM('SMBD_BASE', deps='''tdb tevent dl krb5 ldap gssapi gssapi_krb5 NSS_WRAPPER DYNCONFIG libwbclient crypt nsl cups cap resolv ZLIB PASSDB PARAM_WITHOUT_REG LIBS LIBSMB POPT_SAMBA KRBCLIENT AVAHI -LIBMSRPC_GEN LIBMSRPC LIBADS LIBADS_SERVER LIBADS_PRINTER''', +LIBMSRPC_GEN LIBMSRPC LIBADS LIBADS_SERVER LIBADS_PRINTER +VFS_DEFAULT RPC_MODULES AUTH''', vars=locals()) +bld.SAMBA_SUBSYSTEM('RPC_MODULES', +source='', +deps='''RPC_LSARPC RPC_SAMR RPC_WINREG RPC_INITSHUTDOWN
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 80e240f s3 waf: Remove iniparser source list from source3/wscript_build from 67b6252 s4/dsdb:kcc: cleanup and improve readability http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 80e240fe17b9f12663e09a84a29955d2bf8ed1cd Author: Kai Blin Date: Thu Sep 23 09:16:05 2010 -0700 s3 waf: Remove iniparser source list from source3/wscript_build --- Summary of changes: source3/wscript_build |6 +- 1 files changed, 1 insertions(+), 5 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index 41fbcd0..a78cab6 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -907,8 +907,7 @@ RPCCLIENT_SRC = '''${RPCCLIENT_SRC1} rpc_client/init_netlogon.c rpc_client/init_samr.c''' -PAM_WINBIND_SRC = '''../nsswitch/pam_winbind.c ${WBCOMMON_SRC} - ${LIBREPLACE_SRC} ${INIPARSER_SRC}''' +PAM_WINBIND_SRC = '../nsswitch/pam_winbind.c ${WBCOMMON_SRC} ${LIBREPLACE_SRC}' LIBSMBCLIENT_THREAD_SRC = '''libsmb/libsmb_thread_impl.c libsmb/libsmb_thread_posix.c''' @@ -1124,9 +1123,6 @@ WINBIND_KRB5_LOCATOR_SRC = '''${WINBIND_KRB5_LOCATOR_SRC1} ${LIBREPLACE_SRC}''' POPT_SRC = '''../lib/popt/findme.c ../lib/popt/popt.c ../lib/popt/poptconfig.c \ ../lib/popt/popthelp.c ../lib/popt/poptparse.c''' -INIPARSER_SRC = '''../lib/iniparser_build/iniparser.c ../lib/iniparser_build/dictionary.c -../lib/iniparser_build/strlib.c''' - NTLM_AUTH_SRC1 = '''utils/ntlm_auth.c utils/ntlm_auth_diagnostics.c''' NTLM_AUTH_SRC = '''${NTLM_AUTH_SRC1} -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via dbfb42c s3-waf: Build libwbclient as dynamic library from 34f47a3 s4-rootdse: mark registered controls as non-critical http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit dbfb42c1b50e9372184ad170f10ba75b87565965 Author: Kai Blin Date: Sun Sep 19 15:41:45 2010 -0700 s3-waf: Build libwbclient as dynamic library --- Summary of changes: source3/wscript_build | 20 ++-- 1 files changed, 10 insertions(+), 10 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index c16ceaa..90f2a7e 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -961,7 +961,7 @@ for prefix in bld.env.MODULE_PREFIXES: bld.SAMBA_SUBSYSTEM('WBCOMMON', source=WBCOMMON_SRC) -bld.SAMBA_SUBSYSTEM('LIBWBCLIENT', +bld.SAMBA_LIBRARY('libwbclient', source='''../nsswitch/libwbclient/wbc_guid.c ../nsswitch/libwbclient/wbc_idmap.c ../nsswitch/libwbclient/wbclient.c @@ -1050,14 +1050,14 @@ bld.SAMBA_SUBSYSTEM('SMBLDAP', bld.SAMBA_BINARY('smbd/smbd', source=SMBD_SRC, deps='''tdb DYNCONFIG tevent dl krb5 ldap gssapi gssapi_krb5 - NSS_WRAPPER LIBWBCLIENT crypt nsl cups cap resolv ZLIB PASSDB + NSS_WRAPPER libwbclient crypt nsl cups cap resolv ZLIB PASSDB PARAM_WITHOUT_REG LIBS LIBSMB POPT_SAMBA KRBCLIENT AVAHI''', install_path='${SBINDIR}', vars=locals()) bld.SAMBA_BINARY('nmbd/nmbd', source=NMBD_SRC, - deps='''talloc tdb tevent ZLIB cap resolv LIBWBCLIENT dl + deps='''talloc tdb tevent ZLIB cap resolv libwbclient dl NSS_WRAPPER DYNCONFIG PASSDB PARAM ldap LIB_NONSMBD LIBSMB POPT_SAMBA KRBCLIENT''', install_path='${SBINDIR}', @@ -1066,7 +1066,7 @@ bld.SAMBA_BINARY('nmbd/nmbd', bld.SAMBA_BINARY('winbindd/winbindd', source=WINBINDD_SRC, deps='''talloc tdb tevent cap dl DYNCONFIG ZLIB NSS_WRAPPER - LIBWBCLIENT PASSDB ldap resolv PARAM LIB_NONSMBD LIBSMB + libwbclient PASSDB ldap resolv PARAM LIB_NONSMBD LIBSMB POPT_SAMBA KRBCLIENT''', enabled=bld.env.build_winbind, install_path='${SBINDIR}', @@ -1074,7 +1074,7 @@ bld.SAMBA_BINARY('winbindd/winbindd', bld.SAMBA_BINARY('web/swat', source=SWAT_SRC, - deps='''talloc tevent cap DYNCONFIG LIBS LIBSMB LIBWBCLIENT PARAM + deps='''talloc tevent cap DYNCONFIG LIBS LIBSMB libwbclient PARAM LIB_NONSMBD resolv PASSDB POPT_SAMBA KRBCLIENT cups''', enabled=bld.env.build_swat, install_path='${SBINDIR}', @@ -1083,18 +1083,18 @@ bld.SAMBA_BINARY('web/swat', bld.SAMBA_BINARY('smbclient', source=CLIENT_SRC, deps='''talloc tdb cap resolv POPT_SAMBA PASSDB LIBSMB LIB_NONSMBD - PARAM_WITHOUT_REG LIBWBCLIENT DYNCONFIG PARAM KRBCLIENT''', + PARAM_WITHOUT_REG libwbclient DYNCONFIG PARAM KRBCLIENT''', vars=locals()) bld.SAMBA_BINARY('rpcclient/rpcclient', source=RPCCLIENT_SRC, deps='''talloc tdb cap resolv POPT_SAMBA PASSDB LIBSMB LIB_NONSMBD - PARAM_WITHOUT_REG LIBWBCLIENT DYNCONFIG PARAM KRBCLIENT''', + PARAM_WITHOUT_REG libwbclient DYNCONFIG PARAM KRBCLIENT''', vars=locals()) bld.SAMBA_BINARY('wbinfo', source=WBINFO_SRC, - deps='''talloc LIBWBCLIENT DYNCONFIG tevent cap + deps='''talloc libwbclient DYNCONFIG tevent cap NSS_WRAPPER ASN1_UTIL LIBTSOCKET PASSDB ldap PARAM LIB_NONSMBD LIBSAMBA POPT_SAMBA''', vars=locals()) @@ -1102,14 +1102,14 @@ bld.SAMBA_BINARY('wbinfo', bld.SAMBA_BINARY('testparm', source=TESTPARM_SRC, deps='''talloc tevent DYNCONFIG ldap cap NSS_WRAPPER - LIBWBCLIENT ASN1_UTIL LIBTSOCKET PASSDB PARAM LIB_NONSMBD +
[SCM] Samba Shared Repository - branch v3-6-test updated
The branch, v3-6-test has been updated via 0529160... s3: Fix netgrent configure checks for compilers not supporting -Werror-implicit-function-declaration from 9d8a3a4... s3: Fix bug 7635 http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-6-test - Log - commit 0529160c0829eb2437896d7d8ecc36ad4f201de2 Author: Kai Blin Date: Sat Aug 14 07:40:51 2010 +0200 s3: Fix netgrent configure checks for compilers not supporting -Werror-implicit-function-declaration This should fix bug 7620. (cherry picked from commit 45ac8ffdb4181c31605ccda5035664a8019ffc49) Signed-off-by: Kai Blin --- Summary of changes: source3/configure.in |4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/configure.in b/source3/configure.in index cb685c6..e8a5417 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6506,7 +6506,9 @@ AC_SUBST(FLAGS1) ### # Check for different/missing (set|get|end)netgrent prototypes CFLAGS_SAVE=$CFLAGS -CFLAGS="$CFLAGS -Werror-implicit-function-declaration" +if test x"$samba_cv_HAVE_Wdeclaration_after_statement" = x"yes"; then + CFLAGS="$CFLAGS -Werror-implicit-function-declaration" +fi AC_CACHE_CHECK([for setnetgrent prototype],samba_cv_setnetgrent_prototype, [ AC_TRY_COMPILE([#include #ifdef HAVE_NETGROUP_H -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 45ac8ff... s3: Fix netgrent configure checks for compilers not supporting -Werror-implicit-function-declaration from 554b114... s3: Fix bug 7635 http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 45ac8ffdb4181c31605ccda5035664a8019ffc49 Author: Kai Blin Date: Sat Aug 14 07:40:51 2010 +0200 s3: Fix netgrent configure checks for compilers not supporting -Werror-implicit-function-declaration This should fix bug 7620. --- Summary of changes: source3/configure.in |4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/configure.in b/source3/configure.in index 5156159..db524d5 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6510,7 +6510,9 @@ AC_SUBST(FLAGS1) ### # Check for different/missing (set|get|end)netgrent prototypes CFLAGS_SAVE=$CFLAGS -CFLAGS="$CFLAGS -Werror-implicit-function-declaration" +if test x"$samba_cv_HAVE_Wdeclaration_after_statement" = x"yes"; then + CFLAGS="$CFLAGS -Werror-implicit-function-declaration" +fi AC_CACHE_CHECK([for setnetgrent prototype],samba_cv_setnetgrent_prototype, [ AC_TRY_COMPILE([#include #ifdef HAVE_NETGROUP_H -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 0b6cebd... s3 build: Fix *netgrent prototype detection on opensolaris from 9c3a982... s4-ldb: added support for simple binds on ldb_ldap backend http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 0b6cebd60288b37f28176e24abeb20109dfd70e5 Author: Kai Blin Date: Fri Jul 2 22:35:28 2010 +0200 s3 build: Fix *netgrent prototype detection on opensolaris --- Summary of changes: source3/configure.in | 12 +--- 1 files changed, 9 insertions(+), 3 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/configure.in b/source3/configure.in index 424c320..4c17e4c 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6424,21 +6424,27 @@ CFLAGS_SAVE=$CFLAGS CFLAGS="$CFLAGS -Werror-implicit-function-declaration" AC_CACHE_CHECK([for setnetgrent prototype],samba_cv_setnetgrent_prototype, [ AC_TRY_COMPILE([#include -#include],[setnetgrent("foo")], +#ifdef HAVE_NETGROUP_H +#include +#endif],[setnetgrent("foo")], samba_cv_setnetgrent_prototype=yes, samba_cv_setnetgrent_prototype=no)]) if test x"$samba_cv_setnetgrent_prototype" = x"yes"; then AC_DEFINE(HAVE_SETNETGRENT_PROTOTYPE, 1, [If setnetgrent prototype is defined]) fi AC_CACHE_CHECK([for getnetgrent prototype],samba_cv_getnetgrent_prototype, [ AC_TRY_COMPILE([#include -#include],[char *dom, *user,*host; getnetgrent(&dom,&user,&host)], +#ifdef HAVE_NETGROUP_H +#include +#endif],[char *dom, *user,*host; getnetgrent(&dom,&user,&host)], samba_cv_getnetgrent_prototype=yes, samba_cv_getnetgrent_prototype=no)]) if test x"$samba_cv_getnetgrent_prototype" = x"yes"; then AC_DEFINE(HAVE_GETNETGRENT_PROTOTYPE, 1, [If getnetgrent prototype is defined]) fi AC_CACHE_CHECK([for endnetgrent prototype],samba_cv_endnetgrent_prototype, [ AC_TRY_COMPILE([#include -#include],[endnetgrent()], +#ifdef HAVE_NETGROUP_H +#include +#endif],[endnetgrent()], samba_cv_endnetgrent_prototype=yes, samba_cv_endnetgrent_prototype=no)]) if test x"$samba_cv_endnetgrent_prototype" = x"yes"; then AC_DEFINE(HAVE_ENDNETGRENT_PROTOTYPE, 1, [If endnetgrent prototype is defined]) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via cfee179... s3: Attempt to fix the build on NetBSD from 9e02764... pydsdb: Mark all SamDB and Schema methods that are in pydsdb as private, to discourage them being called directly. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit cfee179d03e9c3b8d02a51995bd1c205daabb6c3 Author: Kai Blin Date: Sun Jun 20 16:29:24 2010 +0200 s3: Attempt to fix the build on NetBSD Unlike Linux and OSX, NetBSD seems to have *netgrent prototypes in netgroup.h. --- Summary of changes: source3/configure.in |9 ++--- source3/wscript |6 +++--- 2 files changed, 9 insertions(+), 6 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/configure.in b/source3/configure.in index 04ddc03..424c320 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6423,19 +6423,22 @@ AC_SUBST(FLAGS1) CFLAGS_SAVE=$CFLAGS CFLAGS="$CFLAGS -Werror-implicit-function-declaration" AC_CACHE_CHECK([for setnetgrent prototype],samba_cv_setnetgrent_prototype, [ -AC_TRY_COMPILE([#include],[setnetgrent("foo")], +AC_TRY_COMPILE([#include +#include],[setnetgrent("foo")], samba_cv_setnetgrent_prototype=yes, samba_cv_setnetgrent_prototype=no)]) if test x"$samba_cv_setnetgrent_prototype" = x"yes"; then AC_DEFINE(HAVE_SETNETGRENT_PROTOTYPE, 1, [If setnetgrent prototype is defined]) fi AC_CACHE_CHECK([for getnetgrent prototype],samba_cv_getnetgrent_prototype, [ -AC_TRY_COMPILE([#include],[char *dom, *user,*host; getnetgrent(&dom,&user,&host)], +AC_TRY_COMPILE([#include +#include],[char *dom, *user,*host; getnetgrent(&dom,&user,&host)], samba_cv_getnetgrent_prototype=yes, samba_cv_getnetgrent_prototype=no)]) if test x"$samba_cv_getnetgrent_prototype" = x"yes"; then AC_DEFINE(HAVE_GETNETGRENT_PROTOTYPE, 1, [If getnetgrent prototype is defined]) fi AC_CACHE_CHECK([for endnetgrent prototype],samba_cv_endnetgrent_prototype, [ -AC_TRY_COMPILE([#include],[endnetgrent()], +AC_TRY_COMPILE([#include +#include],[endnetgrent()], samba_cv_endnetgrent_prototype=yes, samba_cv_endnetgrent_prototype=no)]) if test x"$samba_cv_endnetgrent_prototype" = x"yes"; then AC_DEFINE(HAVE_ENDNETGRENT_PROTOTYPE, 1, [If endnetgrent prototype is defined]) diff --git a/source3/wscript b/source3/wscript index aec71af..0b31563 100644 --- a/source3/wscript +++ b/source3/wscript @@ -364,15 +364,15 @@ utimensat vsyslog _write __write __xstat conf.CHECK_FUNCS('setnetgrent getnetgrent endnetgrent') conf.CHECK_CODE('setnetgrent("foo")', 'HAVE_SETNETGRENT_PROTOTYPE', msg="Checking for setnetgrent prototype", -headers='netdb.h', +headers='netdb.h netgroup.h', cflags="-Werror-implicit-function-declaration") conf.CHECK_CODE('getnetgrent', 'HAVE_GETNETGRENT_PROTOTYPE', msg="Checking for getnetgrent prototype", -headers='netdb.h', +headers='netdb.h netgroup.h', cflags="-Werror-implicit-function-declaration") conf.CHECK_CODE('endnetgrent', 'HAVE_ENDNETGRENT_PROTOTYPE', msg="Checking for endnetgrent prototype", -headers='netdb.h', +headers='netdb.h netgroup.h', cflags="-Werror-implicit-function-declaration") #FIXME: Should just be set when krb5 and ldap requirements are fulfilled -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via a453b87... s3-waf: Change the (set|get|end)netgrent checks to match the configure.in checks via ff32f69... s3 configure: Check for (set|get|end)netgrent prototypes via fa3e50f... build: Allow for a custom message in CHECK_C_PROTOTYPE from 1f07f53... ldb: Remove last import of dsdb. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit a453b87d68f89c48e0d0545fe240801e4eac1686 Author: Kai Blin Date: Sun Jun 20 09:49:34 2010 +0200 s3-waf: Change the (set|get|end)netgrent checks to match the configure.in checks commit ff32f691bba41afab45efe7e21a2c91bb2c157bb Author: Kai Blin Date: Sun Jun 20 09:36:19 2010 +0200 s3 configure: Check for (set|get|end)netgrent prototypes commit fa3e50fee421a7fe407510627e0fdbcd5f4013c0 Author: Kai Blin Date: Thu Jun 17 22:41:57 2010 +0200 build: Allow for a custom message in CHECK_C_PROTOTYPE --- Summary of changes: buildtools/wafsamba/samba_conftests.py |6 -- source3/configure.in | 25 - source3/wscript| 21 - 3 files changed, 40 insertions(+), 12 deletions(-) Changeset truncated at 500 lines: diff --git a/buildtools/wafsamba/samba_conftests.py b/buildtools/wafsamba/samba_conftests.py index a5c1b38..c95a887 100644 --- a/buildtools/wafsamba/samba_conftests.py +++ b/buildtools/wafsamba/samba_conftests.py @@ -34,17 +34,19 @@ def CHECK_LARGEFILE(conf, define='HAVE_LARGEFILE'): @conf -def CHECK_C_PROTOTYPE(conf, function, prototype, define, headers=None): +def CHECK_C_PROTOTYPE(conf, function, prototype, define, headers=None, msg=None): '''verify that a C prototype matches the one on the current system''' if not conf.CHECK_DECLS(function, headers=headers): return False +if not msg: +msg = 'Checking C prototype for %s' % function return conf.CHECK_CODE('%s; void *_x = (void *)%s' % (prototype, function), define=define, local_include=False, headers=headers, link=False, execute=False, - msg='Checking C prototype for %s' % function) + msg=msg) @conf diff --git a/source3/configure.in b/source3/configure.in index cda14f5..04ddc03 100644 --- a/source3/configure.in +++ b/source3/configure.in @@ -6418,7 +6418,30 @@ AC_SUBST(BUILD_INIPARSER) AC_SUBST(INIPARSERLIBS) AC_SUBST(FLAGS1) - +### +# Check for different/missing (set|get|end)netgrent prototypes +CFLAGS_SAVE=$CFLAGS +CFLAGS="$CFLAGS -Werror-implicit-function-declaration" +AC_CACHE_CHECK([for setnetgrent prototype],samba_cv_setnetgrent_prototype, [ +AC_TRY_COMPILE([#include],[setnetgrent("foo")], +samba_cv_setnetgrent_prototype=yes, samba_cv_setnetgrent_prototype=no)]) +if test x"$samba_cv_setnetgrent_prototype" = x"yes"; then +AC_DEFINE(HAVE_SETNETGRENT_PROTOTYPE, 1, [If setnetgrent prototype is defined]) +fi +AC_CACHE_CHECK([for getnetgrent prototype],samba_cv_getnetgrent_prototype, [ +AC_TRY_COMPILE([#include],[char *dom, *user,*host; getnetgrent(&dom,&user,&host)], +samba_cv_getnetgrent_prototype=yes, samba_cv_getnetgrent_prototype=no)]) +if test x"$samba_cv_getnetgrent_prototype" = x"yes"; then +AC_DEFINE(HAVE_GETNETGRENT_PROTOTYPE, 1, [If getnetgrent prototype is defined]) +fi +AC_CACHE_CHECK([for endnetgrent prototype],samba_cv_endnetgrent_prototype, [ +AC_TRY_COMPILE([#include],[endnetgrent()], +samba_cv_endnetgrent_prototype=yes, samba_cv_endnetgrent_prototype=no)]) +if test x"$samba_cv_endnetgrent_prototype" = x"yes"; then +AC_DEFINE(HAVE_ENDNETGRENT_PROTOTYPE, 1, [If endnetgrent prototype is defined]) +fi + +CFLAGS=$CFLAGS_SAVE # Checks for the vfs_fileid module # Start diff --git a/source3/wscript b/source3/wscript index 9bbedea..aec71af 100644 --- a/source3/wscript +++ b/source3/wscript @@ -362,15 +362,18 @@ utimensat vsyslog _write __write __xstat define='HAVE_DIRENT_D_OFF') conf.CHECK_FUNCS('setnetgrent getnetgrent endnetgrent') -conf.CHECK_C_PROTOTYPE('setnetgrent', - 'extern int setnetgrent(const char* netgroup)', - define='HAVE_SETNETGRENT_PROTOTYPE', headers='netdb.h') -conf.CHECK_C_PROTOTYPE('getnetgrent', - 'extern int getn
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 9328097... s3-waf: Fix the OSX 10.4 build by adding an explicit resolv dep on smbclient via 83ad437... s3-waf: Add check for iconv via 7a1c247... s3-waf: Work around missing *netgrent prototypes on OSX 10.4 from d9c81e3... s4:dcesrv_netr_DsRAddressToSitenamesExW - fix the read of the IP packet version http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 93280974b8fb236b212b9116a1d8921329e5e1d8 Author: Kai Blin Date: Thu Jun 17 08:09:41 2010 +0200 s3-waf: Fix the OSX 10.4 build by adding an explicit resolv dep on smbclient commit 83ad437a9cf9f0ed36ea0e72282020e9330f8c88 Author: Kai Blin Date: Tue Jun 15 06:53:11 2010 +0200 s3-waf: Add check for iconv commit 7a1c24705dba06753a693a3dbee93d473726d05a Author: Kai Blin Date: Tue Jun 15 06:52:42 2010 +0200 s3-waf: Work around missing *netgrent prototypes on OSX 10.4 --- Summary of changes: source3/smbd/password.c | 11 +++ source3/wscript | 29 - source3/wscript_build |4 ++-- 3 files changed, 37 insertions(+), 7 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/smbd/password.c b/source3/smbd/password.c index b1fd4b8..1a55a39 100644 --- a/source3/smbd/password.c +++ b/source3/smbd/password.c @@ -21,6 +21,17 @@ #include "includes.h" #include "smbd/globals.h" +/* Fix up prototypes for OSX 10.4, where they're missing */ +#ifndef HAVE_SETNETGRENT_PROTOTYPE +extern int setnetgrent(const char* netgroup); +#endif +#ifndef HAVE_GETNETGRENT_PROTOTYPE +extern int getnetgrent(char **host, char **user, char **domain); +#endif +#ifndef HAVE_ENDNETGRENT_PROTOTYPE +extern void endnetgrent(void); +#endif + enum server_allocated_state { SERVER_ALLOCATED_REQUIRED_YES, SERVER_ALLOCATED_REQUIRED_NO, SERVER_ALLOCATED_REQUIRED_ANY}; diff --git a/source3/wscript b/source3/wscript index 0a4dc37..9bbedea 100644 --- a/source3/wscript +++ b/source3/wscript @@ -49,6 +49,7 @@ def set_options(opt): opt.SAMBA3_ADD_OPTION('utmp') opt.SAMBA3_ADD_OPTION('pthreadpool', with_name="enable", without_name="disable") opt.SAMBA3_ADD_OPTION('avahi', with_name="enable", without_name="disable") +opt.SAMBA3_ADD_OPTION('iconv') def configure(conf): @@ -88,13 +89,13 @@ def configure(conf): conf.RECURSE('../lib/socket_wrapper') conf.RECURSE('../lib/zlib') -conf.CHECK_HEADERS('execinfo.h libexc.h libunwind.h') +conf.CHECK_HEADERS('execinfo.h libexc.h libunwind.h netdb.h') conf.CHECK_FUNCS('getcwd fchown chmod fchmod mknod mknod64') conf.CHECK_FUNCS('strtol strchr strupr chflags') conf.CHECK_FUNCS('getrlimit fsync fdatasync setpgid') conf.CHECK_FUNCS('setsid glob strpbrk crypt16 getauthuid') -conf.CHECK_FUNCS('sigprocmask sigblock sigaction sigset innetgr setnetgrent getnetgrent endnetgrent') +conf.CHECK_FUNCS('sigprocmask sigblock sigaction sigset innetgr') conf.CHECK_FUNCS('initgroups select poll rdchk getgrnam getgrent pathconf') conf.CHECK_FUNCS('setpriv setgidx setuidx setgroups sysconf stat64 fstat64') conf.CHECK_FUNCS('lstat64 fopen64 atexit grantpt lseek64 ftruncate64 posix_fallocate posix_fallocate64') @@ -226,7 +227,7 @@ _acl __acl add_proplist_entry atexit attr_getf attr_list attr_listf attropen attr_remove attr_removef attr_set attr_setf backtrace_symbols bindtextdomain _chdir __chdir chflags chmod _close __close _closedir __closedir closedir64 creat64 crypt16 delproplist devnm dgettext dirfd -DNSServiceRegister _dup __dup _dup2 __dup2 endmntent endnetgrent execl +DNSServiceRegister _dup __dup _dup2 __dup2 endmntent execl extattr_delete_fd extattr_delete_link extattr_get_fd extattr_get_file extattr_get_link extattr_list_fd extattr_list_file extattr_list_link extattr_set_fd extattr_set_file extattr_set_link _facl __facl _fchdir @@ -236,7 +237,7 @@ _fork __fork fremoveea fremovexattr fseek64 fseeko64 fsetea fsetproplist fsetxattr _fstat __fstat fstat64 _fstat64 __fstat64 fsync ftell64 ftello64 ftruncate64 futimens futimes __fxstat getauthuid getcwd _getcwd __getcwd getdents __getdents getdents64 getdirentries -getgrent getgrnam getgrouplist getmntent getnetgrent getpagesize +getgrent getgrnam getgrouplist getmntent getpagesize getproplist get_proplist_entry getpwanam getpwent_r getrlimit gettext glob grantpt hstrerror initgroups innetgr inotify_init lgetea lgetxattr listea listxattr llistea llistxattr @@ -250,7 +251,7 @@ pwrite _pwrite __pwrite pwrite64 _pwrite64 __pwr
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 7747575... s3-waf: Fix up smbclient dependencies via 6331d7f... s3-waf: Fixed dependencies of the the krbclient subsystem. via 6c7c81a... s3-waf: Fixed dependencies of the the avahi subsystem. from 74fad25... s4:ldb_msg_element_compare - fix typo in comment http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 7747575ef485a4d8cfe2fe9ada18b5b009074a0f Author: Kai Blin Date: Wed Jun 2 11:28:54 2010 +0200 s3-waf: Fix up smbclient dependencies commit 6331d7f90d411f18b760f6525a4534a3c663445f Author: Kai Blin Date: Wed Jun 2 11:21:18 2010 +0200 s3-waf: Fixed dependencies of the the krbclient subsystem. commit 6c7c81a8f286a10366a0d2cbb36c00272d6d1d47 Author: Andreas Schneider Date: Wed Jun 2 11:19:36 2010 +0200 s3-waf: Fixed dependencies of the the avahi subsystem. --- Summary of changes: source3/wscript_build |7 --- 1 files changed, 4 insertions(+), 3 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index ab578ff..ab61d80 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -782,8 +782,7 @@ CLIENT_SRC1 = '''client/client.c client/clitar.c ${RPC_CLIENT_SRC} ../librpc/rpc/binding.c client/dnsbrowse.c ${RPC_CLIENT_SRC1} ${RPC_PARSE_SRC2}''' -CLIENT_SRC = '''${CLIENT_SRC1} ${PARAM_SRC} - ${KRBCLIENT_SRC} ${LIBMSRPC_GEN_SRC} +CLIENT_SRC = '''${CLIENT_SRC1} ${LIBMSRPC_GEN_SRC} ${READLINE_SRC} ${DISPLAY_SEC_SRC}''' @@ -855,6 +854,7 @@ bld.SAMBA_SUBSYSTEM('ASN1_UTIL', bld.SAMBA_SUBSYSTEM('AVAHI', source=AVAHI_SRC, +deps='avahi-common avahi-client', enabled=bld.env.with_avahi) bld.SAMBA_SUBSYSTEM('GROUPDB', @@ -883,6 +883,7 @@ bld.SAMBA_SUBSYSTEM('POPT_SAMBA', bld.SAMBA_SUBSYSTEM('KRBCLIENT', source=KRBCLIENT_SRC, +deps='krb5 gssapi gssapi_krb5', vars=locals()) bld.SAMBA_SUBSYSTEM('LIBS', @@ -957,7 +958,7 @@ bld.SAMBA_BINARY('web/swat', bld.SAMBA_BINARY('smbclient', source=CLIENT_SRC, deps='''talloc tdb cap POPT_SAMBA PASSDB LIBSMB LIB_NONSMBD - PARAM_WITHOUT_REG LIBWBCLIENT DYNCONFIG''', + PARAM_WITHOUT_REG LIBWBCLIENT DYNCONFIG PARAM KRBCLIENT''', vars=locals()) bld.SAMBA_BINARY('wbinfo', -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via da894b7... s3-waf: Fix the build from f702578... s3: remove unused prototype for lp_idmap_domains(). http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit da894b7023327ffaf533ec9de1b7cb2a199fe28c Author: Kai Blin Date: Tue Jun 1 15:37:40 2010 +0200 s3-waf: Fix the build --- Summary of changes: source3/wscript_build |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index 17a1352..ab578ff 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -175,7 +175,8 @@ READLINE_SRC = '''lib/readline.c''' POPT_LIB_SRC = '''lib/popt_common.c''' -PARAM_WITHOUT_REG_SRC = '''param/loadparm.c param/util.c lib/sharesec.c lib/ldap_debug_handler.c''' +PARAM_WITHOUT_REG_SRC = '''param/loadparm.c param/util.c param/loadparm_server_role.c + lib/sharesec.c lib/ldap_debug_handler.c''' PARAM_REG_ADD_SRC = '''${REG_SMBCONF_SRC} ${LIBSMBCONF_SRC} ${PRIVILEGES_BASIC_SRC}''' PARAM_SRC = '''${PARAM_REG_ADD_SRC}''' -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via a6c921f... s3-waf: Add check for dirent.d_off member from 3f14d03... s3:winbindd: make sure we only call static_init_idmap once http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit a6c921fef74e368da9a12b8ce82fedbf86c66ed4 Author: Kai Blin Date: Tue Jun 1 10:31:11 2010 +0200 s3-waf: Add check for dirent.d_off member --- Summary of changes: source3/wscript |4 1 files changed, 4 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index cc3f0d9..0a4dc37 100644 --- a/source3/wscript +++ b/source3/wscript @@ -356,6 +356,10 @@ utimensat vsyslog _write __write __xstat headers='unistd.h sys/types.h', msg="Checking for minor macro") +conf.CHECK_STRUCTURE_MEMBER('struct dirent', 'd_off', +headers='unistd.h sys/types.h dirent.h', +define='HAVE_DIRENT_D_OFF') + #FIXME: Should just be set when krb5 and ldap requirements are fulfilled if Options.options.with_ads: conf.DEFINE('WITH_ADS', '1') -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 458b248... s3-waf: Check for device major and minor macros via b497447... s3-waf: Add check for asm/types.h from 5a3e744... pyldb_util: Remove dependency on LIBPYTHON - it's already there implicitly and not available in the standalone build. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 458b2484c73b9381aa3d10b94b3e3576d4bb44d3 Author: Kai Blin Date: Mon May 31 23:02:16 2010 +0200 s3-waf: Check for device major and minor macros commit b497447e1722e6d89406f71b2371b61c616cf71b Author: Kai Blin Date: Mon May 31 22:39:47 2010 +0200 s3-waf: Add check for asm/types.h --- Summary of changes: source3/wscript | 10 ++ 1 files changed, 10 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 41a06b4..cc3f0d9 100644 --- a/source3/wscript +++ b/source3/wscript @@ -346,6 +346,16 @@ utimensat vsyslog _write __write __xstat msg="Checking whether xattr interface takes additional options", headers='sys/types.h attr/xattr.h sys/xattr.h') +conf.CHECK_HEADERS('asm/types.h') + +conf.CHECK_CODE('dev_t dev; int i = major(dev); return 0', "HAVE_DEVICE_MAJOR_FN", +headers='unistd.h sys/types.h', +msg="Checking for major macro") + +conf.CHECK_CODE('dev_t dev; int i = minor(dev); return 0', "HAVE_DEVICE_MINOR_FN", +headers='unistd.h sys/types.h', +msg="Checking for minor macro") + #FIXME: Should just be set when krb5 and ldap requirements are fulfilled if Options.options.with_ads: conf.DEFINE('WITH_ADS', '1') -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 0fddbe4... s3-waf: Check if compiler supports LL suffix via 3811fda... s3-waf: Check for broken nisplus include files from e80301e... s3-smbd: remove unused sconn from token_contains_name(). http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 0fddbe472edb33861386cb11cc141d9b02f95a02 Author: Kai Blin Date: Mon May 31 08:36:29 2010 +0200 s3-waf: Check if compiler supports LL suffix commit 3811fdab5cec7830420c88cce99ea966236434f0 Author: Kai Blin Date: Mon May 31 08:35:58 2010 +0200 s3-waf: Check for broken nisplus include files --- Summary of changes: source3/wscript |9 + 1 files changed, 9 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index a011a52..41a06b4 100644 --- a/source3/wscript +++ b/source3/wscript @@ -202,6 +202,9 @@ main() { conf.CHECK_CODE('uint32 testvar;', 'HAVE_INT16_FROM_RPC_RPC_H', headers='sys/types.h rpc/rpc.h', msg="Checking for uint32 typedef included by rpc/rpc.h") +conf.CHECK_CODE('int i;', 'BROKEN_NISPLUS_INCLUDE_FILES', +headers='sys/types.h sys/acl.h rpcsvc/nis.h', +msg="Checking for broken nisplus include files") # Check if the compiler will optimize out functions conf.CHECK_CODE(''' @@ -212,6 +215,12 @@ if (0) { }''', 'HAVE_COMPILER_WILL_OPTIMIZE_OUT_FNS', msg="Checking if the compiler will optimize out functions") +# Check if the compiler supports the LL suffix on long long integers +# AIX needs this +conf.CHECK_CODE('long long i = 0x80LL', 'COMPILER_SUPPORTS_LL', +headers='stdio.h', +msg="Checking for LL suffix on long long integers") + conf.CHECK_FUNCS(''' _acl __acl add_proplist_entry atexit attr_getf attr_list attr_listf attropen attr_remove attr_removef attr_set attr_setf backtrace_symbols -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via c866920... s3-waf: Fix build after ntlmssp_sign.c moved from 6af6b96... ldb: Revert signature file changes made in 151e239bcf2860411527a953d627b2d724c0a57e http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit c866920c3de0fc75e9939bcc19ff880819a62e07 Author: Kai Blin Date: Mon May 31 15:56:30 2010 +0200 s3-waf: Fix build after ntlmssp_sign.c moved --- Summary of changes: source3/wscript_build |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index 4619327..17a1352 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -234,7 +234,8 @@ LIBSMB_ERR_SRC = '${LIBSMB_ERR_SRC0} ${LIBSMB_ERR_SRC1} ${RPC_PARSE_SRC1}' LIBSMB_SRC0 = ''' ../libcli/auth/ntlm_check.c libsmb/ntlmssp.c - libsmb/ntlmssp_sign.c + ../libcli/auth/ntlmssp.c + ../libcli/auth/ntlmssp_sign.c ${LIBNDR_NTLMSSP_SRC} ../libcli/auth/ntlmssp_ndr.c''' -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 6af6b96... ldb: Revert signature file changes made in 151e239bcf2860411527a953d627b2d724c0a57e from 9864164... s3-netlogon: use LSA in _netr_NetrEnumerateTrustedDomains. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 6af6b96b5728d7690979b2d3258eddb48e55bed4 Author: Kai Blin Date: Mon May 31 15:33:40 2010 +0200 ldb: Revert signature file changes made in 151e239bcf2860411527a953d627b2d724c0a57e --- Summary of changes: source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs |5 + 1 files changed, 5 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs b/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs index 2206e79..4639220 100644 --- a/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs +++ b/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs @@ -166,6 +166,7 @@ ldb_parse_tree_copy_shallow: struct ldb_parse_tree *(TALLOC_CTX *, const struct ldb_qsort: void (void * const, size_t, size_t, void *, ldb_qsort_cmp_fn_t) ldb_register_backend: int (const char *, ldb_connect_fn) ldb_register_module: int (const struct ldb_module_ops *) +ldb_register_samba_handlers: int (struct ldb_context *) ldb_rename: int (struct ldb_context *, struct ldb_dn *, struct ldb_dn *) ldb_reply_add_control: int (struct ldb_reply *, const char *, bool, void *) ldb_reply_get_control: struct ldb_control *(struct ldb_reply *, const char *) @@ -176,6 +177,8 @@ ldb_request_get_control: struct ldb_control *(struct ldb_request *, const char * ldb_request_get_status: int (struct ldb_request *) ldb_request_set_state: void (struct ldb_request *, int) ldb_reset_err_string: void (struct ldb_context *) +ldb_samba_syntax_by_lDAPDisplayName: const struct ldb_schema_syntax *(struct ldb_context *, const char *) +ldb_samba_syntax_by_name: const struct ldb_schema_syntax *(struct ldb_context *, const char *) ldb_schema_attribute_add: int (struct ldb_context *, const char *, unsigned int, const char *) ldb_schema_attribute_add_with_syntax: int (struct ldb_context *, const char *, unsigned int, const struct ldb_schema_syntax *) ldb_schema_attribute_by_name: const struct ldb_schema_attribute *(struct ldb_context *, const char *) @@ -217,3 +220,5 @@ ldb_val_map_remote: struct ldb_val (struct ldb_module *, void *, const struct ld ldb_val_to_time: int (const struct ldb_val *, time_t *) ldb_valid_attr_name: int (const char *) ldb_wait: int (struct ldb_handle *, enum ldb_wait_type) +ldb_wrap_connect: struct ldb_context *(TALLOC_CTX *, struct tevent_context *, struct loadparm_context *, const char *, struct auth_session_info *, struct cli_credentials *, unsigned int) +ldb_wrap_fork_hook: void (void) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via e3997c2... wafsamba: Correctly detect if bld.env.XSLTPROC is not set from cd2dd33... ldb: Support building with system ldb library http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit e3997c2a6d82276cc736686099ab897fa4fd0047 Author: Kai Blin Date: Mon May 31 09:39:44 2010 +0200 wafsamba: Correctly detect if bld.env.XSLTPROC is not set This fixes the build on some build farm hosts and my machine. Jelmer, please check. --- Summary of changes: buildtools/wafsamba/wafsamba.py |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py index eb5aa91..41b866d 100644 --- a/buildtools/wafsamba/wafsamba.py +++ b/buildtools/wafsamba/wafsamba.py @@ -299,7 +299,7 @@ def SAMBA_BINARY(bld, binname, source, if subsystem_name is not None: bld.TARGET_ALIAS(subsystem_name, binname) -if manpages is not None and bld.env.XSLTPROC is not None: +if manpages is not None and 'XSLTPROC' in bld.env: bld.env.MAN_XSL = 'http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl' for m in manpages.split(): source = m + '.xml' -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via e4a9bdc... s3-waf: Fix the build after rebase via 209555e... s3-waf: support avahi builds via 04d251a... build: Also replace '-' by '_' when creating header defines via 8e2b69c... s3-waf: Add more darwin-specific options from 5a0b3cf... s4:tests/python/passwords.py - fix filter http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit e4a9bdc39f499c7bfb04c00bc986c4894cf8e49a Author: Kai Blin Date: Sun May 30 23:27:08 2010 +0200 s3-waf: Fix the build after rebase commit 209555ef09bf57aa79f164f6e85a16e5b4977609 Author: Kai Blin Date: Fri May 28 15:56:32 2010 +0200 s3-waf: support avahi builds commit 04d251a8476b8cf267667fc108f2f8c213fceb54 Author: Kai Blin Date: Fri May 28 15:50:26 2010 +0200 build: Also replace '-' by '_' when creating header defines Tridge, please check commit 8e2b69ca46739960354b90c6ef843e68bb4e2330 Author: Kai Blin Date: Wed May 26 13:44:43 2010 +0200 s3-waf: Add more darwin-specific options --- Summary of changes: buildtools/wafsamba/samba_autoconf.py |1 + source3/wscript | 14 ++ source3/wscript_build | 16 ++-- 3 files changed, 25 insertions(+), 6 deletions(-) Changeset truncated at 500 lines: diff --git a/buildtools/wafsamba/samba_autoconf.py b/buildtools/wafsamba/samba_autoconf.py index 743f420..3551e02 100644 --- a/buildtools/wafsamba/samba_autoconf.py +++ b/buildtools/wafsamba/samba_autoconf.py @@ -84,6 +84,7 @@ def CHECK_HEADER(conf, h, add_headers=False, lib=None): return False d = h.upper().replace('/', '_') d = d.replace('.', '_') +d = d.replace('-', '_') d = 'HAVE_%s' % d if CONFIG_SET(conf, d): if add_headers: diff --git a/source3/wscript b/source3/wscript index e2e6f4d..a011a52 100644 --- a/source3/wscript +++ b/source3/wscript @@ -48,6 +48,7 @@ def set_options(opt): opt.SAMBA3_ADD_OPTION('sendfile-support') opt.SAMBA3_ADD_OPTION('utmp') opt.SAMBA3_ADD_OPTION('pthreadpool', with_name="enable", without_name="disable") +opt.SAMBA3_ADD_OPTION('avahi', with_name="enable", without_name="disable") def configure(conf): @@ -532,6 +533,17 @@ return 0; msg="Checking whether pututline returns pointer") conf.DEFINE('WITH_UTMP', 1) +if Options.options.with_avahi: +conf.env.with_avahi = True +if not conf.CHECK_HEADERS('avahi-common/watch.h avahi-client/client.h'): conf.env.with_avahi = False +if not conf.CHECK_FUNCS_IN('avahi_client_new', 'avahi-client'): conf.env.with_avahi = False +if not conf.CHECK_FUNCS_IN('avahi_strerror', 'avahi-common'): conf.env.with_avahi = False +if conf.env.with_avahi: +conf.DEFINE('WITH_AVAHI_SUPPORT', 1) +else: +conf.SET_TARGET_TYPE('avahi-common', 'EMPTY') +conf.SET_TARGET_TYPE('avahi-client', 'EMPTY') + # FIXME: these should be tests for features, but the old build system just # checks for OSes. import sys @@ -547,7 +559,9 @@ return 0; conf.DEFINE('QNX', '1') conf.DEFINE('STAT_ST_BLOCKSIZE', '512') elif (host_os.rfind('darwin') > -1): +conf.DEFINE('DARWINOS', 1) conf.DEFINE('STAT_ST_BLOCKSIZE', '512') +conf.ADD_CFLAGS('-fno-common') # FIXME: Add more checks here. else: print "Unknown host_os '%s', please report this to samba-techni...@samba.org" % host_os diff --git a/source3/wscript_build b/source3/wscript_build index 770877e..4619327 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -23,7 +23,7 @@ AFS_SRC = 'lib/afs.c' AFS_SETTOKEN_SRC = 'lib/afs_settoken.c' -AVAHI_SRC = '' # TODO: fix +AVAHI_SRC = 'lib/avahi.c smbd/avahi_register.c' SERVER_MUTEX_SRC = 'lib/server_mutex.c' @@ -149,7 +149,7 @@ LIB_SRC = '''${LIBSAMBAUTIL_SRC} ${UTIL_SRC} ${CRYPTO_SRC} lib/bitmap.c lib/dprintf.c ${UTIL_REG_SRC} lib/wins_srv.c lib/util_str.c lib/clobber.c lib/util_sid.c lib/util_uuid.c - lib/util_unistr.c lib/util_file.c + lib/util_unistr.c lib/util_file.c lib/util_names.c lib/util.c lib/util_sock.c lib/sock_exec.c lib/util_sec.c lib/substitute.c lib/dbwrap_util.c
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via f3b0485... s3-waf: Set HAVE_GSSAPI if gssapi libs were found from 6a78241... libreplace: include sys/file.h only when available http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f3b04854b855e1547182bc36d57841dac3b041d8 Author: Kai Blin Date: Thu May 27 23:38:02 2010 +0200 s3-waf: Set HAVE_GSSAPI if gssapi libs were found --- Summary of changes: source3/wscript |3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 7472c7d..e2e6f4d 100644 --- a/source3/wscript +++ b/source3/wscript @@ -406,7 +406,8 @@ utimensat vsyslog _write __write __xstat conf.CHECK_FUNCS_IN('crypto', 'des_set_key') conf.CHECK_FUNCS_IN('copy_Authenticator', 'asn1') conf.CHECK_FUNCS_IN('roken_getaddrinfo_hostspec', 'roken') -conf.CHECK_FUNCS_IN('gss_display_status', 'gssapi gssapi_krb5') +if conf.CHECK_FUNCS_IN('gss_display_status', 'gssapi gssapi_krb5'): +conf.DEFINE('HAVE_GSSAPI', '1') conf.CHECK_FUNCS_IN('krb5_mk_req_extended krb5_kt_compare', 'krb5') conf.CHECK_FUNCS(''' krb5_set_real_time krb5_set_default_in_tkt_etypes krb5_set_default_tgs_enctypes -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via f733362... s3-waf: Support builds with utmp accounting from 4eba4b0... s3-waf: Match the defines from the autotools build on PACKAGE_* http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f7333629f80997822e0e617050a31d1fcc2d9595 Author: Kai Blin Date: Fri May 28 15:17:35 2010 +0200 s3-waf: Support builds with utmp accounting --- Summary of changes: source3/wscript | 37 ++--- 1 files changed, 34 insertions(+), 3 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 73e00d1..7472c7d 100644 --- a/source3/wscript +++ b/source3/wscript @@ -228,7 +228,7 @@ ftell64 ftello64 ftruncate64 futimens futimes __fxstat getauthuid getcwd _getcwd __getcwd getdents __getdents getdents64 getdirentries getgrent getgrnam getgrouplist getmntent getnetgrent getpagesize getproplist get_proplist_entry getpwanam getpwent_r getrlimit gettext -getutmpx getutxent glob grantpt hstrerror initgroups innetgr +glob grantpt hstrerror initgroups innetgr inotify_init lgetea lgetxattr listea listxattr llistea llistxattr llseek _llseek __llseek lremoveea lremovexattr _lseek __lseek lseek64 lsetea lsetxattr _lstat __lstat lstat64 _lstat64 __lstat64 lutimes @@ -236,7 +236,7 @@ __lxstat memalign mknod mknod64 mlock mlockall munlock munlockall nl_langinfo _open __open open64 _open64 __open64 _opendir __opendir opendir64 pathconf poll posix_fallocate posix_fallocate64 posix_memalign prctl pread _pread __pread pread64 _pread64 __pread64 -pututline pututxline pwrite _pwrite __pwrite pwrite64 _pwrite64 +pwrite _pwrite __pwrite pwrite64 _pwrite64 __pwrite64 rdchk _read __read _readdir __readdir readdir64 _readdir64 __readdir64 removeea removexattr rewinddir64 _seekdir __seekdir seekdir64 select setea setenv setgidx setgroups setlocale setluid @@ -245,7 +245,7 @@ setxattr shmget shm_open sigaction sigblock sigprocmask sigset sizeof_proplist_entry _stat __stat stat64 _stat64 __stat64 statvfs strcasecmp strchr strpbrk strsignal strtol strupr sysconf sysctlbyname __sys_llseek syslog _telldir __telldir telldir64 textdomain timegm -updwtmp updwtmpx utimensat vsyslog _write __write __xstat +utimensat vsyslog _write __write __xstat ''') conf.CHECK_TYPE('struct timespec', headers='sys/time.h time.h') @@ -500,6 +500,37 @@ return 0; conf.SET_TARGET_TYPE('gssapi', 'EMPTY') conf.SET_TARGET_TYPE('gssapi_krb5', 'EMPTY') +if Options.options.with_utmp: +conf.CHECK_FUNCS('pututline pututxline updwtmp updwtmpx getutmpx getutxent') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_name', headers='utmp.h', +define='HAVE_UT_UT_NAME') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_user', headers='utmp.h', +define='HAVE_UT_UT_USER') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_id', headers='utmp.h', +define='HAVE_UT_UT_ID') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_host', headers='utmp.h', +define='HAVE_UT_UT_HOST') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_time', headers='utmp.h', +define='HAVE_UT_UT_TIME') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_tv', headers='utmp.h', +define='HAVE_UT_UT_TV') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_type', headers='utmp.h', +define='HAVE_UT_UT_TYPE') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_pid', headers='utmp.h', +define='HAVE_UT_UT_PID') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_exit.e_exit', headers='utmp.h', +define='HAVE_UT_UT_EXIT') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_addr_v6', headers='utmp.h', +define='HAVE_UT_UT_ADDR_V6') +conf.CHECK_STRUCTURE_MEMBER('struct utmp', 'ut_addr', headers='utmp.h', +define='HAVE_UT_UT_ADDR') +conf.CHECK_STRUCTURE_MEMBER('struct utmpx', 'ut_syslen', headers='utmpx.h', +define='HAVE_UX_UT_SYSLEN') +conf.CHECK_CODE('struct utmp utarg; struct utmp *utreturn; utreturn = pututline(&utarg);', +'PUTUTLINE_RETURNS_UTMP', headers='utmp.h', +msg="Checking whether pututline returns pointer") +conf.DEFINE('WITH_UTMP', 1) + # FIXME: these should be tests for features, but the old build system just # checks for OSes. import sys -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 4eba4b0... s3-waf: Match the defines from the autotools build on PACKAGE_* from 93ac516... s3-auth: Added a function to get the server_info from the system user. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 4eba4b07c6645cf7748b827d7e37326383e91d7f Author: Kai Blin Date: Fri May 28 14:35:01 2010 +0200 s3-waf: Match the defines from the autotools build on PACKAGE_* --- Summary of changes: source3/wscript | 10 +- 1 files changed, 5 insertions(+), 5 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 7e39a60..73e00d1 100644 --- a/source3/wscript +++ b/source3/wscript @@ -53,12 +53,12 @@ def set_options(opt): def configure(conf): from samba_utils import TO_LIST -conf.DEFINE('PACKAGE_NAME', 'samba', quote=True) -conf.DEFINE('PACKAGE_STRING', 'Samba ' + version.STRING, quote=True) +conf.DEFINE('PACKAGE_NAME', 'Samba', quote=True) +conf.DEFINE('PACKAGE_STRING', 'Samba %s' % version.MAJOR, quote=True) conf.DEFINE('PACKAGE_TARNAME', 'samba', quote=True) -conf.DEFINE('PACKAGE_URL', "http://www.samba.org/";, quote=True) -conf.DEFINE('PACKAGE_VERSION', version.STRING, quote=True) -conf.DEFINE('PACKAGE_BUGREPORT', 'http://bugzilla.samba.org/', quote=True) +conf.DEFINE('PACKAGE_URL', "", quote=True) +conf.DEFINE('PACKAGE_VERSION', "%s" % version.MAJOR, quote=True) +conf.DEFINE('PACKAGE_BUGREPORT', 'samba-techni...@samba.org', quote=True) conf.DEFINE('CONFIG_H_IS_FROM_SAMBA', 1) conf.DEFINE('_SAMBA_BUILD_', version.MAJOR, add_to_cflags=True) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via d0e131e... s3-waf: Fix the smbclient build with libcap from 3d2c99f... s3-waf: Detect which version of krb5_enctype_to_string is used http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit d0e131ee4e3e1f35ebc33d6c1c27d5c9e69b8e87 Author: Kai Blin Date: Fri May 28 13:20:10 2010 +0200 s3-waf: Fix the smbclient build with libcap --- Summary of changes: source3/wscript_build |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index 66ee90a..770877e 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -950,7 +950,7 @@ bld.SAMBA_BINARY('web/swat', bld.SAMBA_BINARY('smbclient', source=CLIENT_SRC, - deps='''talloc tdb POPT_SAMBA PASSDB LIBSMB LIB_NONSMBD + deps='''talloc tdb cap POPT_SAMBA PASSDB LIBSMB LIB_NONSMBD PARAM_WITHOUT_REG LIBWBCLIENT DYNCONFIG''', vars=locals()) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 3d2c99f... s3-waf: Detect which version of krb5_enctype_to_string is used via da0e0ef... s3-waf: Fix the build of swat with --enable-cups from 76f804a... s4:client/client.c - we don't need "&ctx" for talloc calls http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 3d2c99f13b3b7f927ba3f912e8526f9e770aa34f Author: Kai Blin Date: Fri May 28 12:59:04 2010 +0200 s3-waf: Detect which version of krb5_enctype_to_string is used Pair-Programmed-With: Günther Deschner commit da0e0efe876fdc5e1fe96d1e3a88541006770ff0 Author: Kai Blin Date: Fri May 28 12:58:23 2010 +0200 s3-waf: Fix the build of swat with --enable-cups --- Summary of changes: source3/wscript | 24 source3/wscript_build |2 +- 2 files changed, 25 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 0911e85..7e39a60 100644 --- a/source3/wscript +++ b/source3/wscript @@ -471,6 +471,30 @@ pkdata = krb5_princ_component(context, principal, 0); headers='krb5.h', lib='krb5', msg="Checking whether krb5_princ_component is available") +conf.CHECK_CODE(''' +int main(void) { +char buf[256]; +krb5_enctype_to_string(1, buf, 256); +return 0; +}''', +'HAVE_KRB5_ENCTYPE_TO_STRING_WITH_SIZE_T_ARG', +headers='krb5.h', lib='krb5', +addmain=False, cflags='-Werror', +msg="Checking whether krb5_enctype_to_string takes size_t argument") + +conf.CHECK_CODE(''' +int main(void) { +krb5_context context = NULL; +char *str = NULL; +krb5_enctype_to_string(context, 1, &str); +if (str) free (str); +return 0; +}''', +'HAVE_KRB5_ENCTYPE_TO_STRING_WITH_KRB5_CONTEXT_ARG', +headers='krb5.h stdlib.h', lib='krb5', +addmain=False, cflags='-Werror', +msg="Checking whether krb5_enctype_to_string takes krb5_context argument") + else: conf.SET_TARGET_TYPE('krb5', 'EMPTY') conf.SET_TARGET_TYPE('gssapi', 'EMPTY') diff --git a/source3/wscript_build b/source3/wscript_build index c45f62b..66ee90a 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -943,7 +943,7 @@ bld.SAMBA_BINARY('winbindd/winbindd', bld.SAMBA_BINARY('web/swat', source=SWAT_SRC, deps='''talloc tevent cap DYNCONFIG LIBS LIBSMB LIBWBCLIENT PARAM - LIB_NONSMBD resolv PASSDB POPT_SAMBA KRBCLIENT''', + LIB_NONSMBD resolv PASSDB POPT_SAMBA KRBCLIENT cups''', enabled=bld.env.build_swat, install_path='${SBINDIR}', vars=locals()) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 49a80fe... s3-waf: Fix typo from 21e8548... s3-waf: Also set "developer" env when building in developer mode http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 49a80fe6710a8c3c5977b35be2f55c2748b3bddc Author: Kai Blin Date: Thu May 27 22:45:13 2010 +0200 s3-waf: Fix typo Sorry for the noise --- Summary of changes: source3/wscript |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 6dc05c8..c3d4c43 100644 --- a/source3/wscript +++ b/source3/wscript @@ -61,7 +61,7 @@ def configure(conf): conf.DEFINE('HAVE_CONFIG_H', 1, add_to_cflags=True) if Options.options.developer: conf.ADD_CFLAGS('-DDEVELOPER -DDEBUG_PASSWORD') -conv.env['developer'] = True +conf.env['developer'] = True if Options.options.with_swat: conf.env['build_swat'] = True -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 21e8548... s3-waf: Also set "developer" env when building in developer mode from abbf8ef... s3: Fix a bad memleak in the async echo responder http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 21e8548c0a3ea8fcca4e97a9b0f8b5a2cddf3d29 Author: Kai Blin Date: Thu May 27 22:42:23 2010 +0200 s3-waf: Also set "developer" env when building in developer mode --- Summary of changes: source3/wscript |1 + 1 files changed, 1 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 3bc9bd1..6dc05c8 100644 --- a/source3/wscript +++ b/source3/wscript @@ -61,6 +61,7 @@ def configure(conf): conf.DEFINE('HAVE_CONFIG_H', 1, add_to_cflags=True) if Options.options.developer: conf.ADD_CFLAGS('-DDEVELOPER -DDEBUG_PASSWORD') +conv.env['developer'] = True if Options.options.with_swat: conf.env['build_swat'] = True -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 83b2fd3... s3-waf: Build smbclient binary via 59f3c4e... s3-waf: Fix the naming of some variables introduced recently from c2021e4... s4/test: Connect SAMR and LDARPC pipes before calling libnet_ functions http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 83b2fd30215c5286f0f05bddce76bd5e0959c5c8 Author: Kai Blin Date: Wed May 26 14:09:39 2010 +0200 s3-waf: Build smbclient binary commit 59f3c4ec591e21235650e7e8bfae2540e423c533 Author: Kai Blin Date: Wed May 26 14:09:06 2010 +0200 s3-waf: Fix the naming of some variables introduced recently --- Summary of changes: source3/wscript_build | 21 +++-- 1 files changed, 19 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript_build b/source3/wscript_build index 2c74bf1..cbe2cbb 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -304,7 +304,7 @@ LIBMSRPC_GEN_SRC = '''../librpc/gen_ndr/cli_lsa.c # registry-related objects # UTIL_REG_SRC = '''../libcli/registry/util_reg.c''' -REG_UTIL_MARSHALLING_OBJ = '''registry/reg_util_marshalling.c''' +REG_UTIL_MARSHALLING_SRC = '''registry/reg_util_marshalling.c''' REG_INIT_BASIC_SRC = '''registry/reg_init_basic.c''' REG_INIT_SMBCONF_SRC = '''registry/reg_init_smbconf.c''' @@ -333,7 +333,7 @@ REG_BASE_SRC = '''registry/reg_api.c ${REGFIO_SRC} ${REGSRCS_SRC} registry/reg_util_internal.c - ${REG_UTIL_MARSHALLING_OBJ} + ${REG_UTIL_MARSHALLING_SRC} lib/util_nttoken.c ${REG_BACKENDS_BASE_SRC} ${REG_INIT_BASIC_SRC}''' @@ -771,6 +771,17 @@ EVTLOGADM_SRC = '''${EVTLOGADM_SRC0} ../librpc/gen_ndr/ndr_eventlog.c ../librpc/gen_ndr/ndr_lsa.c''' +DISPLAY_SEC_SRC= '../libcli/security/display_sec.c' + +CLIENT_SRC1 = '''client/client.c client/clitar.c ${RPC_CLIENT_SRC} + ../librpc/rpc/binding.c client/dnsbrowse.c + ${RPC_CLIENT_SRC1} ${RPC_PARSE_SRC2}''' + +CLIENT_SRC = '''${CLIENT_SRC1} ${PARAM_SRC} + ${KRBCLIENT_SRC} ${LIBMSRPC_GEN_SRC} +${READLINE_SRC} ${DISPLAY_SEC_SRC}''' + + LIBS='ICONV' bld.SAMBA_GENERATOR('build_options', @@ -934,6 +945,12 @@ bld.SAMBA_BINARY('web/swat', install_path='${SBINDIR}', vars=locals()) +bld.SAMBA_BINARY('smbclient', + source=CLIENT_SRC, + deps='''talloc tdb POPT_SAMBA PASSDB LIBSMB LIB_NONSMBD + PARAM_WITHOUT_REG LIBWBCLIENT DYNCONFIG''', + vars=locals()) + bld.SAMBA_BINARY('wbinfo', source=WBINFO_SRC, deps='''talloc LIBWBCLIENT DYNCONFIG tevent cap -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 9e194cd... s3-waf: Check for additional options on *xattr via 5a023e7... s3-waf: Add darwin to the host_os-specific checks via b2546ee... s3-waf: Don't hardcode the name of the awk executable in wscript_build from 475531c... Standardize debug messages for read and write. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 9e194cd673a0d0a56cd064bab38cbf30b468999d Author: Kai Blin Date: Wed May 26 00:16:10 2010 +0200 s3-waf: Check for additional options on *xattr commit 5a023e73f7b1e788b49a05318b8de264aca085f0 Author: Kai Blin Date: Tue May 25 23:57:41 2010 +0200 s3-waf: Add darwin to the host_os-specific checks commit b2546ee5571e644d3cb784f33517bf9f28c134d7 Author: Kai Blin Date: Tue May 25 23:53:04 2010 +0200 s3-waf: Don't hardcode the name of the awk executable in wscript_build --- Summary of changes: source3/wscript | 10 ++ source3/wscript_build |2 -- 2 files changed, 10 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 08044ec..166f7c5 100644 --- a/source3/wscript +++ b/source3/wscript @@ -323,6 +323,14 @@ updwtmp updwtmpx utimensat vsyslog _write __write __xstat conf.env.build_winbind = True conf.DEFINE('WITH_WINBIND', '1') +conf.find_program('awk', var='AWK') + +# Darwin has extra options to xattr-family functions +conf.CHECK_CODE('getxattr(0, 0, 0, 0, 0, 0);', +'XATTR_ADD_OPT', +msg="Checking whether xattr interface takes additional options", +headers='sys/types.h attr/xattr.h sys/xattr.h') + #FIXME: Should just be set when krb5 and ldap requirements are fulfilled if Options.options.with_ads: conf.DEFINE('WITH_ADS', '1') @@ -438,6 +446,8 @@ krb5_get_credentials_for_user krb5_get_host_realm krb5_free_host_realm''', elif host_os.rfind('qnx') > -1: conf.DEFINE('QNX', '1') conf.DEFINE('STAT_ST_BLOCKSIZE', '512') +elif (host_os.rfind('darwin') > -1): +conf.DEFINE('STAT_ST_BLOCKSIZE', '512') # FIXME: Add more checks here. else: print "Unknown host_os '%s', please report this to samba-techni...@samba.org" % host_os diff --git a/source3/wscript_build b/source3/wscript_build index 72ff748..2c74bf1 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -773,8 +773,6 @@ EVTLOGADM_SRC = '''${EVTLOGADM_SRC0} LIBS='ICONV' -bld.env.AWK = 'gawk' - bld.SAMBA_GENERATOR('build_options', source='include/config.h script/mkbuildoptions.awk', target='smbd/build_options.c', -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 136ea7b... s3-waf: Actually make --with/--without-swat work via c926acf... s3-waf: Really disable winbindd build when --without-winbind is specified from 2bbf055... Make -k a simple non-bool option. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 136ea7b91d0a712bf78ee325f06ab2d75f712507 Author: Kai Blin Date: Thu May 20 23:05:21 2010 +0200 s3-waf: Actually make --with/--without-swat work commit c926acf7f1b49191b18f04a9caf484d8ef1033b9 Author: Kai Blin Date: Thu May 20 22:58:59 2010 +0200 s3-waf: Really disable winbindd build when --without-winbind is specified --- Summary of changes: source3/wscript |4 source3/wscript_build |4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/wscript b/source3/wscript index 30736ad..a58c524 100644 --- a/source3/wscript +++ b/source3/wscript @@ -62,6 +62,9 @@ def configure(conf): if Options.options.developer: conf.ADD_CFLAGS('-DDEVELOPER -DDEBUG_PASSWORD') +if Options.options.with_swat: +conf.env['build_swat'] = True + # set a limit on recursing in the waf preprocessor conf.env.preprocessor_recursion_limit = 10 @@ -317,6 +320,7 @@ updwtmp updwtmpx utimensat vsyslog _write __write __xstat conf.env[shared_env].append('%s' % entry.upper()) if Options.options.with_winbind: +conf.env.build_winbind = True conf.DEFINE('WITH_WINBIND', '1') #FIXME: Should just be set when krb5 and ldap requirements are fulfilled diff --git a/source3/wscript_build b/source3/wscript_build index 222dab6..636091e 100644 --- a/source3/wscript_build +++ b/source3/wscript_build @@ -923,7 +923,7 @@ bld.SAMBA_BINARY('winbindd/winbindd', deps='''talloc tdb tevent cap dl DYNCONFIG ZLIB NSS_WRAPPER LIBWBCLIENT PASSDB ldap resolv PARAM LIB_NONSMBD LIBSMB POPT_SAMBA KRBCLIENT''', - enabled=Options.options.with_winbind, + enabled=bld.env.build_winbind, install_path='${SBINDIR}', vars=locals()) @@ -931,7 +931,7 @@ bld.SAMBA_BINARY('web/swat', source=SWAT_SRC, deps='''talloc tevent cap DYNCONFIG LIBS LIBSMB LIBWBCLIENT PARAM LIB_NONSMBD resolv PASSDB POPT_SAMBA KRBCLIENT''', - enabled=Options.options.with_swat, + enabled=bld.env.build_swat, install_path='${SBINDIR}', vars=locals()) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
at need to be set by configure options later via a967dea... s3-waf: Add more objects trying to build smbd via 5f87d5a... s3-waf: Added support dynconfig cflags from a8a4fe0... Fix bug #7410 - samba sends "raw" inode number as uniqueid with unix extensions. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 29f549e3fb62b8b431aea5f9e53fc916ff12 Author: Kai Blin Date: Thu May 20 22:30:24 2010 +0200 s3-waf: ndr string functions moved to top level commit aca2b5461c47e6bb6449d7b09e36faa0025bb912 Author: Kai Blin Date: Thu May 20 10:24:37 2010 +0200 s3-waf: Fix the build after rebase commit 73f6fed4d61f69cbbbd911e3c5549f39cea05ac7 Author: Kai Blin Date: Fri May 14 11:03:19 2010 +0200 s3-waf: more elaborate host_os check for STAT_ST_BLOCKSIZE commit 9ab33162503ea5965cd7f34a9b5b9c1f13e75d0c Author: Michael Adam Date: Wed May 12 23:48:10 2010 +0200 s3-waf: fix linking of eventlogadm by adding cap as dependency commit f35bafe39c9aac0c156636965bffa1ebe0b39225 Author: Michael Adam Date: Wed May 12 23:47:36 2010 +0200 s3-waf: fix linking of swat by adding cap as dependency commit c33ba1f9d1a5af5a2055cc28cd859bef75fa7eba Author: Kai Blin Date: Wed May 12 22:43:18 2010 +0200 s3-waf: Fix build with ldap by adding a SMBLDAP subsystem commit 17b136a79f94be5133e1fc93e31001fb102e6d2e Author: Kai Blin Date: Wed May 12 05:39:00 2010 -0600 s3-waf: fix the winbindd build again commit b6c5d5de379de1e1e5ada78021b3defba3ca3194 Author: Kai Blin Date: Wed May 12 05:23:27 2010 -0600 s3-waf: Fix up PIDL includes. Pair-Programmed-With: Stefan Metzmacher commit 9cc39ffb5673e17be78d3986c0cc56e4f1a2af32 Author: Kai Blin Date: Wed May 12 04:32:30 2010 -0600 s3-waf: Some files moved during the rebase commit 5556deee7aabda43ee258d84670fcb9635632a47 Author: Stefan Metzmacher Date: Wed May 12 04:31:27 2010 -0600 s3-waf: Add autogeneration with PIDL commit d704d5295461a2d287f3d69b43d355fc4cfa1489 Author: Kai Blin Date: Wed May 12 04:27:49 2010 -0600 s3-waf: Remove references to LDB Pair-Programmed-With: Stefan Metzmacher commit 1c6ba8551d74a469c80fdc666a8c795bd3a7bf52 Author: Stefan Metzmacher Date: Wed May 12 04:23:10 2010 -0600 s3-waf: Also include source4/ when looking for headers commit 8e04ad2db1e3071e3297a315021fc5158134f575 Author: Kai Blin Date: Tue May 11 17:44:25 2010 +0200 s3-waf: build shared modules as subsystems commit 2650198ff70320cc9f251f2ce881c25932bc0e95 Author: Kai Blin Date: Tue May 11 17:14:54 2010 +0200 s3-waf: autogenerate lists of static modules commit e48b73fc67e7e57d6944722adf738bcc923cf1a6 Author: Kai Blin Date: Tue May 11 17:13:05 2010 +0200 s3-waf: clean up includes commit 3ea211feb4b77633e22ecd09c8d653ccf892ec9f Author: Kai Blin Date: Tue May 11 17:11:41 2010 +0200 s3-waf: create a SECRETS subsystem commit 1e97982633a4a7652d7481a0e888de4fe85c7791 Author: Kai Blin Date: Tue May 11 15:24:13 2010 +0200 s3-waf: clean up dependencies a little commit 997114564d1d8ec9e6f79be6e0cd557e34d04cb6 Author: Kai Blin Date: Tue May 11 15:23:37 2010 +0200 s3-waf: tdb includes are in lib/tdb/include commit 6a32dbd857b892a1c71130fdcb58ec53d06ea4ef Author: Kai Blin Date: Tue May 11 15:00:43 2010 +0200 s3-waf: fix eventlogadm build with winbind commit 0e7e0397780a13b13649c910fe77709e4feedcf0 Author: Kai Blin Date: Tue May 11 10:32:07 2010 +0200 s3-waf: Autogenerate the static and dynamic init function calls commit 25f33a3f8e92e2687db782b56ad794e8dee02986 Author: Kai Blin Date: Tue May 11 10:31:22 2010 +0200 s3-waf: add popt and tdb include dirs to the includes list commit 63a30619b63d17347eda1c13e56ec200fa1ce853 Author: Kai Blin Date: Tue May 11 10:30:25 2010 +0200 s3-waf: Fix up the winbindd build commit 015c09031e48877bda9b15d9334846d7fd43c98e Author: Kai Blin Date: Fri Apr 30 19:45:06 2010 +0200 s3-waf: add eventlogadm binary commit 07661287648e4764a0babf6f571e695c61957b41 Author: Kai Blin Date: Fri Apr 30 14:43:57 2010 +0200 s3-waf: Use a common subsystem for the kerberos client code commit 149167f5748860e6795d11c6aceeb0149101d241 Author: Kai Blin Date: Fri Apr 30 14:33:49 2010 +0200 s3-waf: Use a common subsystem for samba-popt code commit f242a31a43a0ff2d0be84553aca5e159aa138905 Author: Kai Blin Date: Fri Apr 30 14:22:06 2010 +0200 s3-waf: note that the options are broken commit b2431163fccb996b390acbfd65d29d39f92b4679 Author: Kai Blin Date: Fri Apr 30 14:21:28 2010 +0200 s3-waf: replace all - with _ in the configuration option names commit be712a8eea486d493d6e0c924d1d8e13312a52af Author: Kai Blin Date: Fri Apr 30 14:18:20 2010 +0200 s3-waf: Build swat commit 8f9a3c9eb2b79539d04c59ed4a5a570c692cd63c Author: Kai Blin Date: Fri Apr 30 14:17:30
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 29629b9... s3 smb2: Fix the build without kerberos from 33c96e6... s3-net: Created a migration tool for printing TDBs. http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 29629b93907fd32e48d347c109333e9c0ad244eb Author: Kai Blin Date: Thu May 20 11:29:03 2010 +0200 s3 smb2: Fix the build without kerberos Jeremy, please check --- Summary of changes: source3/smbd/smb2_sesssetup.c |2 ++ 1 files changed, 2 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/smbd/smb2_sesssetup.c b/source3/smbd/smb2_sesssetup.c index 9662894..ed58189 100644 --- a/source3/smbd/smb2_sesssetup.c +++ b/source3/smbd/smb2_sesssetup.c @@ -143,6 +143,7 @@ static int smbd_smb2_session_destructor(struct smbd_smb2_session *session) return 0; } +#ifdef HAVE_KRB5 static NTSTATUS smbd_smb2_session_setup_krb5(struct smbd_smb2_session *session, struct smbd_smb2_request *smb2req, uint8_t in_security_mode, @@ -511,6 +512,7 @@ static NTSTATUS smbd_smb2_session_setup_krb5(struct smbd_smb2_session *session, data_blob_free(&secblob_out); return status; } +#endif static NTSTATUS smbd_smb2_spnego_negotiate(struct smbd_smb2_session *session, struct smbd_smb2_request *smb2req, -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 765e9c7... wbinfo: Add better libwbclient error reporting from b05faff... added documentation for the -I flag http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 765e9c7c67058271365521ce415b2ec1483e3c3d Author: Kai Blin Date: Mon May 17 10:50:39 2010 +0200 wbinfo: Add better libwbclient error reporting --- Summary of changes: nsswitch/wbinfo.c | 104 +++-- 1 files changed, 101 insertions(+), 3 deletions(-) Changeset truncated at 500 lines: diff --git a/nsswitch/wbinfo.c b/nsswitch/wbinfo.c index e576309..3c1db8b 100644 --- a/nsswitch/wbinfo.c +++ b/nsswitch/wbinfo.c @@ -47,7 +47,7 @@ static struct wbcInterfaceDetails *init_interface_details(void) wbc_status = wbcInterfaceDetails(&details); if (!WBC_ERROR_IS_OK(wbc_status)) { d_fprintf(stderr, "could not obtain winbind interface " - "details!\n"); + "details: %s\n", wbcErrorString(wbc_status)); } return details; @@ -172,6 +172,8 @@ static bool wbinfo_get_userinfo(char *user) wbc_status = wbcGetpwnam(user, &pwd); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcGetpwnam: %s", + wbcErrorString(wbc_status)); return false; } @@ -195,6 +197,8 @@ static bool wbinfo_get_uidinfo(int uid) wbc_status = wbcGetpwuid(uid, &pwd); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcGetpwuid: %s", + wbcErrorString(wbc_status)); return false; } @@ -219,6 +223,8 @@ static bool wbinfo_get_user_sidinfo(const char *sid_str) wbc_status = wbcStringToSid(sid_str, &sid); wbc_status = wbcGetpwsid(&sid, &pwd); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcGetpwsid: %s", + wbcErrorString(wbc_status)); return false; } @@ -244,6 +250,8 @@ static bool wbinfo_get_groupinfo(const char *group) wbc_status = wbcGetgrnam(group, &grp); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcGetgrnam: %s", + wbcErrorString(wbc_status)); return false; } @@ -273,6 +281,8 @@ static bool wbinfo_get_gidinfo(int gid) wbc_status = wbcGetgrgid(gid, &grp); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcGetgrgid: %s", + wbcErrorString(wbc_status)); return false; } @@ -306,6 +316,8 @@ static bool wbinfo_get_usergroups(const char *user) wbc_status = wbcGetGroups(user, &num_groups, &groups); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcGetGroups: %s", + wbcErrorString(wbc_status)); return false; } @@ -331,11 +343,15 @@ static bool wbinfo_get_usersids(const char *user_sid_str) wbc_status = wbcStringToSid(user_sid_str, &user_sid); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcStringToSid: %s", + wbcErrorString(wbc_status)); return false; } wbc_status = wbcLookupUserSids(&user_sid, false, &num_sids, &sids); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcLookupUserSids: %s", + wbcErrorString(wbc_status)); return false; } @@ -343,6 +359,8 @@ static bool wbinfo_get_usersids(const char *user_sid_str) char *str = NULL; wbc_status = wbcSidToString(&sids[i], &str); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcSidToString: %s", + wbcErrorString(wbc_status)); wbcFreeMemory(sids); return false; } @@ -366,11 +384,15 @@ static bool wbinfo_get_userdomgroups(const char *user_sid_str) wbc_status = wbcStringToSid(user_sid_str, &user_sid); if (!WBC_ERROR_IS_OK(wbc_status)) { + d_fprintf(stderr, "failed to call wbcSidToString: %s", + wbcErrorString(wbc_status)); return false; } wbc_status = wbcLookupUserSids(&us
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via eda5888... build: skip missing executables in testwaf.sh from 2eab1d7... tdb: remove unused variable in tdb_new_database(). http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit eda58884928845702e210afd75d0c0ece8f3dbfe Author: Kai Blin Date: Tue May 11 14:24:47 2010 +0200 build: skip missing executables in testwaf.sh --- Summary of changes: buildtools/testwaf.sh | 14 -- 1 files changed, 12 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/buildtools/testwaf.sh b/buildtools/testwaf.sh index 7a3f1bf..a9a17cf 100755 --- a/buildtools/testwaf.sh +++ b/buildtools/testwaf.sh @@ -48,6 +48,11 @@ echo "testing python portability" pushd lib/talloc versions="python2.4 python2.5 python2.6 python3.0 python3.1" for p in $versions; do +ret=$(which $p || echo "failed") +if [ $ret == "failed" ]; then +echo "$p not found, skipping" +continue +fi echo "Testing $p" $p ../../buildtools/bin/waf configure -C --enable-developer --prefix=$PREFIX $p ../../buildtools/bin/waf build install @@ -56,6 +61,11 @@ popd echo "testing cross compiling" pushd lib/talloc -CC=arm-linux-gnueabi-gcc ./configure -C --prefix=$PREFIX --cross-compile --cross-execute='runarm' -make && make install +ret=$(which arm-linux-gnueabi-gcc || echo "failed") +if [ $ret != "failed" ]; then +CC=arm-linux-gnueabi-gcc ./configure -C --prefix=$PREFIX --cross-compile --cross-execute='runarm' +make && make install +else +echo "Cross-compiler not installed, skipping test" +fi popd -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 7c68512... build: Update the waf build to fix python header checks from e4ce727... s3:provision_basedn_modify.ldif - add "msDS-NcType" attribute and fix comments http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 7c68512a216c63eb151bd8600c4aa5d1ad1bc729 Author: Kai Blin Date: Mon May 10 09:58:57 2010 +0200 build: Update the waf build to fix python header checks --- Summary of changes: buildtools/bin/waf-svn | Bin 107924 -> 107944 bytes 1 files changed, 0 insertions(+), 0 deletions(-) Changeset truncated at 500 lines: diff --git a/buildtools/bin/waf-svn b/buildtools/bin/waf-svn index 25f0406..64c653c 100755 Binary files a/buildtools/bin/waf-svn and b/buildtools/bin/waf-svn differ -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated
The branch, master has been updated via 8208f8e... s3 i18n: Fix up missing newlines in more pam_winbind translations from e56dc83... s3 i18n: Fix up missing newlines in pam_winbind translations http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 8208f8e5e53f59866949b6169bc107f8f17e7a0e Author: Kai Blin Date: Mon Apr 19 09:27:50 2010 +0200 s3 i18n: Fix up missing newlines in more pam_winbind translations --- Summary of changes: source3/locale/pam_winbind/ko.po|4 ++-- source3/locale/pam_winbind/nb.po|4 ++-- source3/locale/pam_winbind/nl.po|4 ++-- source3/locale/pam_winbind/pl.po|4 ++-- source3/locale/pam_winbind/pt_BR.po |4 ++-- source3/locale/pam_winbind/ru.po|4 ++-- source3/locale/pam_winbind/sv.po|4 ++-- source3/locale/pam_winbind/zh_CN.po |4 ++-- source3/locale/pam_winbind/zh_TW.po |4 ++-- 9 files changed, 18 insertions(+), 18 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/locale/pam_winbind/ko.po b/source3/locale/pam_winbind/ko.po index bd169f9..733d408 100644 --- a/source3/locale/pam_winbind/ko.po +++ b/source3/locale/pam_winbind/ko.po @@ -85,12 +85,12 @@ msgstr "ì§ê¸ ë¹ë°ë²í¸ë¥¼ ë³ê²½í´ì¼ í©ëë¤." #: ../../../nsswitch/pam_winbind.c:902 #, fuzzy msgid "Your password expires today.\n" -msgstr "ì¤ë ë¹ë°ë²í¸ê° ë§ë£ë©ëë¤." +msgstr "ì¤ë ë¹ë°ë²í¸ê° ë§ë£ë©ëë¤.\n" #: ../../../nsswitch/pam_winbind.c:932 #, fuzzy, c-format msgid "Your password will expire in %d %s.\n" -msgstr "ë¹ë°ë²í¸ê° %d %sì¼ íì ë§ë£ë©ëë¤." +msgstr "ë¹ë°ë²í¸ê° %d %sì¼ íì ë§ë£ë©ëë¤.\n" #: ../../../nsswitch/pam_winbind.c:933 msgid "days" diff --git a/source3/locale/pam_winbind/nb.po b/source3/locale/pam_winbind/nb.po index 3e505d4..9559699 100644 --- a/source3/locale/pam_winbind/nb.po +++ b/source3/locale/pam_winbind/nb.po @@ -90,12 +90,12 @@ msgstr "Du mÃ¥ endre passordet nÃ¥" #: ../../../nsswitch/pam_winbind.c:902 #, fuzzy msgid "Your password expires today.\n" -msgstr "Passordet utløper i dag" +msgstr "Passordet utløper i dag.\n" #: ../../../nsswitch/pam_winbind.c:932 #, fuzzy, c-format msgid "Your password will expire in %d %s.\n" -msgstr "Passordet vil utløpe om %d %s" +msgstr "Passordet vil utløpe om %d %s.\n" #: ../../../nsswitch/pam_winbind.c:933 msgid "days" diff --git a/source3/locale/pam_winbind/nl.po b/source3/locale/pam_winbind/nl.po index e7f1157..f0cbfda 100644 --- a/source3/locale/pam_winbind/nl.po +++ b/source3/locale/pam_winbind/nl.po @@ -85,12 +85,12 @@ msgstr "U moet uw wachtwoord nu wijzigen" #: ../../../nsswitch/pam_winbind.c:902 #, fuzzy msgid "Your password expires today.\n" -msgstr "Uw wachtwoord verloopt vandaag" +msgstr "Uw wachtwoord verloopt vandaag.\n" #: ../../../nsswitch/pam_winbind.c:932 #, fuzzy, c-format msgid "Your password will expire in %d %s.\n" -msgstr "Uw wachtwoord verloopt over %d %s" +msgstr "Uw wachtwoord verloopt over %d %s.\n" #: ../../../nsswitch/pam_winbind.c:933 msgid "days" diff --git a/source3/locale/pam_winbind/pl.po b/source3/locale/pam_winbind/pl.po index 0f1dbf6..05d069d 100644 --- a/source3/locale/pam_winbind/pl.po +++ b/source3/locale/pam_winbind/pl.po @@ -85,12 +85,12 @@ msgstr "Zmiana hasÅa jest wymagana w tej chwili" #: ../../../nsswitch/pam_winbind.c:902 #, fuzzy msgid "Your password expires today.\n" -msgstr "HasÅo użytkownika wygasa dzisiaj" +msgstr "HasÅo użytkownika wygasa dzisiaj.\n" #: ../../../nsswitch/pam_winbind.c:932 #, fuzzy, c-format msgid "Your password will expire in %d %s.\n" -msgstr "HasÅo użytkownika wygaÅnie za %d %s." +msgstr "HasÅo użytkownika wygaÅnie za %d %s.\n" #: ../../../nsswitch/pam_winbind.c:933 msgid "days" diff --git a/source3/locale/pam_winbind/pt_BR.po b/source3/locale/pam_winbind/pt_BR.po index 418cc80..6736a22 100644 --- a/source3/locale/pam_winbind/pt_BR.po +++ b/source3/locale/pam_winbind/pt_BR.po @@ -85,12 +85,12 @@ msgstr "Você precisa alterar sua senha agora" #: ../../../nsswitch/pam_winbind.c:902 #, fuzzy msgid "Your password expires today.\n" -msgstr "Sua senha expira hoje" +msgstr "Sua senha expira hoje.\n" #: ../../../nsswitch/pam_winbind.c:932 #, fuzzy, c-format msgid "Your password will expire in %d %s.\n" -msgstr "Sua senha expirará em %d %s." +msgstr "Sua senha expirará em %d %s.\n" #: ../../../nsswitch/pam_winbind.c:933 msgid "d