[SCM] Samba Shared Repository - branch master updated

2012-09-06 Thread Andrew Bartlett
The branch, master has been updated
   via  baf2db6 selftest: Test configure stage of dlz_bind9
   via  52f0ded selftest: Add tests for the dlz_bind9 module
  from  0d99175 join.py: Only replicate DNS zones if the source DC had DNS 
zones

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit baf2db685f1d2bff712d45288abf116f903039ed
Author: Andrew Bartlett 
Date:   Thu Sep 6 15:22:17 2012 +1000

selftest: Test configure stage of dlz_bind9

Autobuild-User(master): Andrew Bartlett 
Autobuild-Date(master): Thu Sep  6 09:07:11 CEST 2012 on sn-devel-104

commit 52f0dedc1a63c75f87adc0f70f10aae2b2bfaf72
Author: Andrew Bartlett 
Date:   Thu Sep 6 14:26:57 2012 +1000

selftest: Add tests for the dlz_bind9 module

This will help ensure that we do not break the fundemental loading etc.

From here, it should be easy to extend this to more comprehensive tests.

Andrew Bartlett

---

Summary of changes:
 source4/dns_server/wscript_build  |7 ++
 source4/selftest/tests.py |4 +
 source4/torture/dns/dlz_bind9.c   |  152 +
 source4/torture/dns/wscript_build |   10 +++
 source4/torture/wscript_build |1 +
 5 files changed, 174 insertions(+), 0 deletions(-)
 create mode 100644 source4/torture/dns/dlz_bind9.c
 create mode 100644 source4/torture/dns/wscript_build


Changeset truncated at 500 lines:

diff --git a/source4/dns_server/wscript_build b/source4/dns_server/wscript_build
index b8e2708..280f8de 100644
--- a/source4/dns_server/wscript_build
+++ b/source4/dns_server/wscript_build
@@ -30,3 +30,10 @@ bld.SAMBA_LIBRARY('dlz_bind9_9',
   install_path='${MODULESDIR}/bind9',
   deps='samba-hostconfig samdb-common gensec popt',
   enabled=bld.AD_DC_BUILD_IS_ENABLED())
+
+bld.SAMBA_LIBRARY('dlz_bind9_for_torture',
+  source='dlz_bind9.c',
+  cflags='-DBIND_VERSION_9_8',
+  private_library=True,
+  deps='samba-hostconfig samdb-common gensec popt',
+  enabled=bld.AD_DC_BUILD_IS_ENABLED())
diff --git a/source4/selftest/tests.py b/source4/selftest/tests.py
index b9944cb..fd4b669 100755
--- a/source4/selftest/tests.py
+++ b/source4/selftest/tests.py
@@ -296,6 +296,10 @@ for f in sorted(os.listdir(os.path.join(samba4srcdir, 
"../pidl/tests"))):
 
 # DNS tests
 planpythontestsuite("dc", "samba.tests.dns")
+# Local tests
+for t in smb4torture_testsuites("dlz_bind9."):
+#The dlz_bind9 tests needs to look at the DNS database
+plansmbtorturetestsuite(t, "dc:local", "ncalrpc:localhost")
 
 planpythontestsuite("s3dc", "samba.tests.libsmb_samba_internal");
 
