[SCM] CTDB repository - branch master updated - ctdb-1.0.114-109-g2d60f96

2010-05-31 Thread Ronnie Sahlberg
The branch, master has been updated
   via  2d60f96680d16c2992e2a35517822f88c12538b7 (commit)
  from  d938b80a1c409a9ec4b554ddca5b0d949be53d9e (commit)

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


- Log -
commit 2d60f96680d16c2992e2a35517822f88c12538b7
Author: Ronnie Sahlberg 
Date:   Tue Jun 1 16:22:48 2010 +1000

When adding an ip at runtime, it might not yet have an iface assigned to 
it, so ensure that the next takover_ip call will fall through to accept the ip 
and add it.

---

Summary of changes:
 server/ctdb_takeover.c |5 +
 1 files changed, 5 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/server/ctdb_takeover.c b/server/ctdb_takeover.c
index e80e303..52db386 100644
--- a/server/ctdb_takeover.c
+++ b/server/ctdb_takeover.c
@@ -588,6 +588,11 @@ int32_t ctdb_control_takeover_ip(struct ctdb_context *ctdb,
return -1;
}
 
+   if (vnn->iface == NULL && vnn->pnn == -1 && have_ip && best_iface != 
NULL) {
+   DEBUG(DEBUG_ERR,("Taking over newly created ip\n"));
+   have_ip = false;
+   }
+
if (vnn->iface == NULL && have_ip) {
DEBUG(DEBUG_CRIT,(__location__ " takeoverip of IP %s is known 
to the kernel, "
  "but we have no interface assigned, has 
someone manually configured it?"


-- 
CTDB repository


Build status as of Tue Jun 1 06:00:04 2010

2010-05-31 Thread build
URL: http://build.samba.org/

--- /home/build/master/cache/broken_results.txt.old 2010-05-31 
00:00:44.0 -0600
+++ /home/build/master/cache/broken_results.txt 2010-06-01 00:00:07.0 
-0600
@@ -1,10 +1,10 @@
-Build status as of Mon May 31 06:00:05 2010
+Build status as of Tue Jun  1 06:00:04 2010
 
 Build counts:
 Tree Total  Broken Panic 
 build_farm   0  0  0 
 ccache   30 1  0 
-ldb  30 20 0 
+ldb  30 16 0 
 libreplace   30 11 0 
 lorikeet 0  0  0 
 pidl 19 19 0 
@@ -17,6 +17,6 @@
 samba_3_next 28 28 6 
 samba_4_0_test 30 30 0 
 samba_4_0_waf 30 29 0 
-talloc   30 7  0 
+talloc   30 12 0 
 tdb  28 17 0 
 


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Kai Blin
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] CTDB repository - branch master updated - ctdb-1.0.114-108-gd938b80

2010-05-31 Thread Ronnie Sahlberg
The branch, master has been updated
   via  d938b80a1c409a9ec4b554ddca5b0d949be53d9e (commit)
  from  f0e48dd833a4408449083148c172c2136b934e5b (commit)

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


- Log -
commit d938b80a1c409a9ec4b554ddca5b0d949be53d9e
Author: Ronnie Sahlberg 
Date:   Tue Jun 1 14:51:09 2010 +1000

Dont check linkstatus for loopback. This interface never has
issues with the physical layer

---

Summary of changes:
 config/events.d/10.interface |3 +++
 1 files changed, 3 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/config/events.d/10.interface b/config/events.d/10.interface
index 1e7f94b..3ef6594 100755
--- a/config/events.d/10.interface
+++ b/config/events.d/10.interface
@@ -76,6 +76,9 @@ monitor_interfaces()
}
 
case $IFACE in
+   lo*)
+   # loopback is always working
+   ;;
ib*)
# we dont know how to test ib links
;;


-- 
CTDB repository


[SCM] CTDB repository - branch master updated - ctdb-1.0.114-107-gf0e48dd

2010-05-31 Thread Ronnie Sahlberg
The branch, master has been updated
   via  f0e48dd833a4408449083148c172c2136b934e5b (commit)
  from  53df35aff1e10201a38931bbb82fb266a38892c0 (commit)

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


- Log -
commit f0e48dd833a4408449083148c172c2136b934e5b
Author: Ronnie Sahlberg 
Date:   Tue Jun 1 12:43:32 2010 +1000

Prevent clients from connecting to the natgw address.
This address is dedicated for outgoing connections.

BZ62613

---

Summary of changes:
 config/events.d/11.natgw |8 
 1 files changed, 8 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/config/events.d/11.natgw b/config/events.d/11.natgw
index e6e54f4..a01984c 100644
--- a/config/events.d/11.natgw
+++ b/config/events.d/11.natgw
@@ -23,6 +23,8 @@ delete_all() {
# were the NAT-GW
iptables -D POSTROUTING -t nat -s $CTDB_NATGW_PRIVATE_NETWORK -d ! 
$CTDB_NATGW_PRIVATE_NETWORK -j MASQUERADE >/dev/null 2>/dev/null
 
+   # remove any iptables rule we may have on this address
+   iptables -D INPUT -p tcp --syn -d _ip/32 -j REJECT 2>/dev/null
 }
 
 case "$1" in 
@@ -50,6 +52,12 @@ case "$1" in
NATGWIP=`ctdb natgwlist | head -1 | sed -e "s/^[^ ]* *//"`
 
CTDB_NATGW_PUBLIC_IP_HOST=`echo $CTDB_NATGW_PUBLIC_IP | sed -e 
"s/\/.*/\/32/"`
+
+   # block all incoming connections to the natgw address
+   iptables -D INPUT -p tcp --syn -d $CTDB_NATGW_PUBLIC_IP_HOST -j REJECT 
2>/dev/null 
+   iptables -I INPUT -p tcp --syn -d $CTDB_NATGW_PUBLIC_IP_HOST -j REJECT 
2>/dev/null 
+
+
if [ "$NATGWMASTER" = "-1" ]; then
echo "There is not NATGW master node"
exit 1


-- 
CTDB repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Jelmer Vernooij
The branch, master has been updated
   via  5a3e744... pyldb_util: Remove dependency on LIBPYTHON - it's 
already there implicitly and not available in the standalone build.
  from  8378898... s4:samldb LDB module - start on a sequential trigger 
implementation

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


- Log -
commit 5a3e744394b88d8e0dfbc8cb38add8970227919d
Author: Jelmer Vernooij 
Date:   Mon May 31 23:10:59 2010 +0200

pyldb_util: Remove dependency on LIBPYTHON - it's already there
implicitly and not available in the standalone build.

---

Summary of changes:
 source4/lib/ldb/wscript |3 +--
 1 files changed, 1 insertions(+), 2 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source4/lib/ldb/wscript b/source4/lib/ldb/wscript
index dbe2ae4..50ad874 100644
--- a/source4/lib/ldb/wscript
+++ b/source4/lib/ldb/wscript
@@ -155,8 +155,7 @@ def build(bld):
 else:
 abi_file='ABI/ldb-%s.sigs' % VERSION
 
-bld.SAMBA_PYTHON('pyldb_util',
-deps='ldb LIBPYTHON',
+bld.SAMBA_PYTHON('pyldb_util', deps='ldb',
 source='pyldb_util.c')
 
 if not bld.CONFIG_SET('USING_SYSTEM_LDB'):


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Matthias Dieter Wallnöfer
The branch, master has been updated
   via  8378898... s4:samldb LDB module - start on a sequential trigger 
implementation
   via  a8788ce... ldb:ldb_msg_add_steal_string - prevent also there the 
addition of strings with length 0
   via  0fce829... s4:dsdb_load_udv_v1 - "uint32_t" counter type fits 
better than "unsigned int"
  from  0fddbe4... s3-waf: Check if compiler supports LL suffix

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


- Log -
commit 83788988cbd879789108e8119fa3527ceeb47fe4
Author: Matthias Dieter Wallnöfer 
Date:   Mon May 31 13:58:27 2010 +0200

s4:samldb LDB module - start on a sequential trigger implementation

This is a start to allow the triggers to be called sequentially.

commit a8788ce5236a4fbc1c8096a0eed48638b5a03dd8
Author: Matthias Dieter Wallnöfer 
Date:   Mon May 31 22:22:37 2010 +0200

ldb:ldb_msg_add_steal_string - prevent also there the addition of strings 
with length 0

commit 0fce829de46995d474053bd581555dd40e549ff1
Author: Matthias Dieter Wallnöfer 
Date:   Mon May 31 22:04:29 2010 +0200

s4:dsdb_load_udv_v1 - "uint32_t" counter type fits better than "unsigned 
int"

---

Summary of changes:
 source4/dsdb/common/util.c  |2 +-
 source4/dsdb/samdb/ldb_modules/samldb.c |   36 ++
 source4/lib/ldb/common/ldb_msg.c|5 
 3 files changed, 32 insertions(+), 11 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source4/dsdb/common/util.c b/source4/dsdb/common/util.c
index 9329e61..408a959 100644
--- a/source4/dsdb/common/util.c
+++ b/source4/dsdb/common/util.c
@@ -3310,7 +3310,7 @@ int dsdb_load_udv_v1(struct ldb_context *samdb, struct 
ldb_dn *dn, TALLOC_CTX *m
 struct drsuapi_DsReplicaCursor **cursors, uint32_t *count)
 {
struct drsuapi_DsReplicaCursor2 *v2;
-   unsigned int i;
+   uint32_t i;
int ret;
 
ret = dsdb_load_udv_v2(samdb, dn, mem_ctx, &v2, count);
diff --git a/source4/dsdb/samdb/ldb_modules/samldb.c 
b/source4/dsdb/samdb/ldb_modules/samldb.c
index d7ce48f..a068a29 100644
--- a/source4/dsdb/samdb/ldb_modules/samldb.c
+++ b/source4/dsdb/samdb/ldb_modules/samldb.c
@@ -1168,7 +1168,7 @@ static int samldb_prim_group_change(struct samldb_ctx *ac)
rid = samdb_result_uint(ac->msg, "primaryGroupID", (uint32_t) -1);
if (rid == (uint32_t) -1) {
/* we aren't affected of any primary group change */
-   return ldb_next_request(ac->module, ac->req);
+   return LDB_SUCCESS;
}
 
sid = dom_sid_add_rid(ac, samdb_domain_sid(ldb), rid);
@@ -1225,7 +1225,7 @@ static int samldb_prim_group_change(struct samldb_ctx *ac)
}
}
 
-   return ldb_next_request(ac->module, ac->req);
+   return LDB_SUCCESS;
 }
 
 
@@ -1241,6 +1241,11 @@ static int samldb_member_check(struct samldb_ctx *ac)
ldb = ldb_module_get_ctx(ac->module);
 
el = ldb_msg_find_element(ac->msg, "member");
+   if (el == NULL) {
+   /* we aren't affected */
+   return LDB_SUCCESS;
+   }
+
for (i = 0; i < el->num_values; i++) {
/* Denies to add "member"s to groups which are primary ones
 * for them */
@@ -1275,7 +1280,7 @@ static int samldb_member_check(struct samldb_ctx *ac)
}
}
 
-   return ldb_next_request(ac->module, ac->req);
+   return LDB_SUCCESS;
 }
 
 
@@ -1294,7 +1299,7 @@ static int samldb_prim_group_users_check(struct 
samldb_ctx *ac)
   NULL);
if (sid == NULL) {
/* No SID - it might not be a SAM object - therefore ok */
-   return ldb_next_request(ac->module, ac->req);
+   return LDB_SUCCESS;
}
status = dom_sid_split_rid(ac, sid, NULL, &rid);
if (!NT_STATUS_IS_OK(status)) {
@@ -1302,7 +1307,7 @@ static int samldb_prim_group_users_check(struct 
samldb_ctx *ac)
}
if (rid == 0) {
/* Special object (security principal?) */
-   return ldb_next_request(ac->module, ac->req);
+   return LDB_SUCCESS;
}
 
