1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-27 03:21:53 +03:00
Commit Graph

86648 Commits

Author SHA1 Message Date
Björn Jacke
22945de430 doc/msdfs proxy: extend example for multi target config
Signed-off-by: Björn Jacke <bj@sernet.de>
Reviewed-by: Michael Adam <obnox@samba.org>

Autobuild-User(master): Björn Jacke <bj@sernet.de>
Autobuild-Date(master): Fri Nov  1 00:12:19 CET 2013 on sn-devel-104
2013-11-01 00:12:18 +01:00
Volker Lendecke
85b5bedd43 smbd: Support multiple dfs targets for msdfs proxy shares
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Björn Jacke <bj@sernet.de>
2013-10-31 11:54:48 +01:00
Stefan Metzmacher
127fc670a3 libcli/smb: fix smb2cli_ioctl*() against Windows 2008.
The subsections of [MS-SMB2] "3.2.5.14 Receiving an SMB2 IOCTL Response"
say the client should ignore the InputOffset/InputCount.

We do that only if we ask for max_input_length = 0.

Bug: https://bugzilla.samba.org/show_bug.cgi?id=10232

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Thu Oct 31 01:16:10 CET 2013 on sn-devel-104
2013-10-31 01:16:09 +01:00
Gregor Beck
71dc7e593e s3:libsmb: SMBC_getatr() if no method worked, try all methods again on next attempt
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
f959dd44a0 client: use cli_qpathinfo3 for allinfo
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
569722ee40 s3:libsmb: cli_qpathinfo3 use cli_qpathinfo2 for smb2
cli_qpathinfo3 only works (and is only needed as fallback so far) for smb1.
Use cli_qpathinfo2 in the smb2 case to make it universally usable.

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
7e35a4dc73 client: remove a write only variable
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
0a3cc7e25c s3:libsmb: SMBC_getatr use pathinfo3 for second try
The pathinfo2 call might fail against NetApp because it is sending broken
packages.

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
0abe678af8 s3:libsmb: SMBC_getatr do not let ino undefined on success
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
cfedd4fe69 s3:libsmb: SMBC_getatr try pathinfo2 only once
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
30ba2c0580 s3:libsmb: add function cli_qpathinfo3()
This is a reimplemantation of cli_qpathinfo2 without the use of info level
SMB_QFILEINFO_ALL_INFO which leads to broken responses from NetApp.

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
8228c3c68c s3:libsmb: add function cli_qpathinfo_standard()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Gregor Beck
878f375820 s3:libsmb: pass creation or birth time in cli_qpathinfo_basic()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-30 15:23:51 -07:00
Alexander Werth
508b86e6ef s3:modules: nfs4_acls ACLs with zero entries are fine.
Signed-off-by: Alexander Werth <alexander.werth@de.ibm.com>
Reviewed-by: David Disseldorp <ddiss@samba.org>

Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Wed Oct 30 20:31:42 CET 2013 on sn-devel-104
2013-10-30 20:31:42 +01:00
Alexander Werth
a6bc2fd0d1 s3:modules: Fix realloc with zero sized ACLs
A realloc with size zero is similar to a free.
Since we return the number of acls that's not an error.

Signed-off-by: Alexander Werth <alexander.werth@de.ibm.com>
Reviewed-by: David Disseldorp <ddiss@samba.org>
2013-10-30 18:44:40 +01:00
Volker Lendecke
d35ce088fe rpc_server: Fix a typo
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
2013-10-30 18:44:38 +01:00
Matthieu Patou
8dc931bafc librpc-idl: change the drsuapi_DsBindInfoCtr so that it match what is on the wire both in NDR32 and NDR64.
Previous implementation had a problem with NDR64 with uint32 and
uint3264 being in the wrong order