diff --git a/source4/torture/dns/dlz_bind9.c b/source4/torture/dns/dlz_bind9.c
new file mode 100644
index 000..d01e506
--- /dev/null
+++ b/source4/torture/dns/dlz_bind9.c
@@ -0,0 +1,152 @@
+/*
+   Unix SMB/CIFS implementation.
+   SMB torture tester
+   Copyright (C) Andrew Bartlett 2012
+
+   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 .
+*/
+
+#include "includes.h"
+#include "torture/smbtorture.h"
+#include "dlz_minimal.h"
+#include 
+#include 
+#include "lib/param/param.h"
+#include "dsdb/samdb/samdb.h"
+#include "dsdb/common/util.h"
+#include "auth/session.h"
+
+struct torture_context *tctx_static;
+
+static void dlz_bind9_log_wrapper(int level, const char *fmt, ...)
+{
+   va_list ap;
+   char *msg;
+   va_start(ap, fmt);
+   msg = talloc_vasprintf(NULL, fmt, ap);
+   torture_comment(tctx_static, "%s\n", msg);
+   TALLOC_FREE(msg);
+   va_end(ap);
+}
+
+static bool test_dlz_bind9_version(struct torture_context *tctx)
+{
+   unsigned int flags = 0;
+   torture_assert_int_equal(tctx, dlz_version(&flags),
+DLZ_DLOPEN_VERSION, "got wrong DLZ version");
+   return true;
+}
+
+static bool test_dlz_bind9_create(struct torture_context *tctx)
+{
+   void *dbdata;
+   const char *argv[] = {
+   "samba_dlz",
+   "-H",
+   lpcfg_private_path(tctx, tctx->lp_ctx, "dns/sam.ldb"),
+   NULL
+   };
+   tctx_static = tctx;
+   torture_assert_int_equal(tctx, dlz_create("samba_d

[SCM] Samba Shared Repository - branch master updated

2012-09-06 Thread Björn Jacke
The branch, master has been updated
   via  146ad30 s3-smbd: Remove remaining references to removed OS support 
in old-style quota code
   via  9bfab7e s3-smbd: Remove IRIX support from old (pre-sysquotas) code
   via  79bc9e5 s3-smbd: Remove HPUX support from old (pre-sysquotas) code
   via  8b90f6a s3-smbd: Remove BSD support from old (pre-sysquotas) code
   via  28ccb67 s3-smbd: Remove Linux support from old (pre-sysquotas) code
   via  040a458 s3-configure: Only use sysquotas by default
   via  24013bd build: Remove Unicos support (quota in particular)
   via  b7b0d7d build: Do not compile lib/sysquotas*.c files as part of 
configure
   via  82cffc2 s3: Fix 64-bit warnings in vfs_media_harmony
   via  a6df44b sysquota: we need to list nfs4 as a separate fs name for 
the sys_get_nfs_quota backend
  from  baf2db6 selftest: Test configure stage of dlz_bind9

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 146ad30387ebfeaa0269a26b1c5ee32ed13e095e
Author: Andrew Bartlett 
Date:   Mon Sep 3 13:16:38 2012 +1000

s3-smbd: Remove remaining references to removed OS support in old-style 
quota code

Signed-off-by: Björn Jacke 

Autobuild-User(master): Björn Jacke 
Autobuild-Date(master): Thu Sep  6 10:47:18 CEST 2012 on sn-devel-104

commit 9bfab7ec8cfb01f102e8e22b7f94cd772a8b5a00
Author: Andrew Bartlett 
Date:   Mon Sep 3 12:20:53 2012 +1000

s3-smbd: Remove IRIX support from old (pre-sysquotas) code

This should be essentially dead code, as while it is possible to disable 
sysquotas, the sysquotas has since 2003 supported the 4A varient used on IRIX.

Andrew Bartlett

Signed-off-by: Björn Jacke 

commit 79bc9e5ace576e67ec14132b9b0c892c642cc98f
Author: Andrew Bartlett 
Date:   Mon Sep 3 02:20:05 2012 +1000

s3-smbd: Remove HPUX support from old (pre-sysquotas) code

This should be essentially dead code, as while it is possible to disable 
sysquotas, the sysquotas has since 2003 supported the 4A varient used on HPUX.

Andrew Bartlett

Signed-off-by: Björn Jacke 

commit 8b90f6ace30609b320cc306282488b8ee8397d7b
Author: Andrew Bartlett 
Date:   Mon Sep 3 01:51:59 2012 +1000

s3-smbd: Remove BSD support from old (pre-sysquotas) code

This is essentially dead code, as while it is possible to disable
sysquotas, the default for BSD is now to use sysquotas with the
addition of 4B support via the recent Darwin patch by James Peach.

NFS support has been in sysquotas for quite some time now.

Andrew Bartlett

Signed-off-by: Björn Jacke 

commit 28ccb67170828d2fb739cdda1491434c8a2f5d65
Author: Andrew Bartlett 
Date:   Mon Sep 3 01:41:27 2012 +1000

s3-smbd: Remove Linux support from old (pre-sysquotas) code

This is essentially dead code, as while it is possible to disable 
sysquotas, the default
for Linux has been to use sysquotas for quite some time now.

Andrew Bartlett

Signed-off-by: Björn Jacke 

commit 040a45805f6796858cc916970db7dec2c7f81cf5
Author: Andrew Bartlett 
Date:   Mon Sep 3 03:08:54 2012 +1000

s3-configure: Only use sysquotas by default

We now only use old quota code if --with-quotas=yes and there is no
sysquotas support for this platform.

This also removes --with-sys-quotas as an option, instead being the
first choice if --with-quotas=yes or --with-quotas=auto

sysquotas have been our preferred quota mechanism since 2003.

Andrew Bartlett

Signed-off-by: Björn Jacke 

commit 24013bda4526b1f1cb1c245da83f290210f6e6bc
Author: Andrew Bartlett 
Date:   Wed Jun 13 12:20:07 2012 +1000

build: Remove Unicos support (quota in particular)

Unicos machines are long gone now (Cray now make Linux compute nodes),
so remove the quota support.

Andrew Bartlett

Signed-off-by: Björn Jacke 

commit b7b0d7d868027e6a9e63639838d811febc946109
Author: Andrew Bartlett 
Date:   Tue Jun 5 06:39:28 2012 +1000

build: Do not compile lib/sysquotas*.c files as part of configure

Instead, use the tests in tests/sysquotas.c.

It is better that we see any compile failures, and then expand the
tests than 'automatically' disable the support.  Users can always use
--without-quotas if the quotas code does not work on their system.

Andrew Bartlett

Signed-off-by: Björn Jacke 

commit 82cffc2bdbfec4f5c50514c1e08ed342f8f9d189
Author: Volker Lendecke 
Date:   Wed Sep 5 10:15:48 2012 +0200

s3: Fix 64-bit warnings in vfs_media_harmony

commit a6df44b3ae1ca6395d05e1af804a779d785358db
Author: Björn Jacke 
Date:   Thu Sep 6 07:58:00 2012 +0200

sysquota: we need to list nfs4 as a separate fs name for the 
sys_get_nfs_quota backend

at least the Linux kernel up to 3.5.0 lists NFSv4 aѕ nfs4 and not as nfs

--

[SCM] Samba Shared Repository - branch master updated

2012-09-06 Thread Björn Jacke
The branch, master has been updated
   via  44fd8e7 fileserver:sysquotas: remove wrong cast
   via  d6cc08b s3:quota: don't force the block size to 512
  from  146ad30 s3-smbd: Remove remaining references to removed OS support 
in old-style quota code

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 44fd8e72081f168c0f75cf9fb8969fe42d1e98c9
Author: Björn Jacke 
Date:   Thu Sep 6 14:17:25 2012 +0200

fileserver:sysquotas: remove wrong cast

Autobuild-User(master): Björn Jacke 
Autobuild-Date(master): Thu Sep  6 17:16:30 CEST 2012 on sn-devel-104

commit d6cc08b9eeb9de17bc0e610d6cf6dba13c5c8222
Author: Björn Jacke 
Date:   Thu Sep 6 10:23:50 2012 +0200

s3:quota: don't force the block size to 512

there is no point in forcing the block size to 512 when curblocks is 1. This
will only lead to false quota reporting. See bug #3272

---

Summary of changes:
 source3/lib/sysquotas.c |2 +-
 source3/smbd/quotas.c   |3 ---
 2 files changed, 1 insertions(+), 4 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/lib/sysquotas.c b/source3/lib/sysquotas.c
index 84679f4..cbacc7b 100644
--- a/source3/lib/sysquotas.c
+++ b/source3/lib/sysquotas.c
@@ -225,7 +225,7 @@ static int command_get_quota(const char *path, enum 
SMB_QUOTA_TYPE qtype, unid_t
 
/* we need to deal with long long unsigned here, if 
supported */
 
-   dp->qflags = (enum SMB_QUOTA_TYPE)strtoul(line, &p2, 
10);
+   dp->qflags = strtoul(line, &p2, 10);
p = p2;
while (p && *p && isspace(*p)) {
p++;
diff --git a/source3/smbd/quotas.c b/source3/smbd/quotas.c
index 339952e..3d1056d 100644
--- a/source3/smbd/quotas.c
+++ b/source3/smbd/quotas.c
@@ -203,9 +203,6 @@ static bool nfs_quotas(char *nfspath, uid_t euser_id, 
uint64_t *bsize, uint64_t
*bsize = gqr.getquota_rslt_u.gqr_rquota.rq_bsize;
*dsize = D.dqb_bsoftlimit;
 
-   if (D.dqb_curblocks == 1)
-   *bsize = 512;
-
if (D.dqb_curblocks > D.dqb_bsoftlimit) {
*dfree = 0;
*dsize = D.dqb_curblocks;


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2012-09-06 Thread Kai Blin
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;
}
W_ERROR_NOT_OK_RETURN(werror);
 
+   access_mask = SEC_STD_REQUIRED | SEC_ADS_SELF_WRITE;
+
+   if (tkey != NULL) {
+   int l

[SCM] Samba Shared Repository - branch master updated

2012-09-06 Thread Stefan Metzmacher
The branch, master has been updated
   via  54ae7ca selftest/knownfail: samba3.smb2.durable-v2-open.reopen{1,2} 
fails currently
   via  640752b s4:torture/smb2: add smb2.durable-v2-open.reopen{1,2} tests
   via  1874ebe s4:torture/smb2: check that the server should ignore the 
fname in a DHnC request
   via  afaea04 s4:torture/smb2: don't expect a DHnQ response in a DHnC 
request
  from  8ba8020 s4 dns: Make debug output less noisy

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit 54ae7ca417628ddae5be275891f3782f245d7c5f
Author: Stefan Metzmacher 
Date:   Thu Sep 6 12:18:05 2012 +0200

selftest/knownfail: samba3.smb2.durable-v2-open.reopen{1,2} fails currently

metze

Autobuild-User(master): Stefan Metzmacher 
Autobuild-Date(master): Fri Sep  7 02:12:22 CEST 2012 on sn-devel-104

commit 640752b969714bd43e328a05804affad63aa6d98
Author: Stefan Metzmacher 
Date:   Thu Sep 6 11:51:12 2012 +0200

s4:torture/smb2: add smb2.durable-v2-open.reopen{1,2} tests

They show that only the content of the DH2C request matches and
all other values in the SMB2 Create request are ignored.

metze

commit 1874ebeb37ea1604823d8cedb76344b292453d74
Author: Stefan Metzmacher 
Date:   Thu Sep 6 12:38:54 2012 +0200

s4:torture/smb2: check that the server should ignore the fname in a DHnC 
request

metze

commit afaea04f1cb5a31ba0bfd0f5c8ad37c1bdc6d79e
Author: Stefan Metzmacher 
Date:   Thu Sep 6 11:49:42 2012 +0200

s4:torture/smb2: don't expect a DHnQ response in a DHnC request

This is fixed in Windows 2012 and matches the [MS-SMB2] documentation
now.

metze

---

Summary of changes:
 selftest/knownfail |2 +
 source4/torture/smb2/durable_open.c|7 +-
 source4/torture/smb2/durable_v2_open.c |  184 
 3 files changed, 188 insertions(+), 5 deletions(-)


Changeset truncated at 500 lines:

diff --git a/selftest/knownfail b/selftest/knownfail
index 4e6eb43..30c66b8 100644
--- a/selftest/knownfail
+++ b/selftest/knownfail
@@ -189,6 +189,8 @@
 ^samba3.smb2.durable-open.oplock
 ^samba3.smb2.durable-v2-open.open-oplock
 ^samba3.smb2.durable-v2-open.open-lease
+^samba3.smb2.durable-v2-open.reopen1
+^samba3.smb2.durable-v2-open.reopen2
 ^samba3.smb2.durable-v2-open.persistent-open-oplock
 ^samba3.smb2.durable-v2-open.persistent-open-lease
 ^samba3.smb2.ioctl.shadow_copy
diff --git a/source4/torture/smb2/durable_open.c 
b/source4/torture/smb2/durable_open.c
index 659fa9d..8524fd6 100644
--- a/source4/torture/smb2/durable_open.c
+++ b/source4/torture/smb2/durable_open.c
@@ -443,14 +443,14 @@ bool test_durable_open_reopen2(struct torture_context 
*tctx,
}
 
ZERO_STRUCT(io2);
-   io2.in.fname = fname;
+   /* the path name is ignored by the server */
+   io2.in.fname = "__non_existing_fname__";
io2.in.durable_handle = h;
h = NULL;
 
status = smb2_create(tree, mem_ctx, &io2);
CHECK_STATUS(status, NT_STATUS_OK);
CHECK_CREATED(&io2, EXISTED, FILE_ATTRIBUTE_ARCHIVE);
-   CHECK_VAL(io2.out.durable_open, true);
CHECK_VAL(io2.out.oplock_level, smb2_util_oplock_level("b"));
_h = io2.out.file.handle;
h = &_h;
@@ -524,7 +524,6 @@ bool test_durable_open_reopen2a(struct torture_context 
*tctx,
status = smb2_create(tree, mem_ctx, &io2);
CHECK_STATUS(status, NT_STATUS_OK);
CHECK_CREATED(&io2, EXISTED, FILE_ATTRIBUTE_ARCHIVE);
-   CHECK_VAL(io2.out.durable_open, true);
CHECK_VAL(io2.out.oplock_level, smb2_util_oplock_level("b"));
_h = io2.out.file.handle;
h = &_h;
@@ -689,7 +688,6 @@ bool test_durable_open_reopen4(struct torture_context *tctx,
_h = io2.out.file.handle;
h = &_h;
CHECK_CREATED(&io2, EXISTED, FILE_ATTRIBUTE_ARCHIVE);
-   CHECK_VAL(io2.out.durable_open, true);
CHECK_VAL(io2.out.oplock_level, smb2_util_oplock_level("b"));
 
 done:
@@ -895,7 +893,6 @@ bool test_durable_open_file_position(struct torture_context 
*tctx,
 
status = smb2_create(tree2, mem_ctx, &io2);
CHECK_STATUS(status, NT_STATUS_OK);
-   CHECK_VAL(io2.out.durable_open, true);
CHECK_VAL(io2.out.oplock_level, SMB2_OPLOCK_LEVEL_BATCH);
CHECK_VAL(io2.out.reserved, 0x00);
CHECK_VAL(io2.out.create_action, NTCREATEX_ACTION_EXISTED);
diff --git a/source4/torture/smb2/durable_v2_open.c 
b/source4/torture/smb2/durable_v2_open.c
index 700179e..3b5f7b6 100644
--- a/source4/torture/smb2/durable_v2_open.c
+++ b/source4/torture/smb2/durable_v2_open.c
@@ -369,6 +369,188 @@ bool test_durable_v2_open_lease(struct torture_context 
*tctx,
return ret;
 }
 
+/**
+ * basic test for doing a durable open
+ * and do a durable reopen on the same connection
+ * wh

[SCM] Samba Shared Repository - branch master updated

2012-09-06 Thread Jeremy Allison
The branch, master has been updated
   via  d0159f6 Free protect_ids in secret_store_domain_guid() as the 
caller of fetch_secrets() must free the result in order to not leak memory.
  from  54ae7ca selftest/knownfail: samba3.smb2.durable-v2-open.reopen{1,2} 
fails currently

http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master


- Log -
commit d0159f6673e0fdf50f096548ea1a134c0e864ceb
Author: Michele Baldessari 
Date:   Thu Sep 6 17:32:11 2012 -0700

Free protect_ids in secret_store_domain_guid() as the caller of 
fetch_secrets() must free the result in order to not leak memory.

Signed-off-by: Jeremy Allison 

Autobuild-User(master): Jeremy Allison 
Autobuild-Date(master): Fri Sep  7 04:11:43 CEST 2012 on sn-devel-104

---

Summary of changes:
 source3/passdb/machine_account_secrets.c |2 ++
 1 files changed, 2 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/passdb/machine_account_secrets.c 
b/source3/passdb/machine_account_secrets.c
index 70d7106..6320f4e 100644
--- a/source3/passdb/machine_account_secrets.c
+++ b/source3/passdb/machine_account_secrets.c
@@ -149,9 +149,11 @@ bool secrets_store_domain_guid(const char *domain, struct 
GUID *guid)
if (strncmp(protect_ids, "TRUE", 4)) {
DEBUG(0, ("Refusing to store a Domain SID, "
  "it has been marked as protected!\n"));
+   SAFE_FREE(protect_ids);
return false;
}
}
+   SAFE_FREE(protect_ids);
 #endif
 
slprintf(key, sizeof(key)-1, "%s/%s", SECRETS_DOMAIN_GUID, domain);


-- 
Samba Shared Repository