[Samba] ldapsam:editposix
Hello list, I'm trying to setup Samba to use: ldapsam:editposix = yes but I'm having problems to add users via smbpasswd -a. It seems smbpasswd tries to modify an existing entry (and falling of course) instead of adding a new entry. Is that a bug, a configuration problem, or intended behavior? Do I need to create a postixaccount entry prior to use smbpasswd -a? Thanks in advance, Norberto This message was sent using IMP, the Internet Messaging Program. -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/listinfo/samba
Re: [Samba] Re: In place upgrade
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 Rubin Bennett wrote: On Fri, 2008-10-10 at 13:56 +0100, Kristian Davies wrote: For a system installed without a package manager (i.e. make install), then you make a copy of your passdb.tdb, secrets.tdb and smb.conf, upgrade, and put those 3 files back in. That's the puppy. So, stop services, mv sambadir, install new version afresh, copy over those three files and start services. Will that affect the machines AD machine account with sid's etc... or is that why the secrets.tdb are copied over? That's why secrets.tdb is copied over. However, if you're changing machines or upgrading OS at the same time, you'll need to copy the user/ machine entries in /etc/passwd, /etc/group and /etc/shadow as well or you'll get lots of ugly messages about your password database being corrupt. If you're moving machines, you have to also worry about the other persistent TDB's. You can lose all of your printers/forms/etc. otherwise. - -- _ _ _ _ ___ _ _ _ |Y#| | | |\/| | \ |\ | | |Ryan Novosielski - Systems Programmer II |$| |__| | | |__/ | \| _| |[EMAIL PROTECTED] - 973/972.0922 (2-0922) \__/ Univ. of Med. and Dent.|IST/AST - NJMS Medical Science Bldg - C630 -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.6 (GNU/Linux) Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org iD8DBQFI8SVJmb+gadEcsb4RAk8QAKCZA7DaFH4F40RYwAg28lSnJsVpkACfbMmj HBEBF2R1aRjgNN2hM83dg8I= =wqXf -END PGP SIGNATURE- -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/listinfo/samba
Re: [Samba] ldapsam:editposix
Sent this direct to the poster again, and not to the list. Here it is for the list. On 12/10/2008, at 3:53 AM, Norberto Bensa wrote: Hello list, I'm trying to setup Samba to use: ldapsam:editposix = yes but I'm having problems to add users via smbpasswd -a. It seems smbpasswd tries to modify an existing entry (and falling of course) instead of adding a new entry. Is that a bug, a configuration problem, or intended behavior? Do I need to create a postixaccount entry prior to use smbpasswd -a? Yes, you do. Or, at least, that's the way I've always had to do it. I have a small script with an LDAP template that makes the minimal entries in the ldap for a posixAccount and shadowAccount for the user, then create the samba account. -- Matt Skerritt [EMAIL PROTECTED] -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/listinfo/samba
[Samba] Compile help for Solaris 10 x86, samba 3.0.28a deficient?
Hi all, I've got an ongoing battle with samba shipped with Sun Solaris 10 in it's current form (Samba version 3.0.28a) not wanting to talk to my OpenLDAP master correctly. Essentially, under certain conditions, this behaviour is observed, in the log.smbd: [2008/10/11 08:54:03, 1, pid=13610] libsmb/cliconnect.c:(1451) Error connecting to 192.168.117.150 (Connection refused) [2008/10/11 08:54:03, 0, pid=13610] auth/auth_server.c:(89) password server not available [2008/10/11 08:54:03, 1, pid=13610] auth/auth_server.c:(247) password server is not connected (cli not initilised) So, I went about logging this at a much more verbose level, which hasn't really gotten me anywhere. I can't find an answer to what these errors actually mean - and the only google hits on this specific problem are my own posts. I thought, What if they have changed the way SPNEGO works in Mac OS X 10.5.5's implementation of their directory/kerberos KDC? I then thought that maybe Samba 3.0.28a (only a hunch, no way to prove it) just wasn't up to the task, and that I should try compiling 3.2.4 for my hosts. I gave it a good shot. A really good shot - been at it for a week now, with no joy. Thanks to all those here who have tried to help out with it too! I am looking for some very basic instructions with regard to compiling samba. I want to compile Samba for Solaris 10 x86, with krb5 support, with aio support. I don't really want or need ADS. Unfortunately, try as I might, just hasn't panned out this way. Every step of the way, something has gone wrong. If someone could help me out from first principles with the basics, such as the influential environmental variables : CC C compiler command CFLAGS C compiler flags LDFLAGS linker flags, e.g. -Llib dir if you have libraries in a nonstandard directory lib dir LIBSlibraries to pass to the linker, e.g. -llibrary CPPFLAGSC/C++/Objective C preprocessor flags, e.g. -Iinclude dir if you have headers in a nonstandard directory include dir CPP C preprocessor ...and actually getting Solaris default/vanilla krb5 to configure, make, make install correctly when one specifies --with-krb5=/usr/lib/ krb5, this would be most appreciated. Not even sure if I should be using Sun Studio compiler or GCC. I sort of hoped that somebody would release pre-built binaries for Sol 10 x86, unfortunately, all I can find on samba.org is a long way out of date SPARC binary of 3.0.23. Thanks for your time. JC -- To unsubscribe from this list go to the following URL and read the instructions: https://lists.samba.org/mailman/listinfo/samba
[SCM] Samba Shared Repository - branch v3-3-test updated - release-3-2-0pre2-4252-gd0f7261
The branch, v3-3-test has been updated via d0f7261031f76965879036bd5c7d0a19eabf47cc (commit) via 5f48a925a25a08d6c2077906eec439e49b51070a (commit) via 5822bb7458331c5d52a5a4cb0906777e1f7e3b8d (commit) from cb23dddc723084ca9f8d8eca6c78ee87d903e60c (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=v3-3-test - Log - commit d0f7261031f76965879036bd5c7d0a19eabf47cc Author: Volker Lendecke [EMAIL PROTECTED] Date: Fri Oct 10 23:40:50 2008 +0200 Make use of talloc_tos() commit 5f48a925a25a08d6c2077906eec439e49b51070a Author: Volker Lendecke [EMAIL PROTECTED] Date: Fri Oct 10 17:50:09 2008 +0200 Fix some nonempty blank lines commit 5822bb7458331c5d52a5a4cb0906777e1f7e3b8d Author: Volker Lendecke [EMAIL PROTECTED] Date: Fri Oct 10 16:26:34 2008 +0200 Fix a nexted extern declaration warning --- Summary of changes: source/smbd/connection.c | 38 +++--- source/smbd/ipc.c| 12 ++-- source/smbd/nttrans.c|2 +- 3 files changed, 26 insertions(+), 26 deletions(-) Changeset truncated at 500 lines: diff --git a/source/smbd/connection.c b/source/smbd/connection.c index 8dd5964..fd83f77 100644 --- a/source/smbd/connection.c +++ b/source/smbd/connection.c @@ -2,17 +2,17 @@ Unix SMB/CIFS implementation. connection claim routines Copyright (C) Andrew Tridgell 1998 - + This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. - + This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - + You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/. */ @@ -63,7 +63,7 @@ static int count_fn(struct db_record *rec, void *udp) { struct count_stat *cs = (struct count_stat *)udp; - + if (crec-cnum == -1) { return 0; } @@ -159,7 +159,7 @@ bool claim_connection(connection_struct *conn, const char *name, } crec.start = time(NULL); crec.bcast_msg_flags = msg_flags; - + strlcpy(crec.machine,get_remote_machine_name(),sizeof(crec.machine)); strlcpy(crec.addr,conn?conn-client_address: client_addr(get_client_fd(),addr,sizeof(addr)), @@ -232,17 +232,17 @@ static TDB_DATA* make_pipe_rec_key( struct pipe_open_rec *prec ) { TDB_DATA *kbuf = NULL; fstring key_string; - + if ( !prec ) return NULL; - + if ( (kbuf = TALLOC_P(prec, TDB_DATA)) == NULL ) { return NULL; } - + snprintf( key_string, sizeof(key_string), %s/%d/%d, prec-name, procid_to_pid(prec-pid), prec-pnum ); - + *kbuf = string_term_tdb_data(talloc_strdup(prec, key_string)); if (kbuf-dptr == NULL ) return NULL; @@ -273,17 +273,17 @@ bool store_pipe_opendb( smb_np_struct *p ) TDB_DATA *key; TDB_DATA data; bool ret = False; - - if ( (prec = TALLOC_P( NULL, struct pipe_open_rec)) == NULL ) { + + if ( (prec = TALLOC_P( talloc_tos(), struct pipe_open_rec)) == NULL ) { DEBUG(0,(store_pipe_opendb: talloc failed!\n)); return False; } - + fill_pipe_open_rec( prec, p ); if ( (key = make_pipe_rec_key( prec )) == NULL ) { goto done; } - + data.dptr = (uint8 *)prec; data.dsize = sizeof(struct pipe_open_rec); @@ -293,7 +293,7 @@ bool store_pipe_opendb( smb_np_struct *p ) } ret = NT_STATUS_IS_OK(dbrec-store(dbrec, data, TDB_REPLACE)); - + done: TALLOC_FREE( prec ); return ret; @@ -308,24 +308,24 @@ bool delete_pipe_opendb( smb_np_struct *p ) struct pipe_open_rec *prec; TDB_DATA *key; bool ret = False; - - if ( (prec = TALLOC_P( NULL, struct pipe_open_rec)) == NULL ) { + + if ( (prec = TALLOC_P( talloc_tos(), struct pipe_open_rec)) == NULL ) { DEBUG(0,(store_pipe_opendb: talloc failed!\n)); return False; } - + fill_pipe_open_rec( prec, p ); if ( (key = make_pipe_rec_key( prec )) == NULL ) { goto done; } - + if (!(dbrec = connections_fetch_record(prec, *key))) { DEBUG(0, (connections_fetch_record failed\n));
[SCM] Samba Shared Repository - branch master updated - f0a27064869871806343648de3b5a0667118872f
The branch, master has been updated via f0a27064869871806343648de3b5a0667118872f (commit) via 200b0deaef4d399d321741ce76809beb628a5814 (commit) via 80faa78a912cda4b3298b832e46c22c045ec85f9 (commit) from 47f7ef8f39ba482a7d6578ab82c9e0670381c4f8 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f0a27064869871806343648de3b5a0667118872f Author: Volker Lendecke [EMAIL PROTECTED] Date: Fri Oct 10 23:40:50 2008 +0200 Make use of talloc_tos() commit 200b0deaef4d399d321741ce76809beb628a5814 Author: Volker Lendecke [EMAIL PROTECTED] Date: Fri Oct 10 17:50:09 2008 +0200 Fix some nonempty blank lines commit 80faa78a912cda4b3298b832e46c22c045ec85f9 Author: Volker Lendecke [EMAIL PROTECTED] Date: Fri Oct 10 16:26:34 2008 +0200 Fix a nexted extern declaration warning --- Summary of changes: source3/smbd/connection.c | 38 +++--- source3/smbd/ipc.c| 12 ++-- source3/smbd/nttrans.c|2 +- 3 files changed, 26 insertions(+), 26 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/smbd/connection.c b/source3/smbd/connection.c index 8dd5964..fd83f77 100644 --- a/source3/smbd/connection.c +++ b/source3/smbd/connection.c @@ -2,17 +2,17 @@ Unix SMB/CIFS implementation. connection claim routines Copyright (C) Andrew Tridgell 1998 - + This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version. - + This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. - + You should have received a copy of the GNU General Public License along with this program. If not, see http://www.gnu.org/licenses/. */ @@ -63,7 +63,7 @@ static int count_fn(struct db_record *rec, void *udp) { struct count_stat *cs = (struct count_stat *)udp; - + if (crec-cnum == -1) { return 0; } @@ -159,7 +159,7 @@ bool claim_connection(connection_struct *conn, const char *name, } crec.start = time(NULL); crec.bcast_msg_flags = msg_flags; - + strlcpy(crec.machine,get_remote_machine_name(),sizeof(crec.machine)); strlcpy(crec.addr,conn?conn-client_address: client_addr(get_client_fd(),addr,sizeof(addr)), @@ -232,17 +232,17 @@ static TDB_DATA* make_pipe_rec_key( struct pipe_open_rec *prec ) { TDB_DATA *kbuf = NULL; fstring key_string; - + if ( !prec ) return NULL; - + if ( (kbuf = TALLOC_P(prec, TDB_DATA)) == NULL ) { return NULL; } - + snprintf( key_string, sizeof(key_string), %s/%d/%d, prec-name, procid_to_pid(prec-pid), prec-pnum ); - + *kbuf = string_term_tdb_data(talloc_strdup(prec, key_string)); if (kbuf-dptr == NULL ) return NULL; @@ -273,17 +273,17 @@ bool store_pipe_opendb( smb_np_struct *p ) TDB_DATA *key; TDB_DATA data; bool ret = False; - - if ( (prec = TALLOC_P( NULL, struct pipe_open_rec)) == NULL ) { + + if ( (prec = TALLOC_P( talloc_tos(), struct pipe_open_rec)) == NULL ) { DEBUG(0,(store_pipe_opendb: talloc failed!\n)); return False; } - + fill_pipe_open_rec( prec, p ); if ( (key = make_pipe_rec_key( prec )) == NULL ) { goto done; } - + data.dptr = (uint8 *)prec; data.dsize = sizeof(struct pipe_open_rec); @@ -293,7 +293,7 @@ bool store_pipe_opendb( smb_np_struct *p ) } ret = NT_STATUS_IS_OK(dbrec-store(dbrec, data, TDB_REPLACE)); - + done: TALLOC_FREE( prec ); return ret; @@ -308,24 +308,24 @@ bool delete_pipe_opendb( smb_np_struct *p ) struct pipe_open_rec *prec; TDB_DATA *key; bool ret = False; - - if ( (prec = TALLOC_P( NULL, struct pipe_open_rec)) == NULL ) { + + if ( (prec = TALLOC_P( talloc_tos(), struct pipe_open_rec)) == NULL ) { DEBUG(0,(store_pipe_opendb: talloc failed!\n)); return False; } - + fill_pipe_open_rec( prec, p ); if ( (key = make_pipe_rec_key( prec )) == NULL ) { goto done; } - + if (!(dbrec = connections_fetch_record(prec, *key))) { DEBUG(0, (connections_fetch_record failed\n));
[SCM] Samba Shared Repository - branch master updated - 6a78e56277799672b7ac187c57e546836e136f79
The branch, master has been updated via 6a78e56277799672b7ac187c57e546836e136f79 (commit) via ddbddbd80c80b872cdd36a01f9a3a6bc2eca1b1f (commit) via d4baa2a6bb997d572563ba684454e2cdd6c23a65 (commit) via edeb20b92128f1859d2d8ecee820846ac5799ed5 (commit) via da01822671b3a553fd805315df7322b8225cfe95 (commit) from f0a27064869871806343648de3b5a0667118872f (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 6a78e56277799672b7ac187c57e546836e136f79 Merge: ddbddbd80c80b872cdd36a01f9a3a6bc2eca1b1f f0a27064869871806343648de3b5a0667118872f Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 14:44:10 2008 +0200 Merge branch 'master' of ssh://git.samba.org/data/git/samba into arc4 commit ddbddbd80c80b872cdd36a01f9a3a6bc2eca1b1f Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Wed Sep 24 19:20:33 2008 +0200 Fix build with arc4. commit d4baa2a6bb997d572563ba684454e2cdd6c23a65 Merge: edeb20b92128f1859d2d8ecee820846ac5799ed5 f10d8b84159b5708c1dcf854758cdbd18b2bc033 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Wed Sep 24 18:51:27 2008 +0200 Merge branch 'master' of ssh://git.samba.org/data/git/samba into arc4 commit edeb20b92128f1859d2d8ecee820846ac5799ed5 Merge: da01822671b3a553fd805315df7322b8225cfe95 d2062ab74f7684f8b6975a7415fac23389851278 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Wed Sep 24 18:38:45 2008 +0200 Merge branch 'master' of ssh://git.samba.org/data/git/samba into arc4 Conflicts: source3/include/includes.h commit da01822671b3a553fd805315df7322b8225cfe95 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Wed Sep 24 16:04:43 2008 +0200 Use common arcfour implementation. --- Summary of changes: source3/Makefile.in |4 +- source3/include/includes.h|1 + source3/include/ntlmssp.h |6 ++-- source3/include/proto.h |5 --- source3/lib/arc4.c| 79 - source3/lib/genrand.c |7 ++-- source3/libsmb/ntlmssp_sign.c | 66 +++--- source3/libsmb/smbdes.c | 13 --- 8 files changed, 54 insertions(+), 127 deletions(-) delete mode 100644 source3/lib/arc4.c Changeset truncated at 500 lines: diff --git a/source3/Makefile.in b/source3/Makefile.in index 8bee54d..09c054a 100644 --- a/source3/Makefile.in +++ b/source3/Makefile.in @@ -330,8 +330,8 @@ LIB_OBJ = $(LIBSAMBAUTIL_OBJ) \ lib/substitute.o lib/fsusage.o lib/dbwrap_util.o \ lib/ms_fnmatch.o lib/select.o lib/errmap_unix.o \ lib/tallocmsg.o lib/dmallocmsg.o libsmb/smb_signing.o \ - ../lib/crypto/md5.o ../lib/crypto/hmacmd5.o lib/arc4.o lib/iconv.o \ - lib/pam_errors.o intl/lang_tdb.o lib/conn_tdb.o \ + ../lib/crypto/md5.o ../lib/crypto/hmacmd5.o ../lib/crypto/arcfour.o \ + lib/iconv.o lib/pam_errors.o intl/lang_tdb.o lib/conn_tdb.o \ lib/adt_tree.o lib/gencache.o \ lib/module.o lib/events.o lib/ldap_escape.o @CHARSET_STATIC@ \ lib/secdesc.o lib/util_seaccess.o lib/secace.o lib/secacl.o \ diff --git a/source3/include/includes.h b/source3/include/includes.h index 79495a7..0417a7e 100644 --- a/source3/include/includes.h +++ b/source3/include/includes.h @@ -687,6 +687,7 @@ typedef char fstring[FSTRING_LEN]; #include msdfs.h #include rap.h #include ../lib/crypto/md5.h +#include ../lib/crypto/arcfour.h #include ../lib/crypto/crc32.h #include ../lib/crypto/hmacmd5.h #include ntlmssp.h diff --git a/source3/include/ntlmssp.h b/source3/include/ntlmssp.h index 3fb41c5..b014b21 100644 --- a/source3/include/ntlmssp.h +++ b/source3/include/ntlmssp.h @@ -157,14 +157,14 @@ typedef struct ntlmssp_state unsigned char recv_sign_key[16]; unsigned char recv_seal_key[16]; - unsigned char send_seal_arc4_state[258]; - unsigned char recv_seal_arc4_state[258]; + struct arcfour_state send_seal_arc4_state; + struct arcfour_state recv_seal_arc4_state; uint32 ntlm2_send_seq_num; uint32 ntlm2_recv_seq_num; /* ntlmv1 */ - unsigned char ntlmv1_arc4_state[258]; + struct arcfour_state ntlmv1_arc4_state; uint32 ntlmv1_seq_num; /* it turns out that we don't always get the diff --git a/source3/include/proto.h b/source3/include/proto.h index fc497b6..3df87a6 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -315,11 +315,6 @@ int afs_syscall( int subcall, bool afs_settoken_str(const char *token_string); bool afs_settoken_str(const char *token_string); -/* The following definitions come from lib/arc4.c */ - -void smb_arc4_init(unsigned char arc4_state_out[258], const unsigned char *key, size_t keylen); -void smb_arc4_crypt(unsigned char arc4_state_inout[258], unsigned char
[SCM] Samba Shared Repository - branch master updated - 033bc4682b7c7541966da4b2b43b65a4ba722b43
The branch, master has been updated via 033bc4682b7c7541966da4b2b43b65a4ba722b43 (commit) from 6a78e56277799672b7ac187c57e546836e136f79 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 033bc4682b7c7541966da4b2b43b65a4ba722b43 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 16:17:14 2008 +0200 Prevent errors with data_blob() being a macro in s4 and function in s3. --- Summary of changes: lib/crypto/arcfour.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/crypto/arcfour.c b/lib/crypto/arcfour.c index c57e05d..b4773f4 100644 --- a/lib/crypto/arcfour.c +++ b/lib/crypto/arcfour.c @@ -81,7 +81,7 @@ _PUBLIC_ void arcfour_crypt_blob(uint8_t *data, int len, const DATA_BLOB *key) */ _PUBLIC_ void arcfour_crypt(uint8_t *data, const uint8_t keystr[16], int len) { - DATA_BLOB key = data_blob(keystr, 16); + DATA_BLOB key = { discard_const_p(uint8_t, keystr), 16 }; arcfour_crypt_blob(data, len, key); -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated - a85f6634853a4cf825d70e07a789e96e1882f376
The branch, master has been updated via a85f6634853a4cf825d70e07a789e96e1882f376 (commit) from 033bc4682b7c7541966da4b2b43b65a4ba722b43 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit a85f6634853a4cf825d70e07a789e96e1882f376 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 20:26:40 2008 +0200 Make sure to allocate copy for arc4 data, to avoid problems freeing later. --- Summary of changes: lib/crypto/arcfour.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/crypto/arcfour.c b/lib/crypto/arcfour.c index b4773f4..e70713b 100644 --- a/lib/crypto/arcfour.c +++ b/lib/crypto/arcfour.c @@ -81,7 +81,7 @@ _PUBLIC_ void arcfour_crypt_blob(uint8_t *data, int len, const DATA_BLOB *key) */ _PUBLIC_ void arcfour_crypt(uint8_t *data, const uint8_t keystr[16], int len) { - DATA_BLOB key = { discard_const_p(uint8_t, keystr), 16 }; + DATA_BLOB key = data_blob_named(keystr, 16, DATA_BLOB: __location__); arcfour_crypt_blob(data, len, key); -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated - 621cf3c9bf161e686935f57393ab184d298d72de
The branch, master has been updated via 621cf3c9bf161e686935f57393ab184d298d72de (commit) via 2c4391e95002404fb2e1d09f97541c1ece1da46f (commit) from a85f6634853a4cf825d70e07a789e96e1882f376 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 621cf3c9bf161e686935f57393ab184d298d72de Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 21:02:13 2008 +0200 Use data_blob() for now, since it seems to be the only function available in both Samba 3 and Samba 4. commit 2c4391e95002404fb2e1d09f97541c1ece1da46f Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 20:44:19 2008 +0200 Provide the same set of helper functions for DEBUG in Samba 3 and Samba 4, even though the macros are still different. This makes it possible to use object code compiled with one DEBUG() macro from the other sourceX directory. --- Summary of changes: lib/crypto/arcfour.c |2 +- source3/include/debug.h | 12 +++- source3/include/proto.h |3 ++- source3/lib/debug.c | 12 +--- source4/auth/gensec/cyrus_sasl.c | 22 +++--- source4/lib/smbreadline/smbreadline.c |2 +- source4/lib/tdb_wrap.c| 14 +++--- source4/lib/util/debug.c | 15 --- source4/lib/util/debug.h |9 + 9 files changed, 55 insertions(+), 36 deletions(-) Changeset truncated at 500 lines: diff --git a/lib/crypto/arcfour.c b/lib/crypto/arcfour.c index e70713b..c57e05d 100644 --- a/lib/crypto/arcfour.c +++ b/lib/crypto/arcfour.c @@ -81,7 +81,7 @@ _PUBLIC_ void arcfour_crypt_blob(uint8_t *data, int len, const DATA_BLOB *key) */ _PUBLIC_ void arcfour_crypt(uint8_t *data, const uint8_t keystr[16], int len) { - DATA_BLOB key = data_blob_named(keystr, 16, DATA_BLOB: __location__); + DATA_BLOB key = data_blob(keystr, 16); arcfour_crypt_blob(data, len, key); diff --git a/source3/include/debug.h b/source3/include/debug.h index d171632..56d0237 100644 --- a/source3/include/debug.h +++ b/source3/include/debug.h @@ -40,11 +40,13 @@ int Debug1( const char *, ... ) PRINTF_ATTRIBUTE(1,2); /* PRINTFLIKE1 */ bool dbgtext( const char *, ... ) PRINTF_ATTRIBUTE(1,2); -bool dbghdr( int level, int cls, const char *file, const char *func, int line ); +bool dbghdrclass( int level, int cls, const char *location, const char *func); +bool dbghdr( int level, const char *location, const char *func); #if defined(sgi) (_COMPILER_VERSION = 730) #pragma mips_frequency_hint NEVER Debug1 #pragma mips_frequency_hint NEVER dbgtext +#pragma mips_frequency_hint NEVER dbghdrclass #pragma mips_frequency_hint NEVER dbghdr #endif @@ -192,7 +194,7 @@ extern bool *DEBUGLEVEL_CLASS_ISSET; #define DEBUGLVL( level ) \ ( CHECK_DEBUGLVL(level) \ -dbghdr( level, DBGC_CLASS, __FILE__, FUNCTION_MACRO, (__LINE__) ) ) +dbghdrclass( level, DBGC_CLASS, __location__, FUNCTION_MACRO ) ) #define DEBUGLVLC( dbgc_class, level ) \ @@ -200,7 +202,7 @@ extern bool *DEBUGLEVEL_CLASS_ISSET; unlikely((DEBUGLEVEL_CLASS[ dbgc_class ] = (level))|| \ (!DEBUGLEVEL_CLASS_ISSET[ dbgc_class ] \ DEBUGLEVEL_CLASS[ DBGC_ALL ] = (level)) ) \ -dbghdr( level, DBGC_CLASS, __FILE__, FUNCTION_MACRO, (__LINE__) ) ) +dbghdrclass( level, DBGC_CLASS, __location__, FUNCTION_MACRO) ) #define DEBUG( level, body ) \ @@ -208,7 +210,7 @@ extern bool *DEBUGLEVEL_CLASS_ISSET; unlikely((DEBUGLEVEL_CLASS[ DBGC_CLASS ] = (level))|| \ (!DEBUGLEVEL_CLASS_ISSET[ DBGC_CLASS ] \ DEBUGLEVEL_CLASS[ DBGC_ALL ] = (level)) ) \ -(dbghdr( level, DBGC_CLASS, __FILE__, FUNCTION_MACRO, (__LINE__) )) \ +(dbghdrclass( level, DBGC_CLASS, __location__, FUNCTION_MACRO )) \ (dbgtext body) ) #define DEBUGC( dbgc_class, level, body ) \ @@ -216,7 +218,7 @@ extern bool *DEBUGLEVEL_CLASS_ISSET; unlikely((DEBUGLEVEL_CLASS[ dbgc_class ] = (level))|| \ (!DEBUGLEVEL_CLASS_ISSET[ dbgc_class ] \ DEBUGLEVEL_CLASS[ DBGC_ALL ] = (level)) ) \ -(dbghdr( level, DBGC_CLASS, __FILE__, FUNCTION_MACRO, (__LINE__) )) \ +(dbghdrclass( level, DBGC_CLASS, __location__, FUNCTION_MACRO)) \ (dbgtext body) ) #define DEBUGADD( level, body ) \ diff --git a/source3/include/proto.h b/source3/include/proto.h index 3df87a6..bf66908 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -486,7 +486,8 @@ void force_check_log_size( void ); bool need_to_check_log_size( void ); void check_log_size( void ); void dbgflush( void ); -bool dbghdr(int level, int cls, const char *file, const char *func, int line); +bool dbghdrclass(int level, int cls, const char
[SCM] Samba Shared Repository - branch master updated - f01500e18da2df4a4414e97da8e2cdc3ee8a6e1e
The branch, master has been updated via f01500e18da2df4a4414e97da8e2cdc3ee8a6e1e (commit) via 2911b792ca979dd9c9715e55f92097791b4ce837 (commit) via 5c44ed69548c4a4d753b54f72dc41212e2c7b612 (commit) via a19719ccea2d63d42a35d30f91fe112d2a3db8c7 (commit) via 956599975573044f5f930ef23ce54c11db156ebe (commit) via caa4e428604780bb098060f7286c69d30c8b4007 (commit) via 4604ca430294d8d9a522dd29705e7a7a1c969304 (commit) from 621cf3c9bf161e686935f57393ab184d298d72de (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit f01500e18da2df4a4414e97da8e2cdc3ee8a6e1e Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 21:42:45 2008 +0200 Fix merged build locations. commit 2911b792ca979dd9c9715e55f92097791b4ce837 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 21:33:55 2008 +0200 Fix include, clean up .o files in ../lib and ../libcli Conflicts: source4/Makefile commit 5c44ed69548c4a4d753b54f72dc41212e2c7b612 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Wed Sep 24 14:49:12 2008 +0200 Clean up properly. commit a19719ccea2d63d42a35d30f91fe112d2a3db8c7 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 16:31:39 2008 +0200 Fix libutil path. commit 956599975573044f5f930ef23ce54c11db156ebe Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 21:31:42 2008 +0200 Fix include paths to new location of libutil. commit caa4e428604780bb098060f7286c69d30c8b4007 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 21:05:38 2008 +0200 Move lib/util from source4 to top-level libutil. Conflicts: source4/Makefile commit 4604ca430294d8d9a522dd29705e7a7a1c969304 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 19:44:10 2008 +0200 Provide malloc_array() in Samba 4. --- Summary of changes: .gitignore| 10 +- lib/util/Doxyfile | 24 + lib/util/asn1.c | 770 +++ lib/util/asn1.h | 54 ++ lib/util/attr.h | 90 +++ lib/util/become_daemon.c | 93 +++ lib/util/byteorder.h | 231 +++ lib/util/capability.c | 103 lib/util/capability.m4| 17 + lib/util/config.mk| 71 +++ lib/util/data_blob.c | 232 +++ lib/util/data_blob.h | 123 lib/util/debug.c | 248 lib/util/debug.h | 129 lib/util/dlinklist.h | 113 lib/util/dprintf.c| 111 lib/util/fault.c | 226 +++ lib/util/fault.m4 |5 + lib/util/fsusage.c| 154 + lib/util/fsusage.m4 | 190 ++ lib/util/genrand.c| 361 +++ lib/util/idtree.c | 403 lib/util/mainpage.dox | 11 + lib/util/ms_fnmatch.c | 223 +++ lib/util/mutex.c | 56 ++ lib/util/mutex.h | 75 +++ lib/util/params.c | 587 ++ lib/util/safe_string.h| 44 ++ lib/util/signal.c | 144 + lib/util/signal.m4|1 + lib/util/system.c | 90 +++ lib/util/tests/file.c | 97 +++ lib/util/tests/genrand.c | 65 ++ lib/util/tests/idtree.c | 121 lib/util/tests/str.c | 121 lib/util/tests/strlist.c | 103 lib/util/time.c | 622 +++ lib/util/time.h | 232 +++ lib/util/time.m4 |9 + lib/util/unix_privs.c | 77 +++ lib/util/util.c | 608 ++ lib/util/util.h | 812 lib/util/util.m4 |1 + lib/util/util_file.c | 404 lib/util/util_getent.c| 283 + lib/util/util_ldb.c | 134 lib/util/util_ldb.h | 27 + lib/util/util_pw.c| 77 +++ lib/util/util_str.c
[SCM] Samba Shared Repository - branch master updated - 7a27c07a2765020cb4a07073327bba1435e33f87
The branch, master has been updated via 7a27c07a2765020cb4a07073327bba1435e33f87 (commit) from f01500e18da2df4a4414e97da8e2cdc3ee8a6e1e (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 7a27c07a2765020cb4a07073327bba1435e33f87 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 21:48:00 2008 +0200 Remove duplicate copy of dlinklist.h. --- Summary of changes: lib/util/dlinklist.h|2 +- source3/include/dlinklist.h | 113 --- source3/include/includes.h |2 +- 3 files changed, 2 insertions(+), 115 deletions(-) delete mode 100644 source3/include/dlinklist.h Changeset truncated at 500 lines: diff --git a/lib/util/dlinklist.h b/lib/util/dlinklist.h index 5624124..1a4ebb6 100644 --- a/lib/util/dlinklist.h +++ b/lib/util/dlinklist.h @@ -58,7 +58,7 @@ do { \ DLIST_ADD(list, p); \ } while (0) -/* hook into the end of the list - needs a tmp pointer */ +/* hook into the end of the list - needs the entry type */ #define DLIST_ADD_END(list, p, type) \ do { \ if (!(list)) { \ diff --git a/source3/include/dlinklist.h b/source3/include/dlinklist.h deleted file mode 100644 index 1a4ebb6..000 --- a/source3/include/dlinklist.h +++ /dev/null @@ -1,113 +0,0 @@ -/* - Unix SMB/CIFS implementation. - some simple double linked list macros - Copyright (C) Andrew Tridgell 1998 - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see http://www.gnu.org/licenses/. -*/ - -/* To use these macros you must have a structure containing a next and - prev pointer */ - -#ifndef _DLINKLIST_H -#define _DLINKLIST_H - - -/* hook into the front of the list */ -#define DLIST_ADD(list, p) \ -do { \ -if (!(list)) { \ - (list) = (p); \ - (p)-next = (p)-prev = NULL; \ - } else { \ - (list)-prev = (p); \ - (p)-next = (list); \ - (p)-prev = NULL; \ - (list) = (p); \ - }\ -} while (0) - -/* remove an element from a list - element doesn't have to be in list. */ -#define DLIST_REMOVE(list, p) \ -do { \ - if ((p) == (list)) { \ - (list) = (p)-next; \ - if (list) (list)-prev = NULL; \ - } else { \ - if ((p)-prev) (p)-prev-next = (p)-next; \ - if ((p)-next) (p)-next-prev = (p)-prev; \ - } \ - if ((p) != (list)) (p)-next = (p)-prev = NULL; \ -} while (0) - -/* promote an element to the top of the list */ -#define DLIST_PROMOTE(list, p) \ -do { \ - DLIST_REMOVE(list, p); \ - DLIST_ADD(list, p); \ -} while (0) - -/* hook into the end of the list - needs the entry type */ -#define DLIST_ADD_END(list, p, type) \ -do { \ - if (!(list)) { \ - (list) = (p); \ - (p)-next = (p)-prev = NULL; \ - } else { \ - type tmp; \ - for (tmp = (list); tmp-next; tmp = tmp-next) ; \ - tmp-next = (p); \ - (p)-next = NULL; \ - (p)-prev = tmp; \ - } \ -} while (0) - -/* insert 'p' after the given element 'el' in a list. If el is NULL then - this is the same as a DLIST_ADD() */ -#define DLIST_ADD_AFTER(list, p, el) \ -do { \ -if (!(list) || !(el)) { \ - DLIST_ADD(list, p); \ - } else { \ - p-prev = el; \ - p-next = el-next; \ - el-next = p; \ - if (p-next) p-next-prev = p; \ - }\ -} while (0) - -/* demote an element to the end of the list, needs a tmp pointer */ -#define DLIST_DEMOTE(list, p, tmp) \ -do { \ - DLIST_REMOVE(list, p); \ - DLIST_ADD_END(list, p, tmp); \ -} while (0) - -/* concatenate two lists - putting all elements of the 2nd list at the - end of the first list */ -#define DLIST_CONCATENATE(list1, list2, type) \ -do { \ - if (!(list1)) { \ - (list1) = (list2); \ - } else { \ - type tmp; \ - for (tmp = (list1); tmp-next; tmp = tmp-next) ; \ - tmp-next = (list2); \ -
[SCM] Samba Shared Repository - branch master updated - bb33097fb79021c1a47bb4bc45c132020c47d6e4
The branch, master has been updated via bb33097fb79021c1a47bb4bc45c132020c47d6e4 (commit) via 06cdfb17b92e69de2995dd7c4a3f417f10230aa7 (commit) via e439b3e7ab0d9f80f2606f5a7bee144ee143f4cf (commit) from 7a27c07a2765020cb4a07073327bba1435e33f87 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit bb33097fb79021c1a47bb4bc45c132020c47d6e4 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 22:23:07 2008 +0200 Make sure x_fdup compiles on Samba 4. commit 06cdfb17b92e69de2995dd7c4a3f417f10230aa7 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 22:22:29 2008 +0200 Support make test-X to run all tests that match regex X. commit e439b3e7ab0d9f80f2606f5a7bee144ee143f4cf Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 21:52:55 2008 +0200 Use xfile from common lib/util in Samba 3. Conflicts: source3/Makefile.in --- Summary of changes: lib/util/xfile.c | 32 - lib/util/xfile.h |2 +- source3/Makefile.in|2 +- source3/lib/xfile.c| 417 source4/selftest/config.mk |3 + 5 files changed, 36 insertions(+), 420 deletions(-) delete mode 100644 source3/lib/xfile.c Changeset truncated at 500 lines: diff --git a/lib/util/xfile.c b/lib/util/xfile.c index a016031..7cfb680 100644 --- a/lib/util/xfile.c +++ b/lib/util/xfile.c @@ -36,6 +36,13 @@ #include includes.h #include system/filesys.h +#if _SAMBA_BUILD_ == 3 +#undef malloc +#define malloc SMB_MALLOC +#undef malloc_p +#define malloc_p SMB_MALLOC_P +#endif + #define XBUFSIZE BUFSIZ static XFILE _x_stdin = { 0, NULL, NULL, XBUFSIZE, 0, O_RDONLY, X_IOFBF, 0 }; @@ -222,7 +229,7 @@ size_t x_fwrite(const void *p, size_t size, size_t nmemb, XFILE *f) } /* at least fileno() is simple! */ -int x_fileno(XFILE *f) +int x_fileno(const XFILE *f) { return f-fd; } @@ -387,3 +394,26 @@ off_t x_tseek(XFILE *f, off_t offset, int whence) f-flags = ~X_FLAG_EOF; return lseek(f-fd, offset, whence); } + +XFILE *x_fdup(const XFILE *f) +{ + XFILE *ret; + int fd; + + fd = dup(x_fileno(f)); + if (fd 0) { + return NULL; + } + + ret = malloc_p(XFILE); + if (!ret) { + close(fd); + return NULL; + } + memset(ret, 0, sizeof(XFILE)); + + ret-fd = fd; + ret-open_flags = f-open_flags; + x_setvbuf(ret, NULL, X_IOFBF, XBUFSIZE); + return ret; +} diff --git a/lib/util/xfile.h b/lib/util/xfile.h index 2cc369d..aa14b7c 100644 --- a/lib/util/xfile.h +++ b/lib/util/xfile.h @@ -62,7 +62,7 @@ int x_fclose(XFILE *f); size_t x_fwrite(const void *p, size_t size, size_t nmemb, XFILE *f); /** thank goodness for asprintf() */ -int x_fileno(XFILE *f); +int x_fileno(const XFILE *f); /** simulate fflush() */ int x_fflush(XFILE *f); diff --git a/source3/Makefile.in b/source3/Makefile.in index 5f04382..6ded156 100644 --- a/source3/Makefile.in +++ b/source3/Makefile.in @@ -323,7 +323,7 @@ LIB_OBJ = $(LIBSAMBAUTIL_OBJ) \ lib/ufc.o lib/genrand.o lib/username.o \ lib/util_pw.o lib/access.o lib/smbrun.o \ lib/bitmap.o ../lib/crypto/crc32.o lib/dprintf.o \ - lib/xfile.o lib/wins_srv.o $(UTIL_REG_OBJ) \ + ../lib/util/xfile.o lib/wins_srv.o $(UTIL_REG_OBJ) \ lib/util_str.o lib/clobber.o lib/util_sid.o lib/util_uuid.o \ lib/util_unistr.o lib/util_file.o lib/data_blob.o \ lib/util.o lib/util_sock.o lib/sock_exec.o lib/util_sec.o \ diff --git a/source3/lib/xfile.c b/source3/lib/xfile.c deleted file mode 100644 index e44a92d..000 --- a/source3/lib/xfile.c +++ /dev/null @@ -1,417 +0,0 @@ -/* - Unix SMB/CIFS implementation. - stdio replacement - Copyright (C) Andrew Tridgell 2001 - - This program is free software; you can redistribute it and/or modify - it under the terms of the GNU General Public License as published by - the Free Software Foundation; either version 3 of the License, or - (at your option) any later version. - - This program is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - GNU General Public License for more details. - - You should have received a copy of the GNU General Public License - along with this program. If not, see http://www.gnu.org/licenses/. -*/ - -/* - stdio is very convenient, but on some systems the file descriptor - in FILE* is 8 bits, so it fails when more than 255 files are open. - - XFILE replaces stdio. It is less efficient, but at least it works - when you have lots of files open - - The main restriction on XFILE is that it
Build status as of Sun Oct 12 00:00:03 2008
URL: http://build.samba.org/ --- /home/build/master/cache/broken_results.txt.old 2008-10-11 00:00:26.0 + +++ /home/build/master/cache/broken_results.txt 2008-10-12 00:00:15.0 + @@ -1,22 +1,22 @@ -Build status as of Sat Oct 11 00:00:02 2008 +Build status as of Sun Oct 12 00:00:03 2008 Build counts: Tree Total Broken Panic build_farm 0 0 0 -ccache 34 7 0 +ccache 33 7 0 ctdb 0 0 0 distcc 1 0 0 ldb 34 33 0 -libreplace 32 12 0 +libreplace 33 12 0 lorikeet-heimdal 30 20 0 pidl 20 3 0 ppp 14 14 0 -rsync33 11 0 +rsync34 9 0 samba-docs 0 0 0 samba-gtk7 7 0 -samba_3_X_devel 29 19 0 -samba_3_X_test 30 16 0 -samba_4_0_test 32 28 1 +samba_3_X_devel 29 27 0 +samba_3_X_test 30 18 0 +samba_4_0_test 32 31 0 smb-build32 7 0 talloc 34 33 0 tdb 34 12 0
[SCM] Samba Shared Repository - branch master updated - c4d3dc849f48a75653d1b16031e9c0657df4d098
The branch, master has been updated via c4d3dc849f48a75653d1b16031e9c0657df4d098 (commit) via d7371dae24a8ec341713d004c2ac9444ec4b14de (commit) via 771e25b63b8435b2e9ae201017516ea700890190 (commit) via 348be5f1e44c0b17ff87a8964a36e83b291a6518 (commit) via 218f482fbfe96b2cddec8c05f6b8f174481d2e27 (commit) via cb78d4593b5ac4eaa0cbead6f86027d040a9e88a (commit) via 75a36a9a5491b86aaa3b0983d5a2bd5d024f783a (commit) from bb33097fb79021c1a47bb4bc45c132020c47d6e4 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit c4d3dc849f48a75653d1b16031e9c0657df4d098 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 02:27:38 2008 +0200 Add extra const. commit d7371dae24a8ec341713d004c2ac9444ec4b14de Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 01:56:11 2008 +0200 Add one-test testsuite for datablob. commit 771e25b63b8435b2e9ae201017516ea700890190 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 01:48:22 2008 +0200 Avoid problems with paranoid malloc checker. commit 348be5f1e44c0b17ff87a8964a36e83b291a6518 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 01:46:15 2008 +0200 Share data_blob implementation. commit 218f482fbfe96b2cddec8c05f6b8f174481d2e27 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 00:56:56 2008 +0200 Use common strlist implementation in Samba 3 and Samba 4. commit cb78d4593b5ac4eaa0cbead6f86027d040a9e88a Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 23:57:44 2008 +0200 Cope with changed signature of http_timestring(). commit 75a36a9a5491b86aaa3b0983d5a2bd5d024f783a Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sat Oct 11 23:25:35 2008 +0200 Add some simple tests for lib/util/time.c --- Summary of changes: lib/util/data_blob.c |2 + lib/util/data_blob.h |2 + lib/util/tests/data_blob.c| 44 +++ lib/util/tests/strlist.c |6 +- lib/util/tests/time.c | 75 lib/util/time.c | 128 ++- lib/util/time.h |5 + lib/util/util.h |9 +- lib/util/util_strlist.c | 20 +- lib/util/xfile.c |4 +- libcli/nbt/namerefresh.c |4 +- libcli/nbt/nameregister.c |4 +- source3/Makefile.in |7 +- source3/auth/auth.c |4 +- source3/auth/auth_sam.c |2 +- source3/include/includes.h|3 + source3/include/messages.h|7 +- source3/include/packet.h |4 +- source3/include/proto.h | 18 +- source3/include/smb.h | 12 - source3/lib/data_blob.c | 180 - source3/lib/events.c |2 +- source3/lib/packet.c | 12 +- source3/lib/time.c| 558 - source3/lib/util_str.c| 107 -- source3/libads/authdata.c |4 +- source3/libads/ldap.c |4 +- source3/libsmb/clikrb5.c |4 +- source3/param/loadparm.c |7 +- source3/printing/print_generic.c |2 +- source3/rpc_server/srv_svcctl_nt.c|2 +- source3/rpcclient/cmd_samr.c | 16 +- source3/smbd/chgpasswd.c |2 +- source3/smbd/password.c |4 +- source3/utils/net_ads.c |3 +- source3/utils/net_registry_util.c |2 +- source3/utils/pdbedit.c | 23 +- source3/web/cgi.c |5 +- source3/winbindd/winbindd_dual.c |2 +- source4/auth/sam.c|2 +- source4/client/client.c |2 +- source4/dsdb/common/util.c|2 +- source4/libcli/resolve/wins.c |2 +- source4/libnet/libnet_lookup.c|2 +- source4/nbt_server/wins/winsclient.c |2 +- source4/param/generic.c |2 +- source4/param/loadparm.c |6 +- source4/rpc_server/remote/dcesrv_remote.c |2 +- source4/torture/local/config.mk |2 + source4/torture/local/local.c |2 + source4/torture/nbt/wins.c|8 +- source4/winbind/wb_samba3_cmd.c |2 +- 52 files changed, 347 insertions(+), 988 deletions(-) create mode 100644 lib/util/tests/data_blob.c create mode 100644 lib/util/tests/time.c delete mode 100644 source3/lib/data_blob.c Changeset truncated at 500
[SCM] Samba Shared Repository - branch master updated - 5237369ad8bac6a5fc80e32b313ce9f3266abc0f
The branch, master has been updated via 5237369ad8bac6a5fc80e32b313ce9f3266abc0f (commit) from c4d3dc849f48a75653d1b16031e9c0657df4d098 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 5237369ad8bac6a5fc80e32b313ce9f3266abc0f Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 02:59:30 2008 +0200 Fix warning, prototype. --- Summary of changes: source3/include/proto.h |2 +- source4/lib/socket/socket.c |2 +- 2 files changed, 2 insertions(+), 2 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/include/proto.h b/source3/include/proto.h index 3a74006..08c1e2c 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -1662,7 +1662,7 @@ int fstr_sprintf(fstring s, const char *fmt, ...); char **str_list_make(TALLOC_CTX *mem_ctx, const char *string, const char *sep); char **str_list_copy(TALLOC_CTX *mem_ctx, const char **list); bool str_list_compare(char **list1, char **list2); -size_t str_list_length( const char **list ); +size_t str_list_length( const char * const*list ); bool str_list_sub_basic( char **list, const char *smb_name, const char *domain_name ); bool str_list_substitute(char **list, const char *pattern, const char *insert); diff --git a/source4/lib/socket/socket.c b/source4/lib/socket/socket.c index 92f0a44..0c3d032 100644 --- a/source4/lib/socket/socket.c +++ b/source4/lib/socket/socket.c @@ -491,7 +491,7 @@ static const struct { **/ _PUBLIC_ void set_socket_options(int fd, const char *options) { - const char **options_list = str_list_make(NULL, options, \t,); + const char **options_list = (const char **)str_list_make(NULL, options, \t,); int j; if (!options_list) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated - d68168e63386f900b70b82a7056f6e744cd5d50c
The branch, master has been updated via d68168e63386f900b70b82a7056f6e744cd5d50c (commit) from 5237369ad8bac6a5fc80e32b313ce9f3266abc0f (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit d68168e63386f900b70b82a7056f6e744cd5d50c Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 04:00:55 2008 +0200 Cope with the fact that the data blobs returned are now talloc-allocated. Ideally, this memory should be talloc-stolen (and perhaps have DATA_BLOB in the interface everywhere), but that requires some more complex changes so I've just changed it to copy it for now. --- Summary of changes: source3/smbd/seal.c | 24 1 files changed, 20 insertions(+), 4 deletions(-) Changeset truncated at 500 lines: diff --git a/source3/smbd/seal.c b/source3/smbd/seal.c index e9dc46a..18d8b64 100644 --- a/source3/smbd/seal.c +++ b/source3/smbd/seal.c @@ -426,9 +426,14 @@ static NTSTATUS srv_enc_spnego_gss_negotiate(unsigned char **ppdata, size_t *p_d data_blob_free(auth_reply); SAFE_FREE(*ppdata); - *ppdata = response.data; + *ppdata = memdup(response.data, response.length); + if ((*ppdata) == NULL response.length 0) { + status = NT_STATUS_NO_MEMORY; + } *p_data_size = response.length; + data_blob_free(response); + return status; } #endif @@ -463,8 +468,13 @@ static NTSTATUS srv_enc_ntlm_negotiate(unsigned char **ppdata, size_t *p_data_si } SAFE_FREE(*ppdata); - *ppdata = response.data; + *ppdata = memdup(response.data, response.length); + if ((*ppdata) == NULL response.length 0) { + status = NT_STATUS_NO_MEMORY; + } *p_data_size = response.length; + data_blob_free(response); + return status; } @@ -585,8 +595,11 @@ static NTSTATUS srv_enc_spnego_ntlm_auth(connection_struct *conn, } SAFE_FREE(*ppdata); - *ppdata = response.data; + *ppdata = memdup(response.data, response.length); + if ((*ppdata) == NULL response.length 0) + return NT_STATUS_NO_MEMORY; *p_data_size = response.length; + data_blob_free(response); return status; } @@ -636,8 +649,11 @@ static NTSTATUS srv_enc_raw_ntlm_auth(connection_struct *conn, /* Return the raw blob. */ SAFE_FREE(*ppdata); - *ppdata = response.data; + *ppdata = memdup(response.data, response.length); + if ((*ppdata) == NULL response.length 0) + return NT_STATUS_NO_MEMORY; *p_data_size = response.length; + data_blob_free(response); return status; } -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated - df8885f1c6cdcdb74bec77cbdeeaca48c45e4d43
The branch, master has been updated via df8885f1c6cdcdb74bec77cbdeeaca48c45e4d43 (commit) from d68168e63386f900b70b82a7056f6e744cd5d50c (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit df8885f1c6cdcdb74bec77cbdeeaca48c45e4d43 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 04:15:32 2008 +0200 Fix installation source locations for ../lib/util headers. --- Summary of changes: source4/headermap.txt | 28 ++-- 1 files changed, 14 insertions(+), 14 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/headermap.txt b/source4/headermap.txt index e2bbb16..a1b21d7 100644 --- a/source4/headermap.txt +++ b/source4/headermap.txt @@ -1,12 +1,12 @@ # FIXME: This file should be autogenerated by the build system at some # point -lib/util/util.h: util.h -lib/util/debug.h: util/debug.h -lib/util/mutex.h: util/mutex.h -lib/util/attr.h: util/attr.h -lib/util/byteorder.h: util/byteorder.h -lib/util/safe_string.h: util/safe_string.h -lib/util/xfile.h: util/xfile.h +../lib/util/util.h: util.h +../lib/util/debug.h: util/debug.h +../lib/util/mutex.h: util/mutex.h +../lib/util/attr.h: util/attr.h +../lib/util/byteorder.h: util/byteorder.h +../lib/util/safe_string.h: util/safe_string.h +../lib/util/xfile.h: util/xfile.h lib/tdr/tdr.h: tdr.h librpc/rpc/dcerpc.h: dcerpc.h lib/ldb/include/ldb.h: ldb.h @@ -52,21 +52,21 @@ librpc/gen_ndr/svcctl.h: gen_ndr/svcctl.h librpc/gen_ndr/ndr_svcctl.h: gen_ndr/ndr_svcctl.h librpc/gen_ndr/ndr_svcctl_c.h: gen_ndr/ndr_svcctl_c.h lib/cmdline/popt_common.h: samba/popt.h -lib/util/dlinklist.h: dlinklist.h -lib/util/data_blob.h: util/data_blob.h -lib/util/time.h: util/time.h +../lib/util/dlinklist.h: dlinklist.h +../lib/util/data_blob.h: util/data_blob.h +../lib/util/time.h: util/time.h version.h: samba/version.h param/param.h: param.h -lib/util/asn1.h: samba/asn1.h +../lib/util/asn1.h: samba/asn1.h libcli/util/error.h: core/error.h lib/tdb_wrap.h: tdb_wrap.h lib/ldb_wrap.h: ldb_wrap.h torture/smbtorture.h: smbtorture.h librpc/gen_ndr/winbind.h: gen_ndr/winbind.h param/share.h: share.h -lib/util/util_tdb.h: util_tdb.h -lib/util/util_ldb.h: util_ldb.h -lib/util/wrap_xattr.h: wrap_xattr.h +../lib/util/util_tdb.h: util_tdb.h +../lib/util/util_ldb.h: util_ldb.h +../lib/util/wrap_xattr.h: wrap_xattr.h lib/events/events.h: events/events.h lib/events/events_internal.h: events/events_internal.h libcli/ldap/ldap_ndr.h: ldap_ndr.h -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated - 0d99e58f272ab05873b706a154a528d04749c335
The branch, master has been updated via 0d99e58f272ab05873b706a154a528d04749c335 (commit) from df8885f1c6cdcdb74bec77cbdeeaca48c45e4d43 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 0d99e58f272ab05873b706a154a528d04749c335 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 04:41:53 2008 +0200 Fix include paths for files that aren't compiled - breaks dependency file generation. --- Summary of changes: source4/lib/com/dcom/main.c|2 +- source4/lib/com/dcom/tables.c |2 +- source4/ntvfs/sysdep/sys_lease_linux.c |2 +- 3 files changed, 3 insertions(+), 3 deletions(-) Changeset truncated at 500 lines: diff --git a/source4/lib/com/dcom/main.c b/source4/lib/com/dcom/main.c index 3d2c135..695bfa7 100644 --- a/source4/lib/com/dcom/main.c +++ b/source4/lib/com/dcom/main.c @@ -28,7 +28,7 @@ #include librpc/rpc/dcerpc.h #include lib/com/dcom/dcom.h #include librpc/ndr/ndr_table.h -#include lib/util/dlinklist.h +#include ../lib/util/dlinklist.h #include auth/credentials/credentials.h #include libcli/composite/composite.h diff --git a/source4/lib/com/dcom/tables.c b/source4/lib/com/dcom/tables.c index 26a18a9..f94aa87 100644 --- a/source4/lib/com/dcom/tables.c +++ b/source4/lib/com/dcom/tables.c @@ -20,7 +20,7 @@ */ #include includes.h -#include lib/util/dlinklist.h +#include ../lib/util/dlinklist.h #include librpc/gen_ndr/com_dcom.h #include lib/com/dcom/dcom.h diff --git a/source4/ntvfs/sysdep/sys_lease_linux.c b/source4/ntvfs/sysdep/sys_lease_linux.c index 0727eed..41f1cbd 100644 --- a/source4/ntvfs/sysdep/sys_lease_linux.c +++ b/source4/ntvfs/sysdep/sys_lease_linux.c @@ -27,7 +27,7 @@ #include ntvfs/sysdep/sys_lease.h #include ntvfs/ntvfs.h #include librpc/gen_ndr/ndr_opendb.h -#include lib/util/dlinklist.h +#include ../lib/util/dlinklist.h #include cluster/cluster.h #define LINUX_LEASE_RT_SIGNAL (SIGRTMIN+1) -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated - 5c090e5cda0db947a435915b563145c23dbb30d7
The branch, master has been updated via 5c090e5cda0db947a435915b563145c23dbb30d7 (commit) from 0d99e58f272ab05873b706a154a528d04749c335 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit 5c090e5cda0db947a435915b563145c23dbb30d7 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 04:54:16 2008 +0200 Import Winbind NSS file for NetBSD in an attempt to fix the build on NetBSD. --- Summary of changes: {source3 = source4}/nsswitch/winbind_nss_netbsd.h |0 1 files changed, 0 insertions(+), 0 deletions(-) copy {source3 = source4}/nsswitch/winbind_nss_netbsd.h (100%) Changeset truncated at 500 lines: diff --git a/source3/nsswitch/winbind_nss_netbsd.h b/source4/nsswitch/winbind_nss_netbsd.h similarity index 100% copy from source3/nsswitch/winbind_nss_netbsd.h copy to source4/nsswitch/winbind_nss_netbsd.h -- Samba Shared Repository
[SCM] Samba Shared Repository - branch master updated - a19929dac185cebd4ec70e8aa3703a8bb884385f
The branch, master has been updated via a19929dac185cebd4ec70e8aa3703a8bb884385f (commit) via 7bd4e6e4956d4e979a6c272bc7de187e209b0710 (commit) from 5c090e5cda0db947a435915b563145c23dbb30d7 (commit) http://gitweb.samba.org/?p=samba.git;a=shortlog;h=master - Log - commit a19929dac185cebd4ec70e8aa3703a8bb884385f Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 05:59:50 2008 +0200 Add more tests to datablob testsuite. commit 7bd4e6e4956d4e979a6c272bc7de187e209b0710 Author: Jelmer Vernooij [EMAIL PROTECTED] Date: Sun Oct 12 05:23:26 2008 +0200 Use common signal helper implementation. --- Summary of changes: lib/util/tests/data_blob.c | 46 ++- source3/Makefile.in|2 +- source3/lib/signal.c | 138 3 files changed, 45 insertions(+), 141 deletions(-) delete mode 100644 source3/lib/signal.c Changeset truncated at 500 lines: diff --git a/lib/util/tests/data_blob.c b/lib/util/tests/data_blob.c index 5dd1adc..e0be7a4 100644 --- a/lib/util/tests/data_blob.c +++ b/lib/util/tests/data_blob.c @@ -27,10 +27,48 @@ static bool test_string(struct torture_context *tctx) DATA_BLOB blob = data_blob_string_const(bla); torture_assert_int_equal(tctx, blob.length, 3, blob length); - torture_assert_str_equal(tctx, blob.data, bla, blob data); + torture_assert_str_equal(tctx, (char *)blob.data, bla, blob data); - data_blob_free(blob); + return true; +} + +static bool test_zero(struct torture_context *tctx) +{ + int i; + DATA_BLOB z = data_blob_talloc_zero(tctx, 4); + torture_assert_int_equal(tctx, z.length, 4, length); + for (i = 0; i z.length; i++) + torture_assert_int_equal(tctx, z.data[i], 0, contents); + data_blob_free(z); + return true; +} + + +static bool test_clear(struct torture_context *tctx) +{ + int i; + DATA_BLOB z = data_blob(lalala, 6); + torture_assert_int_equal(tctx, z.length, 6, length); + data_blob_clear(z); + for (i = 0; i z.length; i++) + torture_assert_int_equal(tctx, z.data[i], 0, contents); + data_blob_free(z); + return true; +} + +static bool test_cmp(struct torture_context *tctx) +{ + DATA_BLOB a = data_blob_string_const(bla); + DATA_BLOB b = data_blob_string_const(blae); + torture_assert(tctx, data_blob_cmp(a, b) != 0, cmp different); + torture_assert(tctx, data_blob_cmp(a, a) == 0, cmp self); + return true; +} +static bool test_hex_string(struct torture_context *tctx) +{ + DATA_BLOB a = data_blob_string_const(\xC\xA\xF\xE); + torture_assert_str_equal(tctx, data_blob_hex_string(tctx, a), 0C0A0F0E, hex string); return true; } @@ -39,6 +77,10 @@ struct torture_suite *torture_local_util_data_blob(TALLOC_CTX *mem_ctx) struct torture_suite *suite = torture_suite_create(mem_ctx, DATABLOB); torture_suite_add_simple_test(suite, string, test_string); + torture_suite_add_simple_test(suite, zero, test_zero);; + torture_suite_add_simple_test(suite, clear, test_clear); + torture_suite_add_simple_test(suite, cmp, test_cmp); + torture_suite_add_simple_test(suite, hex string, test_hex_string); return suite; } diff --git a/source3/Makefile.in b/source3/Makefile.in index 6ebaa8f..d1eb3d5 100644 --- a/source3/Makefile.in +++ b/source3/Makefile.in @@ -319,7 +319,7 @@ LIB_OBJ = $(LIBSAMBAUTIL_OBJ) \ $(VERSION_OBJ) lib/charcnv.o lib/debug.o lib/fault.o \ lib/interface.o ../lib/crypto/md4.o \ lib/pidfile.o \ - lib/signal.o lib/system.o lib/sendfile.o lib/recvfile.o lib/time.o \ + ../lib/util/signal.o lib/system.o lib/sendfile.o lib/recvfile.o lib/time.o \ ../lib/util/time.o \ lib/ufc.o lib/genrand.o lib/username.o \ lib/util_pw.o lib/access.o lib/smbrun.o \ diff --git a/source3/lib/signal.c b/source3/lib/signal.c deleted file mode 100644 index 4b1c95e..000 --- a/source3/lib/signal.c +++ /dev/null @@ -1,138 +0,0 @@ -/* - Unix SMB/CIFS implementation. - signal handling functions - - Copyright (C) Andrew Tridgell 1998 - - 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.