Signed-off-by: Matthieu Patou <mat@matws.net>
Reviewed-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Wed Oct 30 10:16:02 CET 2013 on sn-devel-104
2013-10-30 10:16:02 +01:00
Andreas Schneider
5990de5d89 s3-rpc_client: Make data pointer const in trans_send().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Wed Oct 30 01:32:08 CET 2013 on sn-devel-104
2013-10-30 01:32:08 +01:00
Andreas Schneider
cd8f811247 s3-rpc_server: Remove obsolete make_internal_rpc_pipe().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 16:29:16 +01:00
Andreas Schneider
f69a490a87 s3-rpc_server: Remove obsolete FAKE_FILE_TYPE_NAMED_PIPE handling.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 16:28:58 +01:00
Andreas Schneider
b8e07323c9 s3-rpc_server: Use make_internal_rpc_pipe_socketpair().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 16:27:35 +01:00
Andreas Schneider
4498d07e73 s3-rpc_server: Pass the server event context to np_open().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 16:27:18 +01:00
Andreas Schneider
7daa4b94fa s3-rpc_server: Add make_internal_rpc_pipe_socketpair().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 16:17:03 +01:00
Andreas Schneider
327b0ddcd9 s3-smbd: Do not declare change_to_root_user() twice.
This is already in include/proto.h for smbd_shim.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:53:19 +01:00
Andreas Schneider
13d840ad2f s3-smbd_shim: Add become_authenticated_pipe_user().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:52:58 +01:00
Andreas Schneider
9e723f9d69 s3-rpc_server: Add named_pipe_client_init() function.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:51:47 +01:00
Andreas Schneider
921ef8f9eb s3-rpc_server: Make named_pipe_packet_process a shared functiion.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:51:08 +01:00
Andreas Schneider
1c069b1777 s3-rpc_server: Make make_server_pipes_struct a shared function.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:50:50 +01:00
Andreas Schneider
01524063cc s3-waf: Create a target for RPC_SOCK_HELPER.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:46:06 +01:00
Andreas Schneider
710ddf82ed s3-waf: Seperate rpc_server and rpc_service.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:45:39 +01:00
Andreas Schneider
df4c2df53b s3-waf: Reorder rpc_server wscript_build file.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:44:45 +01:00
Andreas Schneider
0733836b0e s3-rpc_server: Use new rpc named pipe functions.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:36:56 +01:00
Andreas Schneider
1e66a8e674 s3-rpc_server: Add make_internal_rpc_pipe().
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:35:49 +01:00
Andreas Schneider
155a794e74 s3-rpc_server: Add make_external_rpc_pipe() function.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:34:48 +01:00
Andreas Schneider
b86b4d0db1 s3-rpc_server: Add npa_state_init() function.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:33:26 +01:00
Andreas Schneider
eec05fb70f libcli: Add tstream_npa_socketpair() function.
Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-29 15:31:45 +01:00
Volker Lendecke
30e5a5c5bf rpc_server: Fix a memleak on error exit
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Oct 28 10:20:35 CET 2013 on sn-devel-104
2013-10-28 10:20:35 +01:00
Volker Lendecke
21803653bb rpc_server: Remove rpc_ep_register_state->mem_ctx
We can use the state directly as a parent

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2013-10-28 08:26:42 +01:00
Volker Lendecke
871e60297f rpc_server: Fix some uses of tevent_req_nomem
tevent_req_nomem is to be used in a sequence of async actions where we
have one main request. This is a completely independent loop without one
central tevent_req. tevent_req_nomem is used as a simple way to signal
an out of memory condition to the main request representing the async
sequence. If we don't have such a tevent_req, we need to directly check
for NULL.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2013-10-28 08:26:42 +01:00
Volker Lendecke
00132ab65c rpc_server: fix a typo
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2013-10-28 08:26:42 +01:00
Matthieu Patou
9c1c3bb4ec auth-kerberos: add the credentials.h so that enum credentials_obtained is defined
We had a warning about the enum being defined in the parameter list:
warning: ‘enum credentials_obtained’ declared inside parameter list

Signed-off-by: Matthieu Patou <mat@matws.net>
Reviewed-by: Andrew Bartlet <abartlet@samba.org>