/* Deny delete requests from groups which are primary ones */
@@ -1316,7 +1321,7 @@ static int samldb_prim_group_users_check(struct 
samldb_ctx *ac)
return LDB_ERR_ENTRY_ALREADY_EXISTS;
}
 
-   return ldb_next_request(ac->module, ac->req);
+   return LDB_SUCCESS;
 }
 
 
@@ -1507,7 +1512,10 @@ static int samldb_modify(struct ldb_module *module, 
struct ldb_request *req)
req->op.mod.message = ac->msg = ldb_msg_copy_shallow(req,
req->op.mod.message);
 
-   return samldb_prim_group_change(ac);
+   ret = samldb_prim_group_change(ac);
+  

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Kai Blin
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

2010-05-31 Thread Günther Deschner
The branch, master has been updated
   via  e80301e... s3-smbd: remove unused sconn from token_contains_name().
  from  d33c41f... s3:winbindd move reinit_after_fork() back out of 
winbindd_register_handlers

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


- Log -
commit e80301eded1d42b6a015c622be07bba589ee3512
Author: Günther Deschner 
Date:   Mon May 31 21:49:04 2010 +0200

s3-smbd: remove unused sconn from token_contains_name().

Guenther

---

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


Changeset truncated at 500 lines:

diff --git a/source3/smbd/share_access.c b/source3/smbd/share_access.c
index d41b05d..6f3bfd0 100644
--- a/source3/smbd/share_access.c
+++ b/source3/smbd/share_access.c
@@ -73,7 +73,6 @@ static bool token_contains_name(TALLOC_CTX *mem_ctx,
const char *prefix;
struct dom_sid sid;
enum lsa_SidType type;
-   struct smbd_server_connection *sconn = smbd_server_conn;
 
if (username != NULL) {
name = talloc_sub_basic(mem_ctx, username, domain, name);


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Stefan Metzmacher
The branch, master has been updated
   via  d33c41f... s3:winbindd move reinit_after_fork() back out of 
winbindd_register_handlers
   via  19f4229... s3:winbind Make state->mem_ctx a talloc child of state
   via  61eb56b... s3:winbind tidy up connecting the winbind sockets.
   via  e5ebc52... Revert "s3:winbindd Split helper functions to allow 
s3compat to call them"
  from  fca69a9... s3-netlogon: Fix crash bug in 
_netr_NetrEnumerateTrustedDomains().

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


- Log -
commit d33c41fbf5bd48fe32d82174d8bd25d1651ee374
Author: Andrew Bartlett 
Date:   Thu May 13 17:07:15 2010 +1000

s3:winbindd move reinit_after_fork() back out of winbindd_register_handlers

This particular init function needs to be done in a native Samba3
build, but it turns out to be difficult for s3compat, which has other
code listening on the sockets.

Andrew Bartlett

commit 19f4229fff0f0e350d0eb6e91f674c48c744d214
Author: Andrew Bartlett 
Date:   Mon May 24 10:11:23 2010 +1000

s3:winbind Make state->mem_ctx a talloc child of state

This way everything is destoryed at the conclusion of
the connection correctly.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 

commit 61eb56be4ea1f4eb26f63b985aeb52cdb1183328
Author: Andrew Bartlett 
Date:   Mon May 17 19:34:32 2010 +1000

s3:winbind tidy up connecting the winbind sockets.

By putting this code inline in winbindd_setup_listeners() we remove 2
static variables and simplify the code.

By putting the get_winbind_priv_pipe_dir() in the same file, we allow
it to be reimplemented in s3compat.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 

commit e5ebc52e9fd45346a74e2c421f2471b5e6cab998
Author: Andrew Bartlett 
Date:   Fri May 14 13:11:48 2010 +1000

Revert "s3:winbindd Split helper functions to allow s3compat to call them"

I'm experimenting with a different entry point

This reverts commit f5c0f90da5f5372ca6b7a72daa8d073a2444a068.

---

Summary of changes:
 source3/winbindd/winbindd.c   |   97 -
 source3/winbindd/winbindd_proto.h |7 +--
 source3/winbindd/winbindd_util.c  |   43 
 3 files changed, 55 insertions(+), 92 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/winbindd/winbindd.c b/source3/winbindd/winbindd.c
index 1c87a14..fcd3145 100644
--- a/source3/winbindd/winbindd.c
+++ b/source3/winbindd/winbindd.c
@@ -574,7 +574,7 @@ static void process_request(struct winbindd_cli_state 
*state)
struct winbindd_dispatch_table *table = dispatch_table;
struct winbindd_async_dispatch_table *atable;
 
-   state->mem_ctx = talloc_init("winbind request");
+   state->mem_ctx = talloc_named(state, 0, "winbind request");
if (state->mem_ctx == NULL)
return;
 
@@ -763,23 +763,40 @@ void request_ok(struct winbindd_cli_state *state)
 
 /* Process a new connection by adding it to the client connection list */
 
-void winbindd_accepted_new_connection(int accepted_sock, bool privileged)
+static void new_connection(int listen_sock, bool privileged)
 {
+   struct sockaddr_un sunaddr;
struct winbindd_cli_state *state;
struct tevent_req *req;
+   socklen_t len;
+   int sock;
+
+   /* Accept connection */
+
+   len = sizeof(sunaddr);
+
+   do {
+   sock = accept(listen_sock, (struct sockaddr *)(void *)&sunaddr,
+ &len);
+   } while (sock == -1 && errno == EINTR);
+
+   if (sock == -1)
+   return;
+
+   DEBUG(6,("accepted socket %d\n", sock));
 
/* Create new connection structure */
 
if ((state = TALLOC_ZERO_P(NULL, struct winbindd_cli_state)) == NULL) {
-   close(accepted_sock);
+   close(sock);
return;
}
 
-   state->sock = accepted_sock;
+   state->sock = sock;
 
state->out_queue = tevent_queue_create(state, "winbind client reply");
if (state->out_queue == NULL) {
-   close(accepted_sock);
+   close(sock);
TALLOC_FREE(state);
return;
}
@@ -792,40 +809,16 @@ void winbindd_accepted_new_connection(int accepted_sock, 
bool privileged)
   WINBINDD_MAX_EXTRA_DATA);
if (req == NULL) {
TALLOC_FREE(state);
-   close(accepted_sock);
+   close(sock);
return;
}
tevent_req_set_callback(req, winbind_client_request_read, state);
 
/* Add to connection list */
 
-   /* Once the client is added here, we can be sure something will close 
it eventually */
winbindd_add_client(state);
 }
 
-static voi

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Günther Deschner
The branch, master has been updated
   via  fca69a9... s3-netlogon: Fix crash bug in 
_netr_NetrEnumerateTrustedDomains().
  from  cf72740... Revert "ldb: Remove Samba-specific symbols."

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


- Log -
commit fca69a9e2f19d7f54cee6ace17adf57372cea52e
Author: Günther Deschner 
Date:   Mon May 31 21:26:30 2010 +0200

s3-netlogon: Fix crash bug in _netr_NetrEnumerateTrustedDomains().

Guenther

---

Summary of changes:
 source3/rpc_server/srv_netlog_nt.c |   29 +++--
 1 files changed, 11 insertions(+), 18 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/rpc_server/srv_netlog_nt.c 
b/source3/rpc_server/srv_netlog_nt.c
index 4bd176c..cccd0d5 100644
--- a/source3/rpc_server/srv_netlog_nt.c
+++ b/source3/rpc_server/srv_netlog_nt.c
@@ -412,12 +412,6 @@ NTSTATUS _netr_NetrEnumerateTrustedDomains(pipes_struct *p,
return status;
}
 
-   trusted_domains = talloc_zero_array(p->mem_ctx, const char *, 
num_domains);
-   if (!trusted_domains) {
-   status = NT_STATUS_NO_MEMORY;
-   goto out;
-   }
-
status = rpccli_lsa_open_policy2(cli, p->mem_ctx,
 true,
 LSA_POLICY_VIEW_LOCAL_INFORMATION,
@@ -426,10 +420,7 @@ NTSTATUS _netr_NetrEnumerateTrustedDomains(pipes_struct *p,
goto out;
}
 
-   status = STATUS_MORE_ENTRIES;
-
-   while (NT_STATUS_EQUAL(status, STATUS_MORE_ENTRIES)) {
-
+   do {
/* Lookup list of trusted domains */
 
status = rpccli_lsa_EnumTrustDom(cli, p->mem_ctx,
@@ -450,16 +441,18 @@ NTSTATUS _netr_NetrEnumerateTrustedDomains(pipes_struct 
*p,
goto out;
}
}
-   }
+   } while (NT_STATUS_EQUAL(status, STATUS_MORE_ENTRIES));
 
-   /* multi sz terminate */
-   trusted_domains = talloc_realloc(p->mem_ctx, trusted_domains, const 
char *, num_domains + 1);
-   if (trusted_domains == NULL) {
-   status = NT_STATUS_NO_MEMORY;
-   goto out;
-   }
+   if (num_domains > 0) {
+   /* multi sz terminate */
+   trusted_domains = talloc_realloc(p->mem_ctx, trusted_domains, 
const char *, num_domains + 1);
+   if (trusted_domains == NULL) {
+   status = NT_STATUS_NO_MEMORY;
+   goto out;
+   }
 
-   trusted_domains[num_domains+1] = NULL;
+   trusted_domains[num_domains] = NULL;
+   }
 
if (!push_reg_multi_sz(trusted_domains, &blob, trusted_domains)) {
TALLOC_FREE(trusted_domains);


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Simo Sorce
The branch, master has been updated
   via  cf72740... Revert "ldb: Remove Samba-specific symbols."
  from  a22d7db... wafsamba: Only try to build manpages if XSLTPROC was 
actually found.

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


- Log -
commit cf727404f4ccad04b7a8fe28d0c1e8eaed69522b
Author: Simo Sorce 
Date:   Mon May 31 14:50:07 2010 -0400

Revert "ldb: Remove Samba-specific symbols."

This reverts commit fe8302b235197e359a20ba0489eb72b54793963e.

Jelmer, please do not re-re-revert this until we can properly handle
*both* s4 and standalone ldb builds.

---

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

2010-05-31 Thread Jelmer Vernooij
The branch, master has been updated
   via  a22d7db... wafsamba: Only try to build manpages if XSLTPROC was 
actually found.
   via  41cdac9... pyldb: Remove duplicate copy of function.
  from  38dfc48... ldb: Remove unexisting and mistyped function from header

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


- Log -
commit a22d7db30813127690d5c3758e7abfa8805e76c9
Author: Jelmer Vernooij 
Date:   Mon May 31 20:44:30 2010 +0200

wafsamba: Only try to build manpages if XSLTPROC was actually found.

commit 41cdac9c3e5b2e9eea3067892a3e60b4bff67154
Author: Jelmer Vernooij 
Date:   Mon May 31 20:44:12 2010 +0200

pyldb: Remove duplicate copy of function.

---

Summary of changes:
 buildtools/wafsamba/wafsamba.py |4 ++--
 source4/lib/ldb/pyldb.c |   28 
 2 files changed, 2 insertions(+), 30 deletions(-)


Changeset truncated at 500 lines:

diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index a9b81f4..13f3f8c 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -213,7 +213,7 @@ def SAMBA_LIBRARY(bld, libname, source,
 if pc_files is not None:
 bld.PKG_CONFIG_FILES(pc_files, vnum=vnum)
 
-if manpages is not None and 'XSLTPROC' in bld.env:
+if manpages is not None and 'XSLTPROC' in bld.env and bld.env['XSLTPROC']:
 bld.MANPAGES(manpages)
 
 
@@ -304,7 +304,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 'XSLTPROC' in bld.env:
+if manpages is not None and 'XSLTPROC' in bld.env and bld.env['XSLTPROC']:
 bld.MANPAGES(manpages)
 
 Build.BuildContext.SAMBA_BINARY = SAMBA_BINARY
diff --git a/source4/lib/ldb/pyldb.c b/source4/lib/ldb/pyldb.c
index ce149cc..fd7584d 100644
--- a/source4/lib/ldb/pyldb.c
+++ b/source4/lib/ldb/pyldb.c
@@ -81,34 +81,6 @@ static PyObject *PyObject_FromLdbValue(struct ldb_context 
*ldb_ctx,
 }
 
 /**
- * Obtain a ldb DN from a Python object.
- *
- * @param mem_ctx Memory context
- * @param object Python object
- * @param ldb_ctx LDB context
- * @return Whether or not the conversion succeeded
- */
-bool PyObject_AsDn(TALLOC_CTX *mem_ctx, PyObject *object, 
-  struct ldb_context *ldb_ctx, struct ldb_dn **dn)
-{
-   struct ldb_dn *odn;
-
-   if (ldb_ctx != NULL && PyString_Check(object)) {
-   odn = ldb_dn_new(mem_ctx, ldb_ctx, PyString_AsString(object));
-   *dn = odn;
-   return true;
-   }
-
-   if (PyLdbDn_Check(object)) {
-   *dn = PyLdbDn_AsDn(object);
-   return true;
-   }
-
-   PyErr_SetString(PyExc_TypeError, "Expected DN");
-   return false;
-}
-
-/**
  * Create a Python object from a ldb_result.
  *
  * @param result LDB result to convert


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Simo Sorce
The branch, master has been updated
   via  38dfc48... ldb: Remove unexisting and mistyped function from header
  from  7f75ee0... ldb: Install ldb_handlers.h header.

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


- Log -
commit 38dfc480334926f07b7d1869225370693140e349
Author: Simo Sorce 
Date:   Mon May 31 13:54:00 2010 -0400

ldb: Remove unexisting and mistyped function from header

---

Summary of changes:
 source4/lib/ldb/include/ldb_handlers.h |2 --
 1 files changed, 0 insertions(+), 2 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source4/lib/ldb/include/ldb_handlers.h 
b/source4/lib/ldb/include/ldb_handlers.h
index 21fbcc3..6e71f1f 100644
--- a/source4/lib/ldb/include/ldb_handlers.h
+++ b/source4/lib/ldb/include/ldb_handlers.h
@@ -35,8 +35,6 @@ int ldb_handler_copy( struct ldb_context *ldb, void 
*mem_ctx,
const struct ldb_val *in, struct ldb_val *out);
 int ldb_comparison_binary( struct ldb_context *ldb, void *mem_ctx,
const struct ldb_val *v1, const struct ldb_val 
*v2);
-int db_handler_fold(   struct ldb_context *ldb, void *mem_ctx,
-   const struct ldb_val *in, struct ldb_val *out);
 int ldb_comparison_fold(   struct ldb_context *ldb, void *mem_ctx,
const struct ldb_val *v1, const struct ldb_val 
*v2);
 


-- 
Samba Shared Repository


Re: [SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread simo
On Mon, 2010-05-31 at 12:23 -0500, Jelmer Vernooij wrote:
> The branch, master has been updated
>via  7f75ee0... ldb: Install ldb_handlers.h header.
>via  fe8302b... ldb: Remove Samba-specific symbols.
>via  1bc53f0... ldb: Move utility functions to separate file.
>via  82d56b9... ldb: Fix dependencies when building with system ldb.
>   from  471ed70... s3:smbd map_username() doesn't need sconn anymore
> 
> http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
> 
> 
> - Log -
> commit 7f75ee025ff9c02763fb9201d94af4b2739c8e03
> Author: Jelmer Vernooij 
> Date:   Mon May 31 18:29:11 2010 +0200
> 
> ldb: Install ldb_handlers.h header.

Jelmer,
why are you installing this header ?
It is a private header afaik.

> diff --git a/source4/lib/ldb/tools/cmdline.c b/source4/lib/ldb/tools/cmdline.c
> index 180923f..c2b595f 100644
> --- a/source4/lib/ldb/tools/cmdline.c
> +++ b/source4/lib/ldb/tools/cmdline.c
> @@ -21,12 +21,9 @@
> License along with this library; if not, see 
> .
>  */
>  
> -#include "ldb_includes.h"
> -#include "ldb.h"
> -#include "tools/cmdline.h"
> -
>  #if (_SAMBA_BUILD_ >= 4)
>  #include "includes.h"
> +#include 
>  #include "lib/cmdline/popt_common.h"
>  #include "lib/ldb-samba/ldif_handlers.h"
>  #include "auth/gensec/gensec.h"


This also doesn't look right.
When you are building the tools you want to build them against the
headers that are going to be installed, and not against the headers that
are currently available on the machine.
We shouldn't reference  but explicitly the headers in the tree.

Simo.

-- 
Simo Sorce
Samba Team GPL Compliance Officer 
Principal Software Engineer at Red Hat, Inc. 



Re: [SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Stefan (metze) Metzmacher
Am 31.05.2010 19:23, schrieb Jelmer Vernooij:
> The branch, master has been updated
>via  7f75ee0... ldb: Install ldb_handlers.h header.
>via  fe8302b... ldb: Remove Samba-specific symbols.
>via  1bc53f0... ldb: Move utility functions to separate file.
>via  82d56b9... ldb: Fix dependencies when building with system ldb.
>   from  471ed70... s3:smbd map_username() doesn't need sconn anymore
> 
> http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master
> 
> 
> - Log -
> commit 7f75ee025ff9c02763fb9201d94af4b2739c8e03
> Author: Jelmer Vernooij 
> Date:   Mon May 31 18:29:11 2010 +0200
> 
> ldb: Install ldb_handlers.h header.
> 
> commit fe8302b235197e359a20ba0489eb72b54793963e
> Author: Jelmer Vernooij 
> Date:   Mon May 31 18:28:09 2010 +0200
> 
> ldb: Remove Samba-specific symbols.
> 
> commit 1bc53f0213b04e30ebf2ac60695c84c5781e4e72
> Author: Jelmer Vernooij 
> Date:   Mon May 31 18:12:05 2010 +0200
> 
> ldb: Move utility functions to separate file.
> 
> commit 82d56b937445585b9e60451daf660aee5ace0523
> Author: Jelmer Vernooij 
> Date:   Mon May 31 16:05:41 2010 +0200
> 
> ldb: Fix dependencies when building with system ldb.

I'm getting this again:

[1862/1965] abi_check: source4/bin/default/source4/lib/ldb/libldb-samba4.so
libldb-samba4.so: symbol ldb_wrap_connect has been added - please mark
it _PRIVATE_ or update minor version
signature: struct ldb_context *(TALLOC_CTX *, struct
tevent_context *, struct loadparm_context *, const char *, struct
auth_session_info *, struct cli_credentials *, unsigned int)
libldb-samba4.so: symbol ldb_register_samba_handlers has been added -
please mark it _PRIVATE_ or update minor version
signature: int (struct ldb_context *)
libldb-samba4.so: symbol ldb_wrap_fork_hook has been added - please mark
it _PRIVATE_ or update minor version
signature: void (void)
libldb-samba4.so: symbol ldb_samba_syntax_by_lDAPDisplayName has been
added - please mark it _PRIVATE_ or update minor version
signature: const struct ldb_schema_syntax *(struct ldb_context
*, const char *)
libldb-samba4.so: symbol ldb_samba_syntax_by_name has been added -
please mark it _PRIVATE_ or update minor version
signature: const struct ldb_schema_syntax *(struct ldb_context
*, const char *)
Waf: Leaving directory `/home/metze/master4/source4/bin'
Build failed: ABI for libldb-samba4.so has changed - please fix library
version then build with --abi-update
See http://wiki.samba.org/index.php/Waf#ABI_Checking for more information
make: *** [all] Fehler 1

metze
> ---
> 
> Summary of changes:
>  source4/auth/wscript_build |2 +-
>  source4/dsdb/wscript_build |2 +-
>  source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs |5 --
>  source4/lib/ldb/pyldb_util.c   |   81 
> 
>  source4/lib/ldb/tools/cmdline.c|   10 ++--
>  source4/lib/ldb/tools/ldbedit.c|7 +++
>  source4/lib/ldb/tools/ldbsearch.c  |6 ++
>  source4/lib/ldb/tools/ldbtest.c|5 ++
>  source4/lib/ldb/wscript|   25 ++---
>  source4/scripting/python/wscript_build |2 +-
>  10 files changed, 124 insertions(+), 21 deletions(-)
>  create mode 100644 source4/lib/ldb/pyldb_util.c
> 
> 
> Changeset truncated at 500 lines:
> 
> diff --git a/source4/auth/wscript_build b/source4/auth/wscript_build
> index 349171e..db8fdf8 100644
> --- a/source4/auth/wscript_build
> +++ b/source4/auth/wscript_build
> @@ -12,7 +12,7 @@ bld.SAMBA_SUBSYSTEM('auth_session',
>   public_deps='CREDENTIALS',
>   public_headers='session.h',
>  header_path='samba',
> - deps='SAMDB'
> + deps='SAMDB auth_sam'
>   )
>  
>  
> diff --git a/source4/dsdb/wscript_build b/source4/dsdb/wscript_build
> index 1bf8413..0a1ea1c 100644
> --- a/source4/dsdb/wscript_build
> +++ b/source4/dsdb/wscript_build
> @@ -51,6 +51,6 @@ bld.SAMBA_MODULE('DNS_UPDATE_SRV',
>  
>  bld.SAMBA_PYTHON('python_dsdb',
>   source='pydsdb.c',
> - deps='SAMDB pyldb',
> + deps='SAMDB pyldb_util',
>   realname='samba/dsdb.so'
>   )
> 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 4639220..2206e79 100644
> --- a/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs
> +++ b/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs
> @@ -166,7 +166,6 @@ 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_co

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Jelmer Vernooij
The branch, master has been updated
   via  7f75ee0... ldb: Install ldb_handlers.h header.
   via  fe8302b... ldb: Remove Samba-specific symbols.
   via  1bc53f0... ldb: Move utility functions to separate file.
   via  82d56b9... ldb: Fix dependencies when building with system ldb.
  from  471ed70... s3:smbd map_username() doesn't need sconn anymore

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


- Log -
commit 7f75ee025ff9c02763fb9201d94af4b2739c8e03
Author: Jelmer Vernooij 
Date:   Mon May 31 18:29:11 2010 +0200

ldb: Install ldb_handlers.h header.

commit fe8302b235197e359a20ba0489eb72b54793963e
Author: Jelmer Vernooij 
Date:   Mon May 31 18:28:09 2010 +0200

ldb: Remove Samba-specific symbols.

commit 1bc53f0213b04e30ebf2ac60695c84c5781e4e72
Author: Jelmer Vernooij 
Date:   Mon May 31 18:12:05 2010 +0200

ldb: Move utility functions to separate file.

commit 82d56b937445585b9e60451daf660aee5ace0523
Author: Jelmer Vernooij 
Date:   Mon May 31 16:05:41 2010 +0200

ldb: Fix dependencies when building with system ldb.

---

Summary of changes:
 source4/auth/wscript_build |2 +-
 source4/dsdb/wscript_build |2 +-
 source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs |5 --
 source4/lib/ldb/pyldb_util.c   |   81 
 source4/lib/ldb/tools/cmdline.c|   10 ++--
 source4/lib/ldb/tools/ldbedit.c|7 +++
 source4/lib/ldb/tools/ldbsearch.c  |6 ++
 source4/lib/ldb/tools/ldbtest.c|5 ++
 source4/lib/ldb/wscript|   25 ++---
 source4/scripting/python/wscript_build |2 +-
 10 files changed, 124 insertions(+), 21 deletions(-)
 create mode 100644 source4/lib/ldb/pyldb_util.c


Changeset truncated at 500 lines:

diff --git a/source4/auth/wscript_build b/source4/auth/wscript_build
index 349171e..db8fdf8 100644
--- a/source4/auth/wscript_build
+++ b/source4/auth/wscript_build
@@ -12,7 +12,7 @@ bld.SAMBA_SUBSYSTEM('auth_session',
public_deps='CREDENTIALS',
public_headers='session.h',
 header_path='samba',
-   deps='SAMDB'
+   deps='SAMDB auth_sam'
)
 
 
diff --git a/source4/dsdb/wscript_build b/source4/dsdb/wscript_build
index 1bf8413..0a1ea1c 100644
--- a/source4/dsdb/wscript_build
+++ b/source4/dsdb/wscript_build
@@ -51,6 +51,6 @@ bld.SAMBA_MODULE('DNS_UPDATE_SRV',
 
 bld.SAMBA_PYTHON('python_dsdb',
  source='pydsdb.c',
- deps='SAMDB pyldb',
+ deps='SAMDB pyldb_util',
  realname='samba/dsdb.so'
  )
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 4639220..2206e79 100644
--- a/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs
+++ b/source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs
@@ -166,7 +166,6 @@ 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 *)
@@ -177,8 +176,6 @@ 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 *)
@@ -220,5 +217,3 @@ 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)
diff --git a/source4/lib/ldb/pyldb_util.c b/source4/lib/ldb/pyldb_util.c
new file mode 100644
index 000..fb06946
--- /dev/null
+++ b/

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Andreas Schneider
The branch, master has been updated
   via  471ed70... s3:smbd map_username() doesn't need sconn anymore
   via  6a25668... s3:smbd user_ok doesn't need sconn anymore
   via  94bf9ce... s3:smbd user_in_list() doesn't need sconn anymore
   via  7747dd8... s3:smbd user_in_network() doesn't need sconn anymore
   via  b32b59d... s3:smbd make yp cache local.
  from  1da4153... buildtools/wafsamba: use build group 'final' for the 
creation of manpages

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


- Log -
commit 471ed70c497f4eeaca27594d609f41f2b2c689cd
Author: Simo Sorce 
Date:   Mon May 31 10:52:06 2010 -0400

s3:smbd map_username() doesn't need sconn anymore

Signed-off-by: Andreas Schneider 

commit 6a25668e55929a8111ac0fc5e34b5a83ae936349
Author: Simo Sorce 
Date:   Mon May 31 10:47:01 2010 -0400

s3:smbd user_ok doesn't need sconn anymore

Signed-off-by: Andreas Schneider 

commit 94bf9ce48a0ef8b77f22f3be6244881ca1a41e49
Author: Simo Sorce 
Date:   Mon May 31 10:45:24 2010 -0400

s3:smbd user_in_list() doesn't need sconn anymore

Signed-off-by: Andreas Schneider 

commit 7747dd82f79bc503efe6a2d3139413afb8dda864
Author: Simo Sorce 
Date:   Mon May 31 10:43:19 2010 -0400

s3:smbd user_in_network() doesn't need sconn anymore

Signed-off-by: Andreas Schneider 

commit b32b59d47f8ec597be9d215e5e260e5d1411d3a4
Author: Simo Sorce 
Date:   Mon May 31 10:36:02 2010 -0400

s3:smbd make yp cache local.

The my_yp_domain variable is just a static cache needed to avoid
making over and over expensive and potentially blocking calls to
yp_get_default_domain().
Instead of keeping this onto the smbd_server_connection struct, just
keep it local to the only function ever using this variable.

This disentagle this function (and a number of calling functions)
from having to pass around smbd_server_connection and thus having
to link against smbd. It also removes a few ifdefs.

Nothing changes from a global/local pov, as the smbd_server_connection
variable passed around is also a global one.

Signed-off-by: Andreas Schneider 

---

Summary of changes:
 source3/auth/auth_util.c |6 +---
 source3/include/proto.h  |8 ++---
 source3/rpc_server/srv_samr_nt.c |9 ++
 source3/smbd/globals.h   |3 --
 source3/smbd/map_username.c  |4 +-
 source3/smbd/password.c  |   55 --
 source3/smbd/process.c   |3 --
 source3/smbd/service.c   |5 +--
 source3/smbd/sesssetup.c |4 +-
 source3/smbd/share_access.c  |2 +-
 source3/smbd/smb2_sesssetup.c|3 +-
 11 files changed, 39 insertions(+), 63 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/auth/auth_util.c b/source3/auth/auth_util.c
index 74d8873..3a63a3b 100644
--- a/source3/auth/auth_util.c
+++ b/source3/auth/auth_util.c
@@ -119,13 +119,12 @@ NTSTATUS make_user_info_map(struct auth_usersupplied_info 
**user_info,
DATA_BLOB *plaintext,
bool encrypted)
 {
-   struct smbd_server_connection *sconn = smbd_server_conn;
const char *domain;
NTSTATUS result;
bool was_mapped;
fstring internal_username;
fstrcpy(internal_username, smb_name);
-   was_mapped = map_username(sconn, internal_username);
+   was_mapped = map_username(internal_username);
 
DEBUG(5, ("Mapping user [%s]\\[%s] from workstation [%s]\n",
 client_domain, smb_name, wksta_name));
@@ -972,7 +971,6 @@ static NTSTATUS check_account(TALLOC_CTX *mem_ctx, const 
char *domain,
  uid_t *uid, gid_t *gid,
  bool *username_was_mapped)
 {
-   struct smbd_server_connection *sconn = smbd_server_conn;
fstring dom_user, lower_username;
fstring real_username;
struct passwd *passwd;
@@ -985,7 +983,7 @@ static NTSTATUS check_account(TALLOC_CTX *mem_ctx, const 
char *domain,
 
/* Get the passwd struct.  Try to create the account if necessary. */
 
-   *username_was_mapped = map_username(sconn, dom_user);
+   *username_was_mapped = map_username(dom_user);
 
passwd = smb_getpwnam( NULL, dom_user, real_username, True );
if (!passwd) {
diff --git a/source3/include/proto.h b/source3/include/proto.h
index cae51e5..237772e 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -5689,7 +5689,7 @@ const struct mangle_fns *posix_mangle_init(void);
 
 /* The following definitions come from smbd/map_username.c  */
 
-bool map_username(struct smbd_server_connection *sconn, fstring user);
+bool map_username(fstring user);
 
 /* The following definitions come from smbd/message.c  */

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Stefan Metzmacher
The branch, master has been updated
   via  1da4153... buildtools/wafsamba: use build group 'final' for the 
creation of manpages
  from  c866920... s3-waf: Fix build after ntlmssp_sign.c moved

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


- Log -
commit 1da415345971fbd045808d26142b9eca797aaedf
Author: Stefan Metzmacher 
Date:   Mon May 31 17:51:21 2010 +0200

buildtools/wafsamba: use build group 'final' for the creation of manpages

This way we don't try to build manpages just for waf build 
--target=smbtorture

metze

---

Summary of changes:
 buildtools/wafsamba/wafsamba.py |1 +
 1 files changed, 1 insertions(+), 0 deletions(-)


Changeset truncated at 500 lines:

diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index 01e2ce8..a9b81f4 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -818,6 +818,7 @@ def MANPAGES(bld, manpages):
 bld.SAMBA_GENERATOR(m,
 source=source,
 target=m,
+group='final',
 rule='${XSLTPROC} -o ${TGT} ${MAN_XSL} ${SRC}'
 )
 bld.INSTALL_FILES('${MANDIR}/man%s' % m[-1], m, flat=True)


-- 
Samba Shared Repository


[SCM] SAMBA-CTDB repository - branch v3-4-ctdb updated - 3.4.7-ctdb-4-10-ge72c09a

2010-05-31 Thread Michael Adam
The branch, v3-4-ctdb has been updated
   via  e72c09a5827c2abba3534263a18c78e6c8e0582a (commit)
   via  1da29b98ecfaca11e4be8d0b23e25f1f3668cf96 (commit)
   via  fc62e1690b75275035e58b1a3ea8c11842533992 (commit)
  from  fce4c325d9020dc4f67dd847649dc9bfa3d6cbd7 (commit)

http://gitweb.samba.org/?p=obnox/samba-ctdb.git;a=shortlog;h=v3-4-ctdb


- Log -
commit e72c09a5827c2abba3534263a18c78e6c8e0582a
Author: Volker Lendecke 
Date:   Wed May 26 17:52:10 2010 +0200

s3: Fix some debug messages

commit 1da29b98ecfaca11e4be8d0b23e25f1f3668cf96
Author: Volker Lendecke 
Date:   Wed May 26 17:47:37 2010 +0200

s3: Don't announce readraw and writeraw with the async echo responder

commit fc62e1690b75275035e58b1a3ea8c11842533992
Author: Volker Lendecke 
Date:   Thu May 27 18:12:30 2010 +0200

s3: Fix a bad memleak in the async echo responder

---

Summary of changes:
 source3/include/proto.h  |2 ++
 source3/param/loadparm.c |   20 ++--
 source3/smbd/process.c   |2 +-
 source3/smbd/reply.c |8 
 4 files changed, 25 insertions(+), 7 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/include/proto.h b/source3/include/proto.h
index 0ec3cc0..dab38a9 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -4038,8 +4038,10 @@ const char **lp_init_logon_delayed_hosts(void);
 int lp_init_logon_delay(void);
 bool lp_load_printers(void);
 bool lp_readraw(void);
+bool _lp_readraw(void);
 bool lp_large_readwrite(void);
 bool lp_writeraw(void);
+bool _lp_writeraw(void);
 bool lp_null_passwords(void);
 bool lp_obey_pam_restrictions(void);
 bool lp_encrypted_passwords(void);
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index 92b4967..5ee1058 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -5476,9 +5476,9 @@ FN_GLOBAL_BOOL(lp_domain_logons, &Globals.bDomainLogons)
 FN_GLOBAL_LIST(lp_init_logon_delayed_hosts, &Globals.szInitLogonDelayedHosts)
 FN_GLOBAL_INTEGER(lp_init_logon_delay, &Globals.InitLogonDelay)
 FN_GLOBAL_BOOL(lp_load_printers, &Globals.bLoadPrinters)
-FN_GLOBAL_BOOL(lp_readraw, &Globals.bReadRaw)
+FN_GLOBAL_BOOL(_lp_readraw, &Globals.bReadRaw)
 FN_GLOBAL_BOOL(lp_large_readwrite, &Globals.bLargeReadwrite)
-FN_GLOBAL_BOOL(lp_writeraw, &Globals.bWriteRaw)
+FN_GLOBAL_BOOL(_lp_writeraw, &Globals.bWriteRaw)
 FN_GLOBAL_BOOL(lp_null_passwords, &Globals.bNullPasswords)
 FN_GLOBAL_BOOL(lp_obey_pam_restrictions, &Globals.bObeyPamRestrictions)
 FN_GLOBAL_BOOL(lp_encrypted_passwords, &Globals.bEncryptPasswords)
@@ -9892,3 +9892,19 @@ bool lp_widelinks(int snum)
 
return lp_widelinks_internal(snum);
 }
+
+bool lp_writeraw(void)
+{
+   if (lp_async_smb_echo_handler()) {
+   return false;
+   }
+   return _lp_writeraw();
+}
+
+bool lp_readraw(void)
+{
+   if (lp_async_smb_echo_handler()) {
+   return false;
+   }
+   return _lp_readraw();
+}
diff --git a/source3/smbd/process.c b/source3/smbd/process.c
index 36640cb..e13d6fd 100644
--- a/source3/smbd/process.c
+++ b/source3/smbd/process.c
@@ -2366,7 +2366,7 @@ static void smbd_echo_reader(struct tevent_context *ev,
 
DEBUG(10,("echo_handler[%d]: reading pdu\n", (int)sys_getpid()));
 
-   status = receive_smb_talloc(state, smbd_server_fd(),
+   status = receive_smb_talloc(state->pending, smbd_server_fd(),
(char **)(void 
*)&state->pending[num_pending].iov_base,
0 /* timeout */,
&unread,
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index a898d5a..8a186b7 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -2941,8 +2941,8 @@ void reply_readbraw(struct smb_request *req)
}
 
if (smbd_server_conn->smb1.echo_handler.trusted_fde) {
-   DEBUG(2,("SMBreadbraw rejected with NOT_SUPPORTED because of"
-"'fork echo handler = yes'\n"));
+   DEBUG(2,("SMBreadbraw rejected with NOT_SUPPORTED because of "
+"'async smb echo handler = yes'\n"));
reply_readbraw_error();
END_PROFILE(SMBreadbraw);
return;
@@ -3649,8 +3649,8 @@ void reply_writebraw(struct smb_request *req)
}
 
if (smbd_server_conn->smb1.echo_handler.trusted_fde) {
-   DEBUG(2,("SMBwritebraw rejected with NOT_SUPPORTED because of"
-"'fork echo handler = yes'\n"));
+   DEBUG(2,("SMBwritebraw rejected with NOT_SUPPORTED because of "
+"'async smb echo handler = yes'\n"));
reply_nterror(req, NT_STATUS_NOT_SUPPORTED);
error_to_writebrawerr(req);
END_PROFILE(SMBwritebraw);


-- 
SAMBA-CTDB repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Kai Blin
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

2010-05-31 Thread Kai Blin
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

2010-05-31 Thread Günther Deschner
The branch, master has been updated
   via  9864164... s3-netlogon: use LSA in 
_netr_NetrEnumerateTrustedDomains.
   via  4bb7e91... s3-netlogon: use SAMR in _netr_ServerAuthenticate3.
   via  db5730c... s3-samr: give the system user a free pass for 
_samr_QueryUserInfo{2} level 18.
   via  3f24f8d... s3-auth: add "system" bool flag to 
auth_serversupplied_info.
   via  a780581... s3-netlogon: use SAMR in _netr_ServerPasswordSet{2}.
  from  62708fb... s3:ntlmssp Move ntlmssp_sign.c from source3 to common 
code.

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


- Log -
commit 98641648d8ec66a0c3e07a73e4275005bfa25811
Author: Günther Deschner 
Date:   Fri May 28 15:31:35 2010 +0200

s3-netlogon: use LSA in _netr_NetrEnumerateTrustedDomains.

Guenther

commit 4bb7e91cfd9071e570c56bca36d35202d01ca80d
Author: Günther Deschner 
Date:   Fri May 28 14:22:08 2010 +0200

s3-netlogon: use SAMR in _netr_ServerAuthenticate3.

Guenther

commit db5730cac4d6e0b64913bce21147352344077e2b
Author: Günther Deschner 
Date:   Fri May 28 14:21:15 2010 +0200

s3-samr: give the system user a free pass for _samr_QueryUserInfo{2} level 
18.

Guenther

commit 3f24f8d2c69be1db28cb1ffb866d45b520d9544d
Author: Günther Deschner 
Date:   Fri May 28 14:19:28 2010 +0200

s3-auth: add "system" bool flag to auth_serversupplied_info.

Guenther

commit a7805811c432adb9b0e82039858269c2154521ae
Author: Günther Deschner 
Date:   Fri May 28 12:39:12 2010 +0200

s3-netlogon: use SAMR in _netr_ServerPasswordSet{2}.

Guenther

---

Summary of changes:
 source3/auth/auth_util.c   |   11 +-
 source3/include/auth.h |1 +
 source3/rpc_server/srv_netlog_nt.c |  466 +++-
 source3/rpc_server/srv_samr_nt.c   |5 +
 4 files changed, 320 insertions(+), 163 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/auth/auth_util.c b/source3/auth/auth_util.c
index 1f9bc7b..74d8873 100644
--- a/source3/auth/auth_util.c
+++ b/source3/auth/auth_util.c
@@ -765,16 +765,24 @@ static NTSTATUS make_new_server_info_system(TALLOC_CTX 
*mem_ctx,
struct auth_serversupplied_info 
**server_info)
 {
struct passwd *pwd;
+   NTSTATUS status;
 
pwd = getpwuid_alloc(mem_ctx, sec_initial_uid());
if (pwd == NULL) {
return NT_STATUS_NO_MEMORY;
}
 
-   return make_serverinfo_from_username(mem_ctx,
+   status = make_serverinfo_from_username(mem_ctx,
 pwd->pw_name,
 false,
 server_info);
+   if (!NT_STATUS_IS_OK(status)) {
+   return status;
+   }
+
+   (*server_info)->system = true;
+
+   return NT_STATUS_OK;
 }
 
 /
@@ -829,6 +837,7 @@ struct auth_serversupplied_info *copy_serverinfo(TALLOC_CTX 
*mem_ctx,
}
 
dst->guest = src->guest;
+   dst->system = src->system;
dst->utok.uid = src->utok.uid;
dst->utok.gid = src->utok.gid;
dst->utok.ngroups = src->utok.ngroups;
diff --git a/source3/include/auth.h b/source3/include/auth.h
index ed422c2..69a91d2 100644
--- a/source3/include/auth.h
+++ b/source3/include/auth.h
@@ -42,6 +42,7 @@ struct auth_usersupplied_info {
 
 struct auth_serversupplied_info {
bool guest;
+   bool system;
 
struct dom_sid *sids;   /* These SIDs are preliminary between
   check_ntlm_password and the token creation. */
diff --git a/source3/rpc_server/srv_netlog_nt.c 
b/source3/rpc_server/srv_netlog_nt.c
index f0b9bab..4bd176c 100644
--- a/source3/rpc_server/srv_netlog_nt.c
+++ b/source3/rpc_server/srv_netlog_nt.c
@@ -27,6 +27,11 @@
 #include "includes.h"
 #include "../libcli/auth/schannel.h"
 #include "../librpc/gen_ndr/srv_netlogon.h"
+#include "../librpc/gen_ndr/srv_samr.h"
+#include "../librpc/gen_ndr/srv_lsa.h"
+#include "../librpc/gen_ndr/cli_samr.h"
+#include "../librpc/gen_ndr/cli_lsa.h"
+#include "rpc_client/cli_lsarpc.h"
 #include "librpc/gen_ndr/messaging.h"
 #include "../lib/crypto/md4.h"
 
@@ -389,39 +394,77 @@ NTSTATUS _netr_NetrEnumerateTrustedDomains(pipes_struct 
*p,
 {
NTSTATUS status;
DATA_BLOB blob;
-   struct trustdom_info **domains;
-   uint32_t num_domains;
-   const char **trusted_domains;
+   int num_domains = 0;
+   const char **trusted_domains = NULL;
+   struct lsa_DomainList domain_list;
+   struct rpc_pipe_client *cli = NULL;
+   struct policy_handle pol;
+   uint32_t enum_ctx = 0;
int i;
+   uint32_t max_size = (uint32_t)-1;
 
DEBUG(6,("_netr_NetrEnumerat

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Günther Deschner
The branch, master has been updated
   via  62708fb... s3:ntlmssp Move ntlmssp_sign.c from source3 to common 
code.
   via  d6fa371... s3:ntlmssp Use a TALLOC_CTX for ntlmssp_sign_packet() 
and ntlmssp_seal_packet()
   via  ebae21f... ntlmssp: Make the ntlmssp.h from source3/ a common header
   via  9a76932... s3:ntlmssp Add two unused variables to match the Samba4 
ntlmssp.h
   via  723ea68... s3:auth Remove AUTH_NTLMSSP_STATE typedef.
   via  3b70686... s3:auth Make AUTH_NTLMSSP_STATE a private structure.
  from  a950c6c... s3:configre: work around shell problem on HP-UX in AC 
macro

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


- Log -
commit 62708fbd1bf6a54d880011ce7d95ee43e08cf30e
Author: Andrew Bartlett 
Date:   Tue May 25 20:58:52 2010 +1000

s3:ntlmssp Move ntlmssp_sign.c from source3 to common code.

This needs a small re-arrangement of the supporting code.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 
Signed-off-by: Günther Deschner 

commit d6fa371b92681a327a86239721fc5990d91ad74f
Author: Andrew Bartlett 
Date:   Tue May 25 20:55:40 2010 +1000

s3:ntlmssp Use a TALLOC_CTX for ntlmssp_sign_packet() and 
ntlmssp_seal_packet()

This ensures the results can't be easily left to leak.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 
Signed-off-by: Günther Deschner 

commit ebae21f0235b957c8faeeb51c926724909d353e9
Author: Andrew Bartlett 
Date:   Tue May 25 20:19:22 2010 +1000

ntlmssp: Make the ntlmssp.h from source3/ a common header

The code is not yet in common, but I hope to fix that soon.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 
Signed-off-by: Günther Deschner 

commit 9a76932ccfe680b9bf224e0dcac7f9cdb7ce9f4e
Author: Andrew Bartlett 
Date:   Tue May 25 19:58:00 2010 +1000

s3:ntlmssp Add two unused variables to match the Samba4 ntlmssp.h

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 
Signed-off-by: Günther Deschner 

commit 723ea68d3b69a9fc31dc02256c4fc323dc9278ce
Author: Andrew Bartlett 
Date:   Tue May 25 15:40:35 2010 +1000

s3:auth Remove AUTH_NTLMSSP_STATE typedef.

typedefs are no longer preferred Samba style.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 
Signed-off-by: Günther Deschner 

commit 3b706865f6bae7a2b04590da160bda939a3bafe5
Author: Andrew Bartlett 
Date:   Tue May 25 15:34:06 2010 +1000

s3:auth Make AUTH_NTLMSSP_STATE a private structure.

This makes it a little easier for it to writen in terms of GENSEC in future.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher 
Signed-off-by: Günther Deschner 

---

Summary of changes:
 libcli/auth/ntlmssp.c |   76 
 libcli/auth/ntlmssp.h |  161 
 libcli/auth/ntlmssp_private.h |   25 ++
 libcli/auth/ntlmssp_sign.c|  573 +
 source3/Makefile.in   |3 +-
 source3/auth/auth_ntlmssp.c   |  115 +-
 source3/include/auth.h|7 +-
 source3/include/ntdomain.h|2 +-
 source3/include/ntlmssp.h |  135 ---
 source3/include/proto.h   |   53 ++--
 source3/libads/sasl.c |8 +-
 source3/libsmb/cliconnect.c   |2 +-
 source3/libsmb/clifsinfo.c|2 +-
 source3/libsmb/ntlmssp.c  |   54 +---
 source3/libsmb/ntlmssp_sign.c |  550 ---
 source3/libsmb/smb_seal.c |   10 +-
 source3/rpc_client/cli_pipe.c |   17 +-
 source3/rpc_server/srv_pipe.c |   81 +++--
 source3/smbd/globals.h|2 +-
 source3/smbd/seal.c   |   13 +-
 source3/smbd/sesssetup.c  |   35 +-
 source3/smbd/smb2_sesssetup.c |   32 +-
 source3/utils/ntlm_auth.c |2 +-
 source3/winbindd/winbindd_ccache_access.c |2 +-
 24 files changed, 1077 insertions(+), 883 deletions(-)
 create mode 100644 libcli/auth/ntlmssp.c
 create mode 100644 libcli/auth/ntlmssp.h
 create mode 100644 libcli/auth/ntlmssp_private.h
 create mode 100644 libcli/auth/ntlmssp_sign.c
 delete mode 100644 source3/include/ntlmssp.h
 delete mode 100644 source3/libsmb/ntlmssp_sign.c


Changeset truncated at 500 lines:

diff --git a/libcli/auth/ntlmssp.c b/libcli/auth/ntlmssp.c
new file mode 100644
index 000..1be764e
--- /dev/null
+++ b/libcli/auth/ntlmssp.c
@@ -0,0 +1,76 @@
+/*
+   Unix SMB/Netbios implementation.
+   Version 3.0
+   handle NLTMSSP, server side
+
+   Copyright (C) Andrew Tridgell  2001
+   Copyright (C) Andrew Bartlett 2001-2003
+   Copyright (C) Andrew Bartlett 2005 (Updated 

Re: [SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Stefan (metze) Metzmacher
Hi Jelmer,

> - Log -
> commit 8c017022dbb78966589fa98e03dea01d91d003b0
> Author: Jelmer Vernooij 
> Date:   Mon May 31 13:55:17 2010 +0200
> 
> talloc: Don't set is_bundled for standalone build.
> 
> commit 151e239bcf2860411527a953d627b2d724c0a57e
> Author: Jelmer Vernooij 
> Date:   Mon May 31 13:51:49 2010 +0200
> 
> ldb/waf: Fix build with system and bundled ldb.

Please test your changes without system libraries,
and make sure it still works.

Currently make bin/smbtorture4 in the merged build gets this:
http://pastie.org/985637

(I assume the s4 build will have the same problem)

metze



signature.asc
Description: OpenPGP digital signature


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Björn Jacke
The branch, master has been updated
   via  a950c6c... s3:configre: work around shell problem on HP-UX in AC 
macro
  from  8c01702... talloc: Don't set is_bundled for standalone build.

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


- Log -
commit a950c6c60097af750d4348cb096fdacb342e9e71
Author: Björn Jacke 
Date:   Mon May 31 14:33:51 2010 +0200

s3:configre: work around shell problem on HP-UX in AC macro

---

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 5532139..6f25be5 100644
--- a/source3/configure.in
+++ b/source3/configure.in
@@ -1864,7 +1864,9 @@ AC_CACHE_CHECK([whether building shared libraries 
actually works],
# variables so they need to be eval'ed.
if AC_TRY_COMMAND([$CC $CPPFLAGS $CFLAGS $PICFLAG -c -o shlib.o 
${srcdir-.}/../tests/shlib.c 1>&AS_MESSAGE_LOG_FD])
then
- if AC_TRY_COMMAND([`eval echo "$SHLD $LDSHFLAGS $PICFLAG"` -o 
"shlib.$SHLIBEXT" shlib.o 1>&AS_MESSAGE_LOG_FD])
+ TESTCMD="`eval echo \"$SHLD $LDSHFLAGS $PICFLAG\"`"
+ TESTCMD="$TESTCMD -o \"shlib.$SHLIBEXT\" shlib.o"
+ if AC_TRY_COMMAND([$TESTCMD 1>&AS_MESSAGE_LOG_FD 2>&1])
  then
ac_cv_shlib_works=yes
  fi


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Jelmer Vernooij
The branch, master has been updated
   via  8c01702... talloc: Don't set is_bundled for standalone build.
   via  151e239... ldb/waf: Fix build with system and bundled ldb.
   via  f89e390... waf: Refactor manpage building code.
   via  f98bb7f... Add manpages argument to SAMBA_LIBRARY().
  from  cc77e79... s4-waf: Fixed the ldb build.

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


- Log -
commit 8c017022dbb78966589fa98e03dea01d91d003b0
Author: Jelmer Vernooij 
Date:   Mon May 31 13:55:17 2010 +0200

talloc: Don't set is_bundled for standalone build.

commit 151e239bcf2860411527a953d627b2d724c0a57e
Author: Jelmer Vernooij 
Date:   Mon May 31 13:51:49 2010 +0200

ldb/waf: Fix build with system and bundled ldb.

commit f89e390fbc6e4f3d8269c40ccab7c718bfcd394f
Author: Jelmer Vernooij 
Date:   Mon May 31 12:17:33 2010 +0200

waf: Refactor manpage building code.

commit f98bb7ffc33bf161caf301c50c55c8e3cc858b85
Author: Jelmer Vernooij 
Date:   Mon May 31 12:08:01 2010 +0200

Add manpages argument to SAMBA_LIBRARY().

---

Summary of changes:
 buildtools/wafsamba/wafsamba.py|   30 ++-
 lib/talloc/wscript |   23 
 source4/lib/ldb/ABI/ldb-samba4-0.9.11.sigs |5 
 source4/lib/ldb/wscript|   26 +++
 4 files changed, 33 insertions(+), 51 deletions(-)


Changeset truncated at 500 lines:

diff --git a/buildtools/wafsamba/wafsamba.py b/buildtools/wafsamba/wafsamba.py
index 41b866d..01e2ce8 100644
--- a/buildtools/wafsamba/wafsamba.py
+++ b/buildtools/wafsamba/wafsamba.py
@@ -116,6 +116,7 @@ def SAMBA_LIBRARY(bld, libname, source,
   abi_match=None,
   hide_symbols=False,
   is_bundled=False,
+  manpages=None,
   enabled=True):
 '''define a Samba library'''
 
@@ -196,7 +197,7 @@ def SAMBA_LIBRARY(bld, libname, source,
 vnum= vnum,
 install_path= None,
 samba_inst_path = install_path,
-name   = libname,
+name= libname,
 samba_realname  = realname,
 samba_install   = install,
 abi_file= abi_file,
@@ -212,6 +213,10 @@ def SAMBA_LIBRARY(bld, libname, source,
 if pc_files is not None:
 bld.PKG_CONFIG_FILES(pc_files, vnum=vnum)
 
+if manpages is not None and 'XSLTPROC' in bld.env:
+bld.MANPAGES(manpages)
+
+
 Build.BuildContext.SAMBA_LIBRARY = SAMBA_LIBRARY
 
 
@@ -300,15 +305,7 @@ def SAMBA_BINARY(bld, binname, source,
 bld.TARGET_ALIAS(subsystem_name, binname)
 
 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'
-bld.SAMBA_GENERATOR(m,
-source=source,
-target=m,
-rule='${XSLTPROC} -o ${TGT} ${MAN_XSL} ${SRC}'
-)
-bld.INSTALL_FILES('${MANDIR}/man%s' % m[-1], m, flat=True)
+bld.MANPAGES(manpages)
 
 Build.BuildContext.SAMBA_BINARY = SAMBA_BINARY
 
@@ -813,6 +810,19 @@ def PKG_CONFIG_FILES(bld, pc_files, vnum=None):
 Build.BuildContext.PKG_CONFIG_FILES = PKG_CONFIG_FILES
 
 
+def MANPAGES(bld, manpages):
+'''build and install manual pages'''
+bld.env.MAN_XSL = 
'http://docbook.sourceforge.net/release/xsl/current/manpages/docbook.xsl'
+for m in manpages.split():
+source = m + '.xml'
+bld.SAMBA_GENERATOR(m,
+source=source,
+target=m,
+rule='${XSLTPROC} -o ${TGT} ${MAN_XSL} ${SRC}'
+)
+bld.INSTALL_FILES('${MANDIR}/man%s' % m[-1], m, flat=True)
+Build.BuildContext.MANPAGES = MANPAGES
+
 
 #
 # give a nicer display when building different types of files
diff --git a/lib/talloc/wscript b/lib/talloc/wscript
index 61930f6..be80b27 100644
--- a/lib/talloc/wscript
+++ b/lib/talloc/wscript
@@ -60,14 +60,17 @@ def build(bld):
   abi_file='ABI/talloc-%s.sigs' % VERSION,
   abi_match='talloc* _talloc*',
   hide_symbols=True,
-  vnum=VERSION, is_bundled=True)
+  vnum=VERSION,
+ is_bundled=not 
bld.env.standalone_talloc, 
+ manpages='talloc.3')
 
 # should we also install the symlink to libtalloc1.so here?
 bld.SAMBA_LIBRARY('talloc-compat1',
   

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Andreas Schneider
The branch, master has been updated
   via  cc77e79... s4-waf: Fixed the ldb build.
  from  11e2608... s3/s4:netrEnumerateTrustedDomains - this call returns a 
"NTSTATUS" result

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


- Log -
commit cc77e7966ea95ccc0812dd772a9002b41792e6b8
Author: Stefan Metzmacher 
Date:   Mon May 31 12:51:58 2010 +0200

s4-waf: Fixed the ldb build.

---

Summary of changes:
 source4/lib/ldb/wscript |6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source4/lib/ldb/wscript b/source4/lib/ldb/wscript
index 0282073..15740d6 100644
--- a/source4/lib/ldb/wscript
+++ b/source4/lib/ldb/wscript
@@ -48,9 +48,9 @@ def configure(conf):
 if conf.env.standalone_ldb:
 conf.find_program('xsltproc', var='XSLTPROC')
 
-# we need this for the ldap backend
-if conf.CHECK_FUNCS_IN('ber_flush ldap_open ldap_initialize', 'lber ldap', 
headers='lber.h ldap.h'):
-conf.env.ENABLE_LDAP_BACKEND = True
+# we need this for the ldap backend
+if conf.CHECK_FUNCS_IN('ber_flush ldap_open ldap_initialize', 'lber 
ldap', headers='lber.h ldap.h'):
+conf.env.ENABLE_LDAP_BACKEND = True
 
 conf.DEFINE('HAVE_CONFIG_H', 1, add_to_cflags=True)
 


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Matthias Dieter Wallnöfer
The branch, master has been updated
   via  11e2608... s3/s4:netrEnumerateTrustedDomains - this call returns a 
"NTSTATUS" result
  from  0eec334... s4:dcesrv_netr_DsrEnumerateDomainTrusts - fix an integer 
type

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


- Log -
commit 11e2608ba97018987b0143521248a83b2dab07e6
Author: Matthias Dieter Wallnöfer 
Date:   Mon May 31 10:15:25 2010 +0200

s3/s4:netrEnumerateTrustedDomains - this call returns a "NTSTATUS" result

See MS-NRPC 3.5.5.6.3.

---

Summary of changes:
 librpc/idl/netlogon.idl   |2 +-
 source3/rpc_server/srv_netlog_nt.c|   14 +++---
 source3/rpcclient/cmd_netlogon.c  |   22 +-
 source4/rpc_server/netlogon/dcerpc_netlogon.c |4 ++--
 source4/torture/rpc/netlogon.c|2 +-
 5 files changed, 20 insertions(+), 24 deletions(-)


Changeset truncated at 500 lines:

diff --git a/librpc/idl/netlogon.idl b/librpc/idl/netlogon.idl
index 4bebb83..7670d34 100644
--- a/librpc/idl/netlogon.idl
+++ b/librpc/idl/netlogon.idl
@@ -1080,7 +1080,7 @@ interface netlogon
[size_is(length)] uint8 *data;
} netr_Blob;
 
-   WERROR netr_NetrEnumerateTrustedDomains(
+   NTSTATUS netr_NetrEnumerateTrustedDomains(
[in,unique] [string,charset(UTF16)] uint16 *server_name,
[out,ref] netr_Blob *trusted_domains_blob
);
diff --git a/source3/rpc_server/srv_netlog_nt.c 
b/source3/rpc_server/srv_netlog_nt.c
index ec6ade6..f0b9bab 100644
--- a/source3/rpc_server/srv_netlog_nt.c
+++ b/source3/rpc_server/srv_netlog_nt.c
@@ -384,8 +384,8 @@ WERROR _netr_LogonControl2Ex(pipes_struct *p,
  _netr_NetrEnumerateTrustedDomains
  */
 
-WERROR _netr_NetrEnumerateTrustedDomains(pipes_struct *p,
-struct 
netr_NetrEnumerateTrustedDomains *r)
+NTSTATUS _netr_NetrEnumerateTrustedDomains(pipes_struct *p,
+  struct 
netr_NetrEnumerateTrustedDomains *r)
 {
NTSTATUS status;
DATA_BLOB blob;
@@ -403,25 +403,25 @@ WERROR _netr_NetrEnumerateTrustedDomains(pipes_struct *p,
unbecome_root();
 
if (!NT_STATUS_IS_OK(status)) {
-   return ntstatus_to_werror(status);
+   return status;
}
 
trusted_domains = talloc_zero_array(p->mem_ctx, const char *, 
num_domains + 1);
if (!trusted_domains) {
-   return WERR_NOMEM;
+   return NT_STATUS_NO_MEMORY;
}
 
for (i = 0; i < num_domains; i++) {
trusted_domains[i] = talloc_strdup(trusted_domains, 
domains[i]->name);
if (!trusted_domains[i]) {
TALLOC_FREE(trusted_domains);
-   return WERR_NOMEM;
+   return NT_STATUS_NO_MEMORY;
}
}
 
if (!push_reg_multi_sz(trusted_domains, &blob, trusted_domains)) {
TALLOC_FREE(trusted_domains);
-   return WERR_NOMEM;
+   return NT_STATUS_NO_MEMORY;
}
 
r->out.trusted_domains_blob->data = blob.data;
@@ -429,7 +429,7 @@ WERROR _netr_NetrEnumerateTrustedDomains(pipes_struct *p,
 
DEBUG(6,("_netr_NetrEnumerateTrustedDomains: %d\n", __LINE__));
 
-   return WERR_OK;
+   return NT_STATUS_OK;
 }
 
 /**
diff --git a/source3/rpcclient/cmd_netlogon.c b/source3/rpcclient/cmd_netlogon.c
index 262975b..faa2bff 100644
--- a/source3/rpcclient/cmd_netlogon.c
+++ b/source3/rpcclient/cmd_netlogon.c
@@ -938,19 +938,18 @@ static WERROR cmd_netlogon_dsr_getforesttrustinfo(struct 
rpc_pipe_client *cli,
return werr;
 }
 
-static WERROR cmd_netlogon_enumtrusteddomains(struct rpc_pipe_client *cli,
- TALLOC_CTX *mem_ctx, int argc,
- const char **argv)
+static NTSTATUS cmd_netlogon_enumtrusteddomains(struct rpc_pipe_client *cli,
+   TALLOC_CTX *mem_ctx, int argc,
+   const char **argv)
 {
NTSTATUS status = NT_STATUS_UNSUCCESSFUL;
-   WERROR werr = WERR_GENERAL_FAILURE;
const char *server_name = cli->desthost;
struct netr_Blob blob;
 
 
if (argc < 1 || argc > 3) {
fprintf(stderr, "Usage: %s \n", argv[0]);
-   return WERR_OK;
+   return NT_STATUS_OK;
}
 
if (argc >= 2) {
@@ -959,18 +958,15 @@ static WERROR cmd_netlogon_enumtrusteddomains(struct 
rpc_pipe_client *cli,
 
status = rpccli_netr_NetrEnumerateTrustedDomains(cli, mem_ctx,
  

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Matthias Dieter Wallnöfer
The branch, master has been updated
   via  0eec334... s4:dcesrv_netr_DsrEnumerateDomainTrusts - fix an integer 
type
   via  aaf1c75... s4:torture/rpc/netlogon.c - add another 
"LogonGetDomainInfo" testcase
  from  3e0b2c8... s3: Fix some debug messages

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


- Log -
commit 0eec33417eb56d1352fd66565f55162c62d86fcd
Author: Matthias Dieter Wallnöfer 
Date:   Mon May 31 12:01:34 2010 +0200

s4:dcesrv_netr_DsrEnumerateDomainTrusts - fix an integer type

commit aaf1c751f4cf447d80ef9dae341ef3247c1607e2
Author: Matthias Dieter Wallnöfer 
Date:   Tue Apr 27 15:58:45 2010 +0200

s4:torture/rpc/netlogon.c - add another "LogonGetDomainInfo" testcase

Mark it as dangerous since it does break some target systems.

---

Summary of changes:
 source4/rpc_server/netlogon/dcerpc_netlogon.c |2 +-
 source4/torture/rpc/netlogon.c|   17 +
 2 files changed, 18 insertions(+), 1 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source4/rpc_server/netlogon/dcerpc_netlogon.c 
b/source4/rpc_server/netlogon/dcerpc_netlogon.c
index c57f414..cfcb4f6 100644
--- a/source4/rpc_server/netlogon/dcerpc_netlogon.c
+++ b/source4/rpc_server/netlogon/dcerpc_netlogon.c
@@ -1980,7 +1980,7 @@ static WERROR dcesrv_netr_DsrEnumerateDomainTrusts(struct 
dcesrv_call_state *dce
 
/* NOTE: we currently are always the root of the forest */
if (r->in.trust_flags & NETR_TRUST_FLAG_IN_FOREST) {
-   int n = trusts->count;
+   uint32_t n = trusts->count;
 
ret = gendb_search_dn(sam_ctx, mem_ctx, NULL,
  &dom_res, dom_attrs);
diff --git a/source4/torture/rpc/netlogon.c b/source4/torture/rpc/netlogon.c
index 96ae4c0..b1d6d1b 100644
--- a/source4/torture/rpc/netlogon.c
+++ b/source4/torture/rpc/netlogon.c
@@ -3150,6 +3150,23 @@ static bool test_GetDomainInfo(struct torture_context 
*tctx,
&& (info.domain_info->trusted_domains != NULL),
"Trusted domains have been requested!");
 
+
+   if (!torture_setting_bool(tctx, "dangerous", false)) {
+   torture_comment(tctx, "Not testing netr_LogonGetDomainInfo 6th 
call (no workstation info) - enable dangerous tests in order to do so\n");
+   } else {
+   /* Try a call without the workstation information structure */
+
+   torture_comment(tctx, "Testing netr_LogonGetDomainInfo 6th call 
(no workstation info)\n");
+   netlogon_creds_client_authenticator(creds, &a);
+
+   query.workstation_info = NULL;
+
+   torture_assert_ntstatus_ok(tctx, 
dcerpc_netr_LogonGetDomainInfo_r(b, tctx, &r),
+   "LogonGetDomainInfo failed");
+   torture_assert_ntstatus_ok(tctx, r.out.result, 
"LogonGetDomainInfo failed");
+   torture_assert(tctx, netlogon_creds_client_check(creds, 
&a.cred), "Credential chaining failed");
+   }
+
return true;
 }
 


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Volker Lendecke
The branch, master has been updated
   via  3e0b2c8... s3: Fix some debug messages
   via  2e4c414... s3: Don't announce readraw and writeraw with the async 
echo responder
  from  82e140c... s3: use shared security defines.

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


- Log -
commit 3e0b2c8c9ae557e615fe3551f561a622c1fa29cd
Author: Volker Lendecke 
Date:   Wed May 26 17:52:10 2010 +0200

s3: Fix some debug messages

commit 2e4c41431e18ed68f0965cdb128d67b008f81389
Author: Volker Lendecke 
Date:   Wed May 26 17:47:37 2010 +0200

s3: Don't announce readraw and writeraw with the async echo responder

---

Summary of changes:
 source3/include/proto.h  |2 ++
 source3/param/loadparm.c |   20 ++--
 source3/smbd/reply.c |8 
 3 files changed, 24 insertions(+), 6 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/include/proto.h b/source3/include/proto.h
index ee6f09a..bd39973 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -3947,8 +3947,10 @@ const char **lp_init_logon_delayed_hosts(void);
 int lp_init_logon_delay(void);
 bool lp_load_printers(void);
 bool lp_readraw(void);
+bool _lp_readraw(void);
 bool lp_large_readwrite(void);
 bool lp_writeraw(void);
+bool _lp_writeraw(void);
 bool lp_null_passwords(void);
 bool lp_obey_pam_restrictions(void);
 bool lp_encrypted_passwords(void);
diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c
index ba9d816..2d389d4 100644
--- a/source3/param/loadparm.c
+++ b/source3/param/loadparm.c
@@ -5569,9 +5569,9 @@ FN_GLOBAL_BOOL(lp_domain_logons, &Globals.bDomainLogons)
 FN_GLOBAL_LIST(lp_init_logon_delayed_hosts, &Globals.szInitLogonDelayedHosts)
 FN_GLOBAL_INTEGER(lp_init_logon_delay, &Globals.InitLogonDelay)
 FN_GLOBAL_BOOL(lp_load_printers, &Globals.bLoadPrinters)
-FN_GLOBAL_BOOL(lp_readraw, &Globals.bReadRaw)
+FN_GLOBAL_BOOL(_lp_readraw, &Globals.bReadRaw)
 FN_GLOBAL_BOOL(lp_large_readwrite, &Globals.bLargeReadwrite)
-FN_GLOBAL_BOOL(lp_writeraw, &Globals.bWriteRaw)
+FN_GLOBAL_BOOL(_lp_writeraw, &Globals.bWriteRaw)
 FN_GLOBAL_BOOL(lp_null_passwords, &Globals.bNullPasswords)
 FN_GLOBAL_BOOL(lp_obey_pam_restrictions, &Globals.bObeyPamRestrictions)
 FN_GLOBAL_BOOL(lp_encrypted_passwords, &Globals.bEncryptPasswords)
@@ -10021,3 +10021,19 @@ bool lp_widelinks(int snum)
 
return lp_widelinks_internal(snum);
 }
+
+bool lp_writeraw(void)
+{
+   if (lp_async_smb_echo_handler()) {
+   return false;
+   }
+   return _lp_writeraw();
+}
+
+bool lp_readraw(void)
+{
+   if (lp_async_smb_echo_handler()) {
+   return false;
+   }
+   return _lp_readraw();
+}
diff --git a/source3/smbd/reply.c b/source3/smbd/reply.c
index 8aa1633..5107b1a 100644
--- a/source3/smbd/reply.c
+++ b/source3/smbd/reply.c
@@ -3055,8 +3055,8 @@ void reply_readbraw(struct smb_request *req)
}
 
if (smbd_server_conn->smb1.echo_handler.trusted_fde) {
-   DEBUG(2,("SMBreadbraw rejected with NOT_SUPPORTED because of"
-"'fork echo handler = yes'\n"));
+   DEBUG(2,("SMBreadbraw rejected with NOT_SUPPORTED because of "
+"'async smb echo handler = yes'\n"));
reply_readbraw_error();
END_PROFILE(SMBreadbraw);
return;
@@ -3787,8 +3787,8 @@ void reply_writebraw(struct smb_request *req)
}
 
if (smbd_server_conn->smb1.echo_handler.trusted_fde) {
-   DEBUG(2,("SMBwritebraw rejected with NOT_SUPPORTED because of"
-"'fork echo handler = yes'\n"));
+   DEBUG(2,("SMBwritebraw rejected with NOT_SUPPORTED because of "
+"'async smb echo handler = yes'\n"));
reply_nterror(req, NT_STATUS_NOT_SUPPORTED);
error_to_writebrawerr(req);
END_PROFILE(SMBwritebraw);


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Günther Deschner
The branch, master has been updated
   via  82e140c... s3: use shared security defines.
  from  fbb7814... s3: only use netlogon/nbt header when needed.

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


- Log -
commit 82e140c04562c1480d8ae1d6cb68d510824a1a1c
Author: Günther Deschner 
Date:   Fri May 28 03:31:52 2010 +0200

s3: use shared security defines.

Guenther

---

Summary of changes:
 source3/include/rpc_secdes.h |   15 ---
 source3/libads/disp_sec.c|   28 ++--
 2 files changed, 14 insertions(+), 29 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/include/rpc_secdes.h b/source3/include/rpc_secdes.h
index 74c22fc..e21767e 100644
--- a/source3/include/rpc_secdes.h
+++ b/source3/include/rpc_secdes.h
@@ -22,21 +22,6 @@
 #define _RPC_SECDES_H 
 
 /* for ADS */
-#defineSEC_RIGHTS_LIST_CONTENTS0x4
-#define SEC_RIGHTS_LIST_OBJECT 0x80
-#defineSEC_RIGHTS_READ_ALL_PROP0x10
-#defineSEC_RIGHTS_READ_PERMS   0x2
-#define SEC_RIGHTS_WRITE_ALL_VALID 0x8
-#defineSEC_RIGHTS_WRITE_ALL_PROP   0x20 
-#define SEC_RIGHTS_MODIFY_OWNER0x8
-#defineSEC_RIGHTS_MODIFY_PERMS 0x4
-#defineSEC_RIGHTS_CREATE_CHILD 0x1
-#defineSEC_RIGHTS_DELETE_CHILD 0x2
-#define SEC_RIGHTS_DELETE_SUBTREE  0x40
-#define SEC_RIGHTS_DELETE   0x1 /* 
advanced/special/object/delete */
-#define SEC_RIGHTS_EXTENDED0x100 /* change/reset password, 
receive/send as*/
-#defineSEC_RIGHTS_CHANGE_PASSWDSEC_RIGHTS_EXTENDED
-#defineSEC_RIGHTS_RESET_PASSWD SEC_RIGHTS_EXTENDED
 #define SEC_RIGHTS_FULL_CTRL   0xf01ff
 
 /*
diff --git a/source3/libads/disp_sec.c b/source3/libads/disp_sec.c
index f8489e1..ad07ffc 100644
--- a/source3/libads/disp_sec.c
+++ b/source3/libads/disp_sec.c
@@ -27,26 +27,26 @@ static struct perm_mask_str {
 } perms[] = {
{SEC_RIGHTS_FULL_CTRL,  "[Full Control]"},
 
-   {SEC_RIGHTS_LIST_CONTENTS,  "[List Contents]"},
-   {SEC_RIGHTS_LIST_OBJECT,"[List Object]"},
+   {SEC_ADS_LIST,  "[List Contents]"},
+   {SEC_ADS_LIST_OBJECT,   "[List Object]"},
 
-   {SEC_RIGHTS_READ_ALL_PROP,  "[Read All Properties]"},   
-   {SEC_RIGHTS_READ_PERMS, "[Read Permissions]"},  
+   {SEC_ADS_READ_PROP, "[Read All Properties]"},
+   {SEC_STD_READ_CONTROL,  "[Read Permissions]"},
 
-   {SEC_RIGHTS_WRITE_ALL_VALID,"[All validate writes]"},
-   {SEC_RIGHTS_WRITE_ALL_PROP, "[Write All Properties]"},
+   {SEC_ADS_SELF_WRITE,"[All validate writes]"},
+   {SEC_ADS_WRITE_PROP,"[Write All Properties]"},
 
-   {SEC_RIGHTS_MODIFY_PERMS,   "[Modify Permissions]"},
-   {SEC_RIGHTS_MODIFY_OWNER,   "[Modify Owner]"},
+   {SEC_STD_WRITE_DAC, "[Modify Permissions]"},
+   {SEC_STD_WRITE_OWNER,   "[Modify Owner]"},
 
-   {SEC_RIGHTS_CREATE_CHILD,   "[Create All Child Objects]"},
+   {SEC_ADS_CREATE_CHILD,  "[Create All Child Objects]"},
 
-   {SEC_RIGHTS_DELETE, "[Delete]"},
-   {SEC_RIGHTS_DELETE_SUBTREE, "[Delete Subtree]"},
-   {SEC_RIGHTS_DELETE_CHILD,   "[Delete All Child Objects]"},
+   {SEC_STD_DELETE,"[Delete]"},
+   {SEC_ADS_DELETE_TREE,   "[Delete Subtree]"},
+   {SEC_ADS_DELETE_CHILD,  "[Delete All Child Objects]"},
 
-   {SEC_RIGHTS_CHANGE_PASSWD,  "[Change Password]"},   
-   {SEC_RIGHTS_RESET_PASSWD,   "[Reset Password]"},
+   {SEC_ADS_CONTROL_ACCESS,"[Change Password]"},
+   {SEC_ADS_CONTROL_ACCESS,"[Reset Password]"},
 
{0, 0}
 };


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Günther Deschner
The branch, master has been updated
   via  fbb7814... s3: only use netlogon/nbt header when needed.
   via  f9f8007... s3-build: only use ndr_security.h where needed.
   via  c00407b... libcli/nbt/lmhosts: fix missing prototype warning.
  from  7426cf4... s3: remove prototype of non-existsing function 
idmap_tdb_tdb_close().

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


- Log -
commit fbb7814f91f85e95769a5e23506825167b44139f
Author: Günther Deschner 
Date:   Tue May 18 19:40:31 2010 +0200

s3: only use netlogon/nbt header when needed.

Guenther

commit f9f8007361583c1d38be7e15eeae6b58a09614b3
Author: Günther Deschner 
Date:   Fri May 28 02:19:32 2010 +0200

s3-build: only use ndr_security.h where needed.

Guenther

commit c00407bd3589e9a459014ddb0efd986b15d2eecc
Author: Günther Deschner 
Date:   Fri May 28 03:04:45 2010 +0200

libcli/nbt/lmhosts: fix missing prototype warning.

Andrew, please check.

Guenther

---

Summary of changes:
 libcli/nbt/lmhosts.c  |1 +
 libgpo/gpo_util.c |1 +
 source3/include/client.h  |2 ++
 source3/include/includes.h|1 -
 source3/include/proto.h   |   25 -
 source3/lib/secdesc.c |1 +
 source3/lib/sharesec.c|1 +
 source3/lib/util_sid.c|1 +
 source3/libads/cldap.c|1 +
 source3/libads/cldap.h|   12 
 source3/libads/ldap.c |1 +
 source3/libsmb/clidgram.c |1 +
 source3/libsmb/clidgram.h |   16 
 source3/libsmb/cliquota.c |1 +
 source3/libsmb/dsgetdcname.c  |2 ++
 source3/libsmb/namequery.c|1 +
 source3/modules/vfs_acl_common.c  |2 ++
 source3/nmbd/nmbd_lmhosts.c   |1 +
 source3/passdb/lookup_sid.c   |1 +
 source3/printing/nt_printing.c|1 +
 source3/registry/reg_api.c|1 +
 source3/registry/regfio.c |1 +
 source3/rpc_server/srv_spoolss_util.c |1 +
 source3/rpc_server/srv_srvsvc_nt.c|1 +
 source3/rpc_server/srv_svcctl_nt.c|1 +
 source3/smbd/file_access.c|1 +
 source3/smbd/nttrans.c|1 +
 source3/smbd/open.c   |1 +
 source3/smbd/smb2_create.c|1 +
 source3/smbd/trans2.c |1 +
 source3/utils/net_ads.c   |1 +
 source3/utils/net_printing.c  |1 +
 source3/utils/net_rpc_registry.c  |1 +
 source3/winbindd/idmap_adex/gc_util.c |1 +
 source3/winbindd/wb_group_members.c   |1 +
 source3/winbindd/winbindd_cm.c|1 +
 source3/winbindd/winbindd_ndr.c   |1 +
 37 files changed, 64 insertions(+), 26 deletions(-)
 create mode 100644 source3/libads/cldap.h
 create mode 100644 source3/libsmb/clidgram.h


Changeset truncated at 500 lines:

diff --git a/libcli/nbt/lmhosts.c b/libcli/nbt/lmhosts.c
index 317ccc5..3e746f0 100644
--- a/libcli/nbt/lmhosts.c
+++ b/libcli/nbt/lmhosts.c
@@ -26,6 +26,7 @@
 #include "lib/util/util_net.h"
 #include "system/filesys.h"
 #include "system/network.h"
+#include "../libcli/nbt/libnbt.h"
 
 /
  Start parsing the lmhosts file.
diff --git a/libgpo/gpo_util.c b/libgpo/gpo_util.c
index ef16329..0afed55 100644
--- a/libgpo/gpo_util.c
+++ b/libgpo/gpo_util.c
@@ -19,6 +19,7 @@
 #define TALLOC_DEPRECATED 1
 #include "includes.h"
 #include "librpc/gen_ndr/ndr_misc.h"
+#include "../librpc/gen_ndr/ndr_security.h"
 #include "../libgpo/gpo.h"
 #if _SAMBA_BUILD_ == 4
 #include "system/filesys.h"
diff --git a/source3/include/client.h b/source3/include/client.h
index 71232b3..c245f55 100644
--- a/source3/include/client.h
+++ b/source3/include/client.h
@@ -22,6 +22,8 @@
 #ifndef _CLIENT_H
 #define _CLIENT_H
 
+#include "../librpc/ndr/libndr.h"
+
 /* the client asks for a smaller buffer to save ram and also to get more
overlap on the wire. This size gives us a nice read/write size, which
will be a multiple of the page size on almost any system */
diff --git a/source3/include/includes.h b/source3/include/includes.h
index be3b66f..de1d419 100644
--- a/source3/include/includes.h
+++ b/source3/include/includes.h
@@ -656,7 +656,6 @@ struct ntlmssp_state;
 
 #include "auth.h"
 #include "ntdomain.h"
-#include "librpc/gen_ndr/ndr_nbt.h"
 #include "librpc/rpc/dcerpc.h"
 #include "nt_printing.h"
 #include "idmap.h"
diff --git a/source3/include/proto.h b/source3/include/proto.h
index 5589eee..ee6f09a 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -1759,17 +1759,6 @@ NTSTATUS kerberos_return_pac(TALLOC_CTX *mem_ctx,
 const

[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Michael Adam
The branch, master has been updated
   via  7426cf4... s3: remove prototype of non-existsing function 
idmap_tdb_tdb_close().
  from  e3997c2... wafsamba: Correctly detect if bld.env.XSLTPROC is not set

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


- Log -
commit 7426cf4306e84c994f3903b4b867cc76c45574be
Author: Michael Adam 
Date:   Mon May 31 10:30:15 2010 +0200

s3: remove prototype of non-existsing function idmap_tdb_tdb_close().

---

Summary of changes:
 source3/include/proto.h |1 -
 1 files changed, 0 insertions(+), 1 deletions(-)


Changeset truncated at 500 lines:

diff --git a/source3/include/proto.h b/source3/include/proto.h
index b018a45..5589eee 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -6497,7 +6497,6 @@ NTSTATUS idmap_passdb_init(void);
 
 /* The following definitions come from winbindd/idmap_tdb.c  */
 
-bool idmap_tdb_tdb_close(TDB_CONTEXT *tdbctx);
 NTSTATUS idmap_alloc_tdb_init(void);
 NTSTATUS idmap_tdb_init(void);
 


-- 
Samba Shared Repository


[SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Kai Blin
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


Re: [SCM] Samba Shared Repository - branch master updated

2010-05-31 Thread Stefan (metze) Metzmacher
Hi Jelmer,

> diff --git a/lib/talloc/wscript b/lib/talloc/wscript
> index 3a87506..61930f6 100644
> --- a/lib/talloc/wscript
> +++ b/lib/talloc/wscript
> @@ -60,14 +60,14 @@ def build(bld):
>abi_file='ABI/talloc-%s.sigs' % VERSION,
>abi_match='talloc* _talloc*',
>hide_symbols=True,
> -  vnum=VERSION)
> +  vnum=VERSION, is_bundled=True)
>  
>  # should we also install the symlink to libtalloc1.so here?
>  bld.SAMBA_LIBRARY('talloc-compat1',
>'compat/talloc_compat1.c',
>deps='talloc',
>enabled = bld.env.TALLOC_COMPAT1,
> -  vnum=VERSION)
> +  vnum=VERSION, is_bundled=True)
>

shouldn't we use 'not bld.env.standalone_talloc' instead of 'True'
here too?

metze



signature.asc
Description: OpenPGP digital signature