Björn Baumbach
6552ed64c1
s3-libsmb/passchange.c: Fix cli_errstr() usage (part of bug #7864 )
...
Convert cli_errstr() to nt_errstr()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-05-18 10:50:57 +02:00
Christian Ambach
20179bb550
s3:libsmb convert user-specified domain to uppercase
...
with client ntlmv2 auth = yes, there is a small difference between
using smbclient -U user\domain and smbclient -U user -W domain
if domain is provided in lowercase
using -W will uppercase the given parameter, while picking the
domain name from -U will not convert it to uppercase and this
leads to failing NTLMv2 authentication
with this patch, there is no difference between
smbclient -U domain\user and smbclient -U user -W domain any more
Autobuild-User: Christian Ambach <ambi@samba.org>
Autobuild-Date: Mon May 16 11:42:55 CEST 2011 on sn-devel-104
2011-05-16 11:42:55 +02:00
Volker Lendecke
30be9fe554
s3: Make&use set_socket_addr_v4
...
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat May 14 18:57:57 CEST 2011 on sn-devel-104
2011-05-14 18:57:57 +02:00
Volker Lendecke
f1cdce6c13
s3: Paranoia in smbsock_connect_state_destructor
...
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat May 14 14:19:01 CEST 2011 on sn-devel-104
2011-05-14 14:19:00 +02:00
Volker Lendecke
06a2ff5796
s3: Use tevent_req_ntstatus properly in a few places
2011-05-10 12:10:25 +02:00
Rusty Russell
87e3542174
async_smb.c: convert cli->timeout properly
...
I have a test failure on my 32-bit Ubuntu system, in that
samba3.smbtorture_s3.plain(s3dc).LOCK9 immediately times out (rather than
waiting 5 seconds for the child).
Debugging revealed this code: timeout is in ms and is set to > 1000 in
various places. The code dates from 2002, and other perturbations didn't
reveal why it breaks now, but fix it anyway.
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-User: Rusty Russell <rusty@rustcorp.com.au>
Autobuild-Date: Tue May 10 12:09:07 CEST 2011 on sn-devel-104
2011-05-10 12:09:07 +02:00
Rusty Russell
7deeacae2b
gencache: don't use CLEAR_IF_FIRST as fallback.
...
CLEAR_IF_FIRST only works if *all* openers use that flag.
So just truncate the file: it's racy, but that's what we're doing anyway.
We'd really need a TDB_OPENCHECK_OR_CLEAR flag to do this properly (or in
TDB2, a open hook at the right point).
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
2011-04-19 12:06:05 +09:30
Volker Lendecke
622faa2687
s3: Fix including libsmb/proto.h without prior ads.h
...
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat May 7 11:38:11 CEST 2011 on sn-devel-104
2011-05-07 11:38:11 +02:00
Günther Deschner
1e208a7057
s3-includes: no need to globally include libads/ads_status.h.
...
Guenther
2011-05-06 16:37:22 +02:00
Günther Deschner
675573d54b
s3-includes: finally only include client.h when libsmb is used.
...
Guenther
2011-05-06 16:37:22 +02:00
Günther Deschner
27022587e3
s3-libsmb: move protos to libsmb/proto.h
...
Guenther
2011-05-06 16:37:18 +02:00
Günther Deschner
d8cfca3a9b
s3: only include tdb headers where needed.
...
Guenther
2011-05-06 10:48:10 +02:00
Andrew Bartlett
e3b858496f
libcli/smb Move cifs posix helper functions and headers in common
...
unix_perms_to_wire() was a duplicate symbol in the top level build.
Andrew Bartlett
2011-05-06 07:51:24 +02:00
Andrew Bartlett
db74cad1c6
libcli/util Move NTSTATUS table to the top level
2011-05-06 07:51:24 +02:00
Andrew Bartlett
344eb08ee4
nterr: Add mem_ctx for return string from get_nt_error_c_code()
...
It is clearer to avoid the implicit return on talloc_tos()
Andrew Bartlett
2011-05-06 07:51:24 +02:00
Andrew Bartlett
f1ec28827f
libcli/util Merge ntstatus_to_dos() ntstatus_to_werror() to the top level
...
This takes the Samba4 version, with the NT_STATUS_IS_DOS() check.
This will be used in smbd/error.c shortly.
Andrew Bartlett
2011-05-06 07:51:24 +02:00
Andrew Bartlett
865a937671
errors: Merge ntstatus -> DOS error table between Samba3 and Samba4.
...
They are now identical
Andrew Bartlett
2011-05-06 07:51:24 +02:00
Jeremy Allison
7d6ebe0de7
More const fixes. Remove CONST_DISCARD.
2011-05-06 01:44:07 +02:00
Jeremy Allison
02af307585
More simple const fixes.
2011-05-05 23:56:07 +02:00
Jeremy Allison
e131c94ac1
More const fixes for compiler warnings from the waf build.
2011-05-05 23:56:07 +02:00
Jeremy Allison
4f41be356a
Fix many const compiler warnings.
2011-05-05 10:41:59 -07:00
Günther Deschner
ea8960448d
s3-libsmb: run minimal_includes.pl.
...
Guenther
2011-05-05 02:05:27 +02:00
Jeremy Allison
a3e913ae8b
Add in bufflen limit when storing NetBIOS names. Remove safe_strcpy.
2011-05-04 12:12:15 -07:00
Jeremy Allison
0c464df22b
Change safe_strcpy_base to strlcpy_base. Note the size doesn't change here as the original macro auto-added the -1.
2011-05-04 12:12:14 -07:00
Volker Lendecke
7febcb5ffe
s3: Filter out duplicates in name_query()
...
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Wed May 4 00:03:47 CEST 2011 on sn-devel-104
2011-05-04 00:03:47 +02:00
Volker Lendecke
8da8c36b53
s3: Tune broadcast namequeries for unique names
...
If we get a unique name via a broadcast query, there's no point in waiting the
full timeout. A unique name is just what its name says: unique. No point in
waiting longer.
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Tue May 3 00:57:24 CEST 2011 on sn-devel-104
2011-05-03 00:57:24 +02:00
Stefan Metzmacher
76b3867547
s3:libsmb/nterr: NO_S4U_PROT_SUPPORT and CROSSREALM_DELEGATION_FAILURE
...
metze
2011-05-02 13:58:23 +02:00
Volker Lendecke
d87427973c
s3: Make name_resolve_bcast return sockaddr_storage
...
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat Apr 30 20:40:46 CEST 2011 on sn-devel-104
2011-04-30 20:40:46 +02:00
Volker Lendecke
020b691cf8
s3: Remove ip_sevice from get_ipc_connect_master_ip
...
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Sat Apr 30 18:16:28 CEST 2011 on sn-devel-104
2011-04-30 18:16:28 +02:00
Jeremy Allison
de87f549b7
Add POSIX O_RDONLY test of a directory for bug #8112 - POSIX extension opens of a directory are denied with EISDIR.
...
Don't strip access bits from wire flags when opening a directory.
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Sat Apr 30 02:21:24 CEST 2011 on sn-devel-104
2011-04-30 02:21:24 +02:00
Günther Deschner
50883cfeb4
s3-tevent: only include ../lib/util/tevent wrappers where needed.
...
Guenther
Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Fri Apr 29 14:00:30 CEST 2011 on sn-devel-104
2011-04-29 14:00:30 +02:00
Andrew Bartlett
0520da2bbe
s3-smb Use FILE_ATTRIBUTE_ARCHIVE intead of aARCH
...
This means we use just one constant for this file attribute.
Andrew Bartlett
2011-04-29 16:38:13 +10:00
Andrew Bartlett
0eca33bbf6
s3-smb Use FILE_ATTRIBUTE_DIRECTORY intead of aDIR
...
This means we use just one constant for this file attribute.
Andrew Bartlett
2011-04-29 16:38:13 +10:00
Andrew Bartlett
0a3c84b554
s3-smb Use FILE_ATTRIBUTE_SYSTEM intead of aSYSTEM
...
This means we use just one constant for this file attribute.
Andrew Bartlett
2011-04-29 16:38:13 +10:00
Andrew Bartlett
317e19aeb3
s3-smb Use FILE_ATTRIBUTE_HIDDEN intead of aHIDDEN
...
This means we use just one constant for this file attribute.
Andrew Bartlett
2011-04-29 16:38:12 +10:00
Andrew Bartlett
7f66ebde2e
s3-smb Use FILE_ATTRIBUTE_READONLY intead of aRONLY
...
This means we use just one constant for this file attribute.
Andrew Bartlett
2011-04-29 16:38:12 +10:00
Andrew Bartlett
818ec32d0c
s3-libads Pass a struct sockaddr_storage to cldap routines
...
This avoids these routines doing a DNS lookup that has already been
done, and ensures that the emulated DNS lookup isn't thrown away.
Andrew Bartlett
2011-04-28 05:30:20 +02:00
Jeremy Allison
240465f96e
Remove another fstring in this code.
...
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Thu Apr 28 03:15:32 CEST 2011 on sn-devel-104
2011-04-28 03:15:32 +02:00
Jeremy Allison
af599b3d90
Fixup (C) - we've both worked lots on this :-).
...
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Apr 27 21:56:29 CEST 2011 on sn-devel-104
2011-04-27 21:56:29 +02:00
Jeremy Allison
1815f0298f
Remove fstrings from client struct. Properly talloc strings (ensuring we never end up with a NULL pointer).
2011-04-27 12:06:25 -07:00
Andrew Bartlett
e130dec97b
s3-libsmb Use 'resolv:hosts file' as a DNS emulation when specified.
...
This allows make test to operate without making real DNS calls.
Andrew Bartlett
2011-04-27 11:40:18 +10:00
Volker Lendecke
e81ea8a291
s3: Make cli_session_setup_lanman2 async
...
Signed-off-by: Jeremy Allison <jra@samba.org>
Autobuild-User: Jeremy Allison <jra@samba.org>
Autobuild-Date: Wed Apr 27 00:25:35 CEST 2011 on sn-devel-104
2011-04-27 00:25:34 +02:00
Volker Lendecke
531628e558
s3: Make cli_session_setup_nt1 async
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2011-04-26 12:22:55 -07:00
Volker Lendecke
40e2ee9cb6
s3: Make plaintext session setup async
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2011-04-26 12:22:55 -07:00
Volker Lendecke
ca9ac7c4c7
s3: Remove cli_write
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2011-04-26 12:22:55 -07:00
Volker Lendecke
0226428eb9
s3: Use cli_writeall instead of cli_write
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2011-04-26 12:22:55 -07:00
Volker Lendecke
d018fccb70
s3: Add cli_writeall
...
Signed-off-by: Jeremy Allison <jra@samba.org>
2011-04-26 12:22:55 -07:00
Volker Lendecke
80c395aef4
s3: Remove unused code
...
This is done in name_query_send these days
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Apr 25 19:24:58 CEST 2011 on sn-devel-104
2011-04-25 19:24:58 +02:00
Volker Lendecke
a3d35ac44b
s3: Move setting the name_query timeout
...
An async caller might want a different timeout behaviour
2011-04-25 18:39:20 +02:00
Volker Lendecke
b61c38fde6
s3: Fix some typos in dsgetdcname
...
Autobuild-User: Volker Lendecke <vlendec@samba.org>
Autobuild-Date: Mon Apr 25 12:35:30 CEST 2011 on sn-devel-104
2011-04-25 12:35:30 +02:00