Autobuild-User(master): Matthieu Patou <mat@samba.org>
Autobuild-Date(master): Sun Oct 27 02:25:47 CET 2013 on sn-devel-104
2013-10-27 02:25:46 +01:00
Stefan Metzmacher
1e2e421632 librpc-idl: replace int32 by uint32 as the values are always > 0
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-26 16:33:07 -07:00
Matthieu Patou
568bf16dfa librpc-idl: replace int32 by the enumeration as it's the type that we use in union's switch drsuapi_DsGetDCInfoCtrLevels
Signed-off-by: Matthieu Patou <mat@matws.net>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
2013-10-26 16:33:07 -07:00
David Disseldorp
68427f1e97 torture: add FSCTL_SRV_COPYCHUNK_WRITE access test
Check that FSCTL_SRV_COPYCHUNK_WRITE succeeds when the copy-chunk target
is opened with SEC_RIGHTS_FILE_WRITE only.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>

Autobuild-User(master): Jeremy Allison <jra@samba.org>
Autobuild-Date(master): Fri Oct 25 22:48:59 CEST 2013 on sn-devel-104
2013-10-25 22:48:59 +02:00
David Disseldorp
a13fda7472 smb2_ioctl: add support for FSCTL_SRV_COPYCHUNK_WRITE
FSCTL_SRV_COPYCHUNK can only be used when the client has the copy-chunk
target file open with FILE_WRITE_DATA and FILE_READ_DATA.
FSCTL_SRV_COPYCHUNK_WRITE requires only FILE_WRITE_DATA access on the
target, and is therefore suitable for cp --reflink, which opens the
target file O_WRONLY.

Signed-off-by: David Disseldorp <ddiss@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-10-25 11:41:19 -07:00
Volker Lendecke
ef4054eb88 Revert "smbd: Move oplock/sharemode ops into one place"
This reverts commit 7b70fa1873.

This is a change in behaviour which needs much further investigation
and testing.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>

Autobuild-User(master): David Disseldorp <ddiss@samba.org>
Autobuild-Date(master): Fri Oct 25 14:22:20 CEST 2013 on sn-devel-104
2013-10-25 14:22:20 +02:00
Volker Lendecke
4378db9819 Revert "smbd: Move oplock handling together"
This reverts commit e689b7d51e.

This is a change in behaviour which needs much further investigation
and testing.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: David Disseldorp <ddiss@samba.org>
2013-10-25 12:33:30 +02:00
Steven Siloti
319c2d7311 waf: parse LDFLAGS from python
The LDFLAGS returned by get_python_variables may contain additional library
search paths. These need to be parsed out and placed in LIBPATH to maintain
correct ordering of search paths in the final link flags.

Specifically, appending LDFLAGS directly to LINKFLAGS on my system was causing
/usr/lib to be the first search path specified. This lead to linking against
installed libraries rather than the versions from the current build.

Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Fri Oct 25 02:48:35 CEST 2013 on sn-devel-104
2013-10-25 02:48:35 +02:00
Michael Adam
64f5e24100 build: fix ordering problems with lib-provided and internal RPATHs
When a library or system (like cups) provides an RPATH,
e.g. with -Wl,-R or -Wl,-rpath, this was added by waf
to the LINKFLAGS, wich was later prepended to our RPATH.
But if the path by chance contains an older version of
one of our internal libraries like talloc, this would lead
to linking the too old talloc into our binaries.

This has been observed on, e.g., FreeBSD, but it is a general
problem.

This patch fixes the problem by specially parsing the RPATH
linker options from the pkg-config(, cups-config, ....) output
and putting the paths into the RPATH_<lib> container, which
is then later correctly appended to our internal RPATH.

Signed-off-by: Michael Adam <obnox@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-25 11:55:14 +13:00
Samuel Cabrero
d3aee80928 s4-dns: dlz_bind9: Create dns-HOSTNAME account disabled
Reviewed-by: Andrew Bartlett <abartlet@samba.org>

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Fri Oct 25 00:39:21 CEST 2013 on sn-devel-104
2013-10-25 00:39:21 +02:00