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

3015 Commits

Author SHA1 Message Date
Volker Lendecke
699f86cc27 Revert "winbind4: Remove unused winbind_get_idmap irpc operation"
This reverts commit 41ff0f4454.

Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-02-18 10:28:28 +01:00
Stefan Metzmacher
bf1e65ceb8 s4:pyrpc: let dcerpc_interface_new() use py_dcerpc_interface_init_helper()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date(master): Mon Feb 17 21:39:30 CET 2014 on sn-devel-104
2014-02-17 21:39:30 +01:00
Stefan Metzmacher
4f31b3db35 s4:pyrpc: fix talloc hierachy in py_dcerpc_interface_init_helper()
The tevent_context is cached under the connection,
so we need to make sure it stays arround as long as the connection.

Otherwise it will segfault while dereferencing the tevent_context
on deallocation if a secondary connection is arround.

This completes commit 4cc3388c03,
which only fixed it in dcerpc_interface_new().

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-02-17 13:35:38 +01:00
Stefan Metzmacher
4d4e4ef619 s4:librpc/rpc: make dcerpc_pipe->binding const
This should not be changed after the connection is
ready for requests.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:18 +01:00
Stefan Metzmacher
0cc3e945b5 s4:librpc/rpc: pass dcerpc_binding arround as 'const'
This should only be modified by the owner.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:18 +01:00
Stefan Metzmacher
30fa344604 s4:librpc/rpc: only pass down dcecli_connection to the low level connect functions
They don't need dcerpc_pipe.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:18 +01:00
Stefan Metzmacher
2a68f5d4dd s4:librpc/rpc: don't create a ncacn_np: binding
It's up to the caller to store the dcerpc_pipe->binding.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:18 +01:00
Stefan Metzmacher
79c76ee54d s4:librpc/rpc: use dcerpc_binding_get_string_option() for "host" and "target_hostname"
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:18 +01:00
Stefan Metzmacher
4afe367c08 s4:librpc/rpc: use dcerpc_binding_get_string_option("target_principal")
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:18 +01:00
Stefan Metzmacher
f309d67fcd s4:librpc/rpc: make use of dcerpc_binding_get_string_option("endpoint")
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:18 +01:00
Stefan Metzmacher
26c2a27c2d s4:librpc/rpc: make use of dcerpc_binding_get_flags()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:17 +01:00
Stefan Metzmacher
00073465df s4:librpc/rpc: make use of dcerpc_binding_get_*() in dcerpc_connect.c
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:16 +01:00
Stefan Metzmacher
a281574c9f s4:librpc/rpc: remove unused dcerpc_pipe->assoc_group_id
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
cef6b2d9d7 s4:librpc/rpc: make use of dcerpc_binding_[g|s]et_assoc_group_id()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
16de18e5a2 s4:librpc/rpc: make use of dcerpc_binding_[g|s]et_* functions in dcerpc_epm_map_binding_send()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
c50664f68f s4:librpc/rpc: always call dcerpc_binding_set_abstract_syntax() in dcerpc_epm_map_binding_send()
We should always set the abstract syntax even if we don't ask the endpoint
mapper.

By using dcerpc_binding_set_abstract_syntax() instead of calling
binding->object = table->syntax_id, we will be able to separate
the abstract_syntax from the object uuid in future.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
8ccebf3a27 s4:librpc/rpc: the table argument to dcerpc_epm_map_binding_send() isn't optional
We already dereference it unchecked later, so we can avoid some indentation.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
df4a900aa6 s4:librpc/tests: add dcerpc_binding assoc_group_id tests
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
06410872a1 s4:librpc/tests: add dcerpc_binding target_hostname/target_principal tests
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
c2e1dedb81 s4:librpc/tests: use dcerpc_binding_get*() functions
We should not dereference struct dcerpc_binding.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:15 +01:00
Stefan Metzmacher
afcd5506c9 librpc/rpc: remove dcerpc_binding->localaddress and store it in the options array
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:14 +01:00
Stefan Metzmacher
c327a60a02 librpc/rpc: let derpc_binding_string() add ncacn_options before key=value options
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:14 +01:00
Stefan Metzmacher
91a367dce5 s4:librpc/rpc: use dcerpc_binding_[g|set]_string_option("localaddress")
We should avoid deferencing struct dcerpc_binding if possible.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:14 +01:00
Stefan Metzmacher
1228a935ac s4:librpc/rpc: use dcerpc_binding_dup() before modifying the given binding
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-13 11:54:13 +01:00
Stefan Metzmacher
e42a674625 s4:librpc/rpc: make use of dcerpc_binding_dup() in dcerpc_epm_map_binding_send()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:20:32 +01:00
Stefan Metzmacher
4340590ae9 s4:librpc/rpc: fix memory hierachie in dcerpc_epm_map_binding_send()
We should allocate on 's' the internal state, not on the callers
mem_ctx.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:20:32 +01:00
Stefan Metzmacher
4cf691ce1f s4:librpc/rpc: avoid some indentation levels in dcerpc_epm_map_binding_send()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:20:32 +01:00
Stefan Metzmacher
6e813ab897 s4:librpc/rpc: use dcerpc_binding_dup() in dcerpc_schannel_key_send()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:20:32 +01:00
Stefan Metzmacher
cd4ae0f7f3 s4:librpc/test: an empty hostname means b->host == NULL
In future we'll not allow b->host == "" any more.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:20:31 +01:00
Stefan Metzmacher
327c060666 s4:librpc/rpc: remove prototypes which are already in librpc/rpc/rpc_common.h
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:20:28 +01:00
Stefan Metzmacher
d791f3354e s4:librpc/rpc: use the correct _recv function in continue_open_pipe()
We start with dcerpc_pipe_open_unix_stream_send() so we need
to call dcerpc_pipe_open_unix_stream_recv().

It was just luck that it worked before...

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:20:28 +01:00
Stefan Metzmacher
2e093cc0cc s4:librpc/rpc: only propose header signing if we use sign or seal
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:02:14 +01:00
Stefan Metzmacher
1137d62d9d s4:librpc/rpc: add forward declaration for struct resolve_context
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-02-11 16:02:14 +01:00
Volker Lendecke
41ff0f4454 winbind4: Remove unused winbind_get_idmap irpc operation
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Kai Blin <kai@samba.org>

Autobuild-User(master): Volker Lendecke <vl@samba.org>
Autobuild-Date(master): Mon Feb 10 13:24:09 CET 2014 on sn-devel-104
2014-02-10 13:24:09 +01:00
Garming Sam
63c24977ba param: rename lp function and variable from 'lockdir' to 'lock_directory'
Signed-off-by: Garming Sam <garming@catalyst.net.nz>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2014-02-07 16:19:10 -08:00
Stefan Metzmacher
dc561b7e2d dcerpc.idl: make use of union dcerpc_bind_ack_reason and fix all callers.
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>

Autobuild-User(master): Günther Deschner <gd@samba.org>
Autobuild-Date(master): Thu Jan 16 18:21:40 CET 2014 on sn-devel-104
2014-01-16 18:21:40 +01:00
Stefan Metzmacher
7a62a35577 s4:librpc/rpc: change dcerpc_map_reason() into dcerpc_map_nak_reason()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-01-16 16:22:53 +01:00
Stefan Metzmacher
0648f6e66e s4:librpc/rpc: add dcerpc_map_ack_reason()
This is not the value as dcerpc_bind_ack_reason values are not the same
as dcerpc_bind_nak_reason values.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-01-16 16:22:53 +01:00
Stefan Metzmacher
9b2dc0e46c s4:librpc: remove dcerpc_event_context()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Guenther Deschner <gd@samba.org>
2014-01-16 16:22:52 +01:00
Matthias Dieter Wallnöfer
0c2fbe5a0c samba:python - Py_RETURN_NONE remove compatibility code for releases < 2.4
http://www.python.org/doc//current/c-api/none.html

Reviewed-By: Jelmer Vernooij <jelmer@samba.org>

Autobuild-User(master): Matthias Dieter Wallnöfer <mdw@samba.org>
Autobuild-Date(master): Thu Jan  9 16:27:47 CET 2014 on sn-devel-104
2014-01-09 16:27:47 +01:00
Gregor Beck
6b586c3cf6 s4:librpc: remove recv_data from transport
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>

Autobuild-User(master): Stefan Metzmacher <metze@samba.org>
Autobuild-Date(master): Tue Jan  7 12:42:32 CET 2014 on sn-devel-104
2014-01-07 12:42:32 +01:00
Gregor Beck
9d2557d6e4 s4:librpc: factor out xxx_send_request() to dcerpc_send_request()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:46 +01:00
Gregor Beck
445913133a s4:librpc: factor out xxx_send_read() to dcerpc_send_read()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:46 +01:00
Gregor Beck
9832eb6bbf s4:librpc: factor out xxx_shutdown_pipe() to dcerpc_shutdown_pipe()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:46 +01:00
Gregor Beck
30ca477c71 s4:librpc: factor out xxx_dead() to dcerpc_transport_dead()
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:46 +01:00
Gregor Beck
3193c27256 s4:librpc: remove server_name from transport
Signed-off-by: Gregor Beck <gbeck@sernet.de>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:45 +01:00
Stefan Metzmacher
383ba3dacf s4:librpc: make 'struct dcerpc_pipe_connect' private
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:45 +01:00
Stefan Metzmacher
27d0d32105 s4:librpc: remove unused dcerpc_smb2.c
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:45 +01:00
Stefan Metzmacher
a9bb84c4b0 s4:librpc: implement dcerpc_pipe_open_smb2() in dcerpc_smb.c
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:45 +01:00
Stefan Metzmacher
7352f7f91d s4:librpc: make use of dcerpc_pipe_open_smb_send/recv for SMB2
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:44 +01:00
Stefan Metzmacher
45fc961932 s4:librpc: pass dcecli_connection instead of dcerpc_pipe to dcerpc_secondary_smb_send()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:44 +01:00
Stefan Metzmacher
bebc05a973 s4:librpc: use dcerpc_binding_dup() instead of talloc_reference()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:44 +01:00
Stefan Metzmacher
a08ee93a2f s4:librpc: pass smbXcli_{conn,session,tcon} to dcerpc_pipe_open_smb_send()
This will allow it to be used also for smb2 later.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:44 +01:00
Stefan Metzmacher
f7b1ff2cf4 s4:librpc: don't talloc_reference smbcli_tree
It's the job of the caller to make sure it stays for the
whole lifetime of the connection.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:43 +01:00
Stefan Metzmacher
e6474ba2c2 s4:librpc: keep smbcli_tree/smb2_tree as talloc child of dcecli_connection
This will avoid the need of talloc_reference later.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:43 +01:00
Gregor Beck
d230f73e97 s4:librpc: use tstream_smbXcli_np in dcerpc_smb.c
Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:43 +01:00
Gregor Beck
2ec65ea1e7 s4:librpc: use tstream in dcerpc_sock.c
Pair-Programmed-With: Stefan Metzmacher <metze@samba.org>

Signed-off-by: Gregor Beck <gbeck@sernet.de>
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:43 +01:00
Stefan Metzmacher
01ea63e1a1 s4:librpc: make it possible for the transport to specify the max_xmit/recv_size
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:42 +01:00
Stefan Metzmacher
d821661484 s4:librpc/rpc: update alloc_hint for each fragment
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:36 +01:00
Stefan Metzmacher
ce84ade56c s4:librpc/rpc: remove unused rpc_request->ndr structure
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:36 +01:00
Stefan Metzmacher
a0f781cca4 s4:librpc: fix memory leaks in dcerpc_request_recv_data()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-01-07 08:37:35 +01:00
Stefan Metzmacher
b61f71730f s4:librpc: fix memory leak in ncacn_pull()
Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Michael Adam <obnox@samba.org>
2014-01-07 08:37:35 +01:00
Stefan Metzmacher
4cc3388c03 s4:pyrpc: fix talloc hierachie in dcerpc_InterfaceObject
The tevent_context is cached under the connection,
so we need to make sure it stays arround as long as the connection.

Otherwise it will segfault while dereferencing the tevent_context
on deallocation if a secondary connection is arround.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2014-01-07 08:37:34 +01:00
Stefan Metzmacher
7db1dc13b0 s4:librpc: always try to negotiate DCERPC_PFC_FLAG_SUPPORT_HEADER_SIGN
If the gensec backend supports it there's no reason not sign the header.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2014-01-07 00:27:11 +01:00
Stefan Metzmacher
127de4f4ac CVE-2013-4408:s4:dcerpc_sock: check for invalid frag_len within sock_complete_packet()
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10185

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-12-09 07:05:45 +01:00
Stefan Metzmacher
77c3518152 CVE-2013-4408:s4:dcerpc_smb2: check for invalid frag_len in send_read_request_continue()
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10185

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-12-09 07:05:45 +01:00
Stefan Metzmacher
3be7907fd9 CVE-2013-4408:s4:dcerpc_smb: check for invalid frag_len in send_read_request_continue()
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10185

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-12-09 07:05:45 +01:00
Stefan Metzmacher
db5fff3bc9 CVE-2013-4408:s4:dcerpc: check for invalid frag_len in ncacn_pull()
Bug: https://bugzilla.samba.org/show_bug.cgi?id=10185

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Jeremy Allison <jra@samba.org>
2013-12-09 07:05:45 +01:00
Stefan Metzmacher
a62927ef88 s4:librpc: let dcerpc_schannel_key_recv() return netlogon_creds_CredentialState
cli_credentials_set_netlogon_creds() should only be used directly before
a DCERPC bind in order to pass the session information to the
gensec layer.

Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-17 08:49:00 +13:00
Stefan Metzmacher
300a186a71 s4:librpc: make dcerpc_schannel_key_send/recv static
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-17 08:49:00 +13:00
Stefan Metzmacher
d610339028 s4:librpc/rpc: remove unused dcerpc_smb_tree()
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-17 08:48:55 +13:00
Stefan Metzmacher
e9998d1668 s4:librpc/rpc: make use of dcerpc_secondary_smb_send/recv() in dcerpc_secondary_context()
This avoids the use of dcerpc_smb_tree(), which is a layer violation.

Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-17 08:48:54 +13:00
Stefan Metzmacher
07ec60ce72 s4:librpc/rpc: add dcerpc_secondary_smb_send/recv()
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-17 08:48:54 +13:00
Stefan Metzmacher
ecb3150587 s4:librpc/rpc: remove unused dcerpc_smb_fnum()
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-17 08:48:53 +13:00
Stefan Metzmacher
d052528974 s4:librpc: implement dcerpc_binding_handle_auth_info()
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-10-17 08:48:44 +13:00
Stefan Metzmacher
ae6166a3c1 s4:librpc: avoid talloc_reference() in dcerpc_epm_map_binding_send()
Signed-off-by: Stefan Metzmacher <metze@samba.org>

Reviewed-by: Andrew Bartlett <abartlet@samba.org>
2013-08-12 16:48:46 +12:00
Stefan Metzmacher
34fa794699 s4:librpc: fix netlogon connections against servers without AES support
LogonGetCapabilities() only works on the credential chain if
the server supports AES, so we need to work on a temporary copy
until we know the server replied a valid return authenticator.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2013-08-05 10:30:01 +02:00
Günther Deschner
a9d5b2fdf0 libcli/auth: also set secure channel type in netlogon_creds_client_init().
Signed-off-by: Günther Deschner <gd@samba.org>
Reviewed-by: Stefan Metzmacher <metze@samba.org>
Reviewed-by: Andreas Schneider <asn@samba.org>
2013-08-05 10:30:00 +02:00
Bill Parker
9b58da9866 Fix bug 10025 - Lack of Sanity Checking in calls to malloc()/calloc().
In reviewing various files in Samba-4.0.7, I found a number
of instances where malloc()/calloc() were called without the
checking the return value for a value of NULL, which would
indicate failure.

(NB. The changes needed to ccan, iniparser, popt and heimdal
will be reported upstream, not patched inside Samba).

Reviewed-by: Jeremy Allison <jra@samba.org>
Reviewed-by: Simo Source <idra@samba.org>
2013-07-17 16:12:19 -07:00
Andrew Bartlett
d87b81fa30 build: Move nfs4acl to the top level
This is to create IDL-stored NFSv4 ACLs, just as we use for posix ACLs
to permit better testing.

Andrew Bartlett

Reviewed-by: Jeremy Allison <jra@samba.org>
2013-05-09 06:18:20 +02:00
Andreas Schneider
7937a6afcb s4-librpc: Remove dead code in smb_send_request().
If trigger_read we return earlier.

Found by Coverity.

Signed-off-by: Andreas Schneider <asn@samba.org>
Reviewed-by: Günther Deschner <gd@samba.org>
2012-12-21 13:56:00 +01:00
Andrew Tridgell
b0cc0d5698 s4-librpc: set error code to LOGON_FAILURE on RPC fault with access denied
this allows the client code to trigger a retry with a new password
callback for NTLM connections

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2012-11-01 15:40:41 +11:00
Andrew Tridgell
5d6ae3498a s4-librpc: try a 2nd logon for more error cases
not all servers give LOGON_FAILURE on authentication failures, so we
need to do the retry with a new ticket on a wider range of error types

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2012-11-01 15:40:41 +11:00
Andrew Tridgell
ed2e69fe91 s4-librpc: use cli_credentials_failed_kerberos_login to cope with stale tickets
This allows our RPC client code to cope with a kerberos server
changing password while we have a valid service ticket

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2012-11-01 15:40:40 +11:00
Andrew Bartlett
76b7348299 pymessaging: Use the server_id IDL structure rather than a tuple
This will make it easier to pass this structure in and out.  The tuple is still
accepted as input.

Andrew Bartlett
2012-10-31 08:13:56 +11:00
Andrew Bartlett
3b4ef03097 imessaging: Add irpc_all_servers() to list all available servers
This is implemented with a tdb_traverse_read(), and will allow a tool
to disover the name and server_id of all Samba processes, as each
process registers itself to recieve messages.

Andrew Bartlett
2012-10-31 08:13:56 +11:00
Stefan Metzmacher
89a5a71654 s4:librpc/rpc: don't do async requests if gensec doesn't support async replies (bug #9097)
metze
2012-08-25 01:39:41 +02:00
Stefan Metzmacher
0bd0ad967d s4:librpc/rpc: also call dcerpc_schedule_io_trigger() after bind and alter_context responses
metze
2012-08-25 01:39:41 +02:00
Stefan Metzmacher
e44b5bdb2c s4:librpc/rpc: use dcerpc_req_dequeue() in dcerpc_request_recv_data()
metze
2012-08-25 01:39:41 +02:00
Stefan Metzmacher
81bc57d395 s4:librpc/rpc: use talloc_zero for 'struct rpc_request'
metze
2012-08-25 01:39:41 +02:00
Andrew Bartlett
1219eaffbe s4-python: Complete python bindings for idmap.idl
Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Wed Aug 22 03:08:51 CEST 2012 on sn-devel-104
2012-08-22 03:08:51 +02:00
Andrew Bartlett
10267f153c s4-python: complete python bindigns for smb_acls.idl 2012-08-22 01:31:57 +02:00
Volker Lendecke
5251d07e62 s4: Fix returns in py_check_dcerpc_type
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2012-08-17 00:57:19 +02:00
Stefan Metzmacher
7977d90f1e s4:librpc/dcerpc_smb2: sync smb2_session_key() with smb_session_key()
metze
2012-08-01 14:17:14 +02:00
Stefan Metzmacher
286e249737 s4:librpc/dcerpc_smb: make use of smbXcli_session_application_key()
metze
2012-08-01 14:17:13 +02:00
Stefan Metzmacher
803fb40449 s4:librpc/dcerpc_smb2: make use of smbXcli_session_application_key()
metze
2012-08-01 14:17:13 +02:00
Andrew Bartlett
fc6d7bfbe7 s4-librpc: Fix private context for dcerpc_connect_timeout_handler
This was incorrect in 02a356ea77.

Andrew Bartlett

Autobuild-User(master): Andrew Bartlett <abartlet@samba.org>
Autobuild-Date(master): Sun Jul 29 14:54:33 CEST 2012 on sn-devel-104
2012-07-29 14:54:32 +02:00
Andrew Bartlett
02a356ea77 s4-librpc: Ensure we do not call call the decrpc timeout handler during gensec_update()
This avoids a situation where we could destroy pointers on the stack due to
a nested event loop.

This is certainly not a final, generic solution, but it is a minimal change
while we work to make gensec and gensec_gssapi async.

Andrew Bartlett
2012-07-18 09:32:53 +02:00
Andreas Schneider
197781a651 s4-librpc: Add capabilities check for AES encrypted connections.
Signed-off-by: Günther Deschner <gd@samba.org>
2012-07-17 13:26:34 +02:00
Stefan Metzmacher
780006db9d s4:librpc/rpc: add DCERPC_SCHANNEL_AES support
metze

Signed-off-by: Günther Deschner <gd@samba.org>
2012-07-17 10:58:39 +02:00
Stefan Metzmacher
342a2e6181 s4:librpc/rpc/dcerpc_schannel: just append NETLOGON_NEG_RODC_PASSTHROUGH as rodc
The RODC stuff doesn't depend on the schannel algorithm.

metze

Signed-off-by: Günther Deschner <gd@samba.org>
2012-07-17 10:58:38 +02:00
Stefan Metzmacher
e7c7a91130 s4:librpc/rpc/dcerpc_schannel: rework downgrade logic
metze

Signed-off-by: Günther Deschner <gd@samba.org>
2012-07-17 10:58:38 +02:00
Andrew Bartlett
1e28aa147f build: Add missing deps and make MESSAGING a private library
To remove finddcs_nbt these missing deps need to be added.  These
subsystems linked to to implicit dependencies provided by finddcs.
Due to the new arrangmenet of subsystems, MESSAGING needs to be a
private library to avoid being a source of duplicate symbols.

Andrew Bartlett
2012-06-07 06:45:06 +02:00
Stefan Metzmacher
5629eb7802 s4:librpc: create a binding on the pipe if necessary in dcerpc_pipe_open_smb2_send()
Pair-Programmed-With: Michael Adam <obnox@samba.org>
2012-04-27 17:44:06 +02:00
Stefan Metzmacher
df27ba3e8b s4:librpc/rpc: directly return after composite_error()
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Mon Apr 23 12:17:08 CEST 2012 on sn-devel-104
2012-04-23 12:17:08 +02:00
Stefan Metzmacher
0971a4ee6c s4:librpc/rpc: also parse ncacn_packet pdus with LIBNDR_FLAG_OBJECT_PRESENT
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Tue Apr  3 23:06:31 CEST 2012 on sn-devel-104
2012-04-03 23:06:30 +02:00
Stefan Metzmacher
05ceb53dda s4:librpc/rpc: don't mix up paylod ndr flags with the dcerpc layer
If the transfer syntax is NDR64, it's only for the payload not
for the dcerpc pdus.

metze
2012-04-03 20:02:10 +02:00
Jelmer Vernooij
95ca5fbadd libndr: Rename ndr64_transfer_syntax and null_ndr_syntax_id so they have a ndr_ prefix.
This makes the NDR namespace a bit clearer, in preparation of ABI checking.
2012-03-20 13:54:07 +01:00
Jelmer Vernooij
0affe19304 Remove more unnecessary shebang lines in python files.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Fri Mar 16 02:48:52 CET 2012 on sn-devel-104
2012-03-16 02:48:52 +01:00
Stefan Metzmacher
ebcfa61d9f s4:librpc/rpc: avoid an unused talloc_reference() from dcerpc_request_send()
metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
bb75905b6a s4:librpc/rpc: pass a mem_ctx to dcerpc_request_send()
metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
cd1d5a29d4 s4:librpc/rpc: use tevent_req_defer_callback() in dcerpc_alter_context_*
metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
6d631e52cf s4:librpc/rpc: use tevent_req_defer_callback() in dcerpc_bind_*
metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
198c5ace6f s4:librpc/rpc: convert dcerpc_alter_context_send/recv to tevent_req
Many thanks to Andrew Bartlett <abartlet@samba.org> for the
debugging, which lead to the following line:

       talloc_steal(state, raw_packet->data);

metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
6b81d71f3e s4:librpc/rpc: convert dcerpc_bind_send/recv to tevent_req
Many thanks to Andrew Bartlett <abartlet@samba.org> for the
debugging, which lead to the following line:

       talloc_steal(state, raw_packet->data);

metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
946eca438d s4:librpc/rpc: also notify requests which are not shipped about a dead connection
metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
080549f467 s4:librpc/rpc: ship requests via an immediate event
Deep inside dcerpc_ship_next_request() some code path
could trigger dcerpc_connection_dead(), which means
it's not safe to do any processing after calling dcerpc_ship_next_request().

metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
553a8921a4 s4:librpc/rpc: if the connecion is dead we're done
There's no point in doing anymore processing,
it can just lead to crashes.

metze
2012-03-15 07:35:28 +01:00
Stefan Metzmacher
6949a79087 s4:librpc/rpc: if the connection is dead we don't want to be called recursivly.
metze
2012-03-15 07:35:28 +01:00
Andrew Bartlett
193078117d s4-librpc: Remove unused new_ev
Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Fri Mar  9 07:18:45 CET 2012 on sn-devel-104
2012-03-09 07:18:45 +01:00
Stefan Metzmacher
7b1fb08842 s4:librpc/rpc: make dcerpc_bh_raw_call_* more robust against disconnects and timeouts
Using tevent_req_defer_callback() should make the situation a bit better,
until we have a common robust low level dcerpc library.

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Mar  7 18:44:24 CET 2012 on sn-devel-104
2012-03-07 18:44:24 +01:00
Stefan Metzmacher
01c404a67c s4:librpc/rpc: make dcerpc_bh_is_connected() more robust
metze
2012-03-07 17:01:17 +01:00
Michael Adam
e9210987c6 s4:libcli:smb2: add a previous session argument to smb2_connect_send() 2012-02-28 00:08:53 +01:00
Stefan Metzmacher
07b1de98cd s4:librpc/dcerpc_smb2: make use of smb2cli_session_application_key()
metze
2012-02-27 12:51:34 +01:00
Stefan Metzmacher
1b45f2aed8 s4:pyrpc: add 'user_session_key' getter to the connection object
This gets the session key from gensec for usage in DRSUAPI.

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Jan  4 22:31:52 CET 2012 on sn-devel-104
2012-01-04 22:31:52 +01:00
Andreas Schneider
a7541fc27e s4-librpc: Fix netlogon schannel client connect.
As a client we request as much flags as possible. The server checks
which flags it supports and returns the same negotiation flags or less.
So we need to store the negotiate flags from the server. We need them
later if we have to call netr_LogonGetCapabilities.
2011-12-22 17:48:24 +01:00
Andreas Schneider
17d124490b s4-librpc: Fix NETLOGON credential chain with Windows 2008.
Windows Server 2008 returns NT_STATUS_DOWNGRADE_DETECTED if you call
netrServerAuthenticate2 during a domain join without setting the strong
keys flag (128bit crypto).

Only for NT4 we need to do a downgrade to the returned negotiate flags.

See also 0970369ca0.
2011-12-14 13:41:28 +01:00
Stefan Metzmacher
4afbda221c s4:libcli/raw: implement on top of smbXcli_conn/req
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Wed Nov 30 15:13:36 CET 2011 on sn-devel-104
2011-11-30 15:13:36 +01:00
Stefan Metzmacher
300343d16c s4:libcli/smb2: implement on top of smbXcli_conn/req
metze
2011-11-24 19:02:33 +01:00
Matthieu Patou
7c9b3cdcf7 s4-librpc: do not limit to the first IP when trying to do a rpc connection
The function continue_ip_resolve_name was calling resolve_name_recv which returns
only the first IP for a given hostname.
Instead we use resolve_name_multiple_recv which returns all the IP for a given
hostname. This kind of problem can occur if a host has more than 1 IP but is listenning
only on 1.
2011-11-11 20:28:11 +01:00
Kai Blin
23000bcf2e dns: Build the python bindings 2011-11-04 15:51:58 +01:00
Günther Deschner
6e67073900 waf: convert NDR_NBT into shared library.
Guenther
2011-11-03 18:35:09 +01:00
Günther Deschner
185b94eefa nbt: trim down header dependencies of nbt.idl.
Guenther
2011-11-03 18:35:08 +01:00
Stefan Metzmacher
6c07505b15 s4:librpc/dcerpc_smb2: fix smb2_write_callback()
The should use smb2_write_recv() to get the result.

metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Fri Oct 28 09:55:48 CEST 2011 on sn-devel-104
2011-10-28 09:55:48 +02:00
Stefan Metzmacher
926b3394b6 s4:librpc/dcerpc_smb: fix smb_write_callback()
The should use smb_raw_write_recv() to get the result.

metze
2011-10-28 08:11:00 +02:00
David Disseldorp
281fc93c6b libcli: move ioctl function field defs to smb_constants
Currently there are a lot of duplicate ioctl function field definitions
between source3 and source4.

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-10-19 15:44:29 +02:00
Andrew Bartlett
e7d5f0a357 gensec: move event context from gensec_*_init() to gensec_update()
This avoids keeping the event context around on a the gensec_security
context structure long term.

In the Samba3 server, the event context we either supply is a NULL
pointer as no server-side modules currently use the event context.

Andrew Bartlett

Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-10-18 13:13:33 +11:00
Andrew Bartlett
3cdb1fe440 s4-messaging: Pass the loadparm context, not just the messaging path
This will allow the TDB layer to get at the lp_ctx for tdb options.

Andrew Bartlett
2011-10-13 14:06:07 +02:00
Andrew Bartlett
b21b012756 lib/param move source4 param code to the top level
This is done so that the lpcfg_ functions are available across the whole
build, either with the struct loadparm_context loaded from an smb.conf directly
or as a wrapper around the source3 param code.

This is not the final, merged loadparm, but simply one step to make
it easier to solve other problems while we make our slow progress
on this difficult problem.

Andrew Bartlett
2011-10-11 13:41:34 +11:00
Andrew Tridgell
57e30bc0cb dns: build python bindings for dnsserver RPC protocol 2011-10-04 15:08:56 +11:00
Andrew Tridgell
3e685f5995 s4-rpc: show binding string in failed rpc binds
this makes debugging some RPC auth issues easier
2011-09-22 10:00:49 +10:00
Stefan Metzmacher
afabf12251 s4:librpc/rpc: return NT_STATUS_CONNECTION_DISCONNECTED
We should return the same in all places.

metze
2011-09-14 18:03:18 +02:00
Andrew Bartlett
8c33036a37 s4-subdomain more work on sub-domain join
we can now create a subdomain of an existing windows domain using:

  samba-tool domain join sub.domain.dns.name subdomain

The ordering of the creation of the key records is quite tricky,
especially for the NTDSDSA object

Pair-Programmed-With: Andrew Tridgell <tridge@samba.org>
2011-09-13 15:38:02 +10:00
Jelmer Vernooij
df1d3dc777 s4-python: Consistently use spaces rather than tabs, fix headers in several places. 2011-09-13 02:24:03 +02:00
Stefan Metzmacher
b9cc4dd088 s4:librpc: rpc_common.h was move to dcerpc-binding
metze
2011-09-06 15:22:19 +02:00
Andrew Bartlett
c8f13dab6b build: Add dcerpc-binding to dcerpc.pc
This will help projects like OpenChange that depend on
this code, now that it has been split between two libraries.

Andrew Bartlett
2011-08-26 14:06:07 +02:00
Amitay Isaacs
c71e781e7d py_security: Fix comparison between two dom_sid objects
dom_sid_compare() function can return values other than -1, 0, 1.
Python requires compare function to return value from [-1, 0, 1].

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-08-19 16:35:03 +10:00
Jelmer Vernooij
292fe74971 credentials: Rename library to samba-credentials to avoid name clashes.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Thu Aug 18 22:16:38 CEST 2011 on sn-devel-104
2011-08-18 22:16:38 +02:00
Jelmer Vernooij
9ee1e1f0ac cli-raw: Add public libsmbclient-raw library. 2011-08-18 14:19:18 +02:00
Simo Sorce
4a8fdc3958 s4:librpc: use tevent_ fn names instead of legacy event_ ones 2011-08-13 09:54:15 -04:00
Jelmer Vernooij
f8ec7f6cb1 pytalloc: Use consistent prefix for functions, add ABI file. 2011-08-10 15:36:21 +02:00
Andrew Bartlett
dd49eb87ce build: rename rpcommon to dcerpc-binding an make a public library
OpenChange needs this library.

Andrew Bartlett
2011-08-08 13:34:06 +02:00
Andrew Bartlett
af5f494bd2 build: provide tevent-util as a public library
This is needed so that OpenChange can get at _tevent_req_nterr(), which is referenced
by generated PIDL output.

Andrew Bartlett
2011-08-08 13:34:06 +02:00
Andreas Schneider
68e7b9307a s4-librpc: Fix double free.
Autobuild-User: Andreas Schneider <asn@cryptomilk.org>
Autobuild-Date: Thu Aug  4 12:31:18 CEST 2011 on sn-devel-104
2011-08-04 12:31:18 +02:00
Andrew Bartlett
d3fe48ba48 gensec: Remove mem_ctx from calls that do not return memory
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-08-03 18:48:01 +10:00
Stefan Metzmacher
695af0f6ed winsif.idl: fix comment about a pidl bug
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Mon Aug  1 17:47:05 CEST 2011 on sn-devel-104
2011-08-01 17:47:05 +02:00
Jelmer Vernooij
7524413751 cli_raw: Make name lowercase.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sat Jul 23 23:20:51 CEST 2011 on sn-devel-104
2011-07-23 23:20:51 +02:00
Andrew Bartlett
77c612fc21 s4-librpc Remove unsued server_id4.idl 2011-06-10 03:27:20 +02:00
Andrew Bartlett
a772797a38 librpc/idr Use the Samba3 notify.idl in common.
The extra fields in the structure that Samba4 does not use should not
bother it.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-06-09 12:40:08 +02:00
Andrew Bartlett
d057116cc2 server_id.idl: Bring server_id.idl in common
Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-06-09 12:40:08 +02:00
Andrew Bartlett
8d803d5a0a s4-cluster Use task_id instead of id2 to clarify server_id structure
This seems a clearer and more acceptable name.

Andrew Bartlett

Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-06-09 12:40:08 +02:00
Matthias Dieter Wallnöfer
7ebafb000a s4:librpc/rpc/dcerpc.c - janitorial: use "void" for functions without arguments
Probably a mistake in commit 907cdb5de7.

Reviewed-by: Tridge
2011-06-09 09:35:08 +02:00
Andrew Bartlett
907cdb5de7 s4-modules Remove lp_ctx from init functions that no longer need it
Now that we don't allow the smb.conf to change the modules dir, many
functions that simply load modules or initialise a subsytem that may
load modules no longer need an lp_ctx.

Andrew Bartlett
2011-06-06 17:37:51 +10:00
Andrew Tridgell
66aec3cf67 s4-ipv6: removed the old unused ipv6 code in dcerpc_sock.c
the code is now generic to both V4 and V6
2011-06-06 12:26:11 +10:00
Andrew Tridgell
5d2dbf93b3 s4-ipv6: allow for IPv6 in dcerpc socket calls 2011-06-06 12:26:11 +10:00
Andrew Bartlett
14f99167f6 build: Remove --disable-s3build so we can rely on these subsystems
This will make it easier to write code that uses the whole codebase.

Andrew Bartlett

Autobuild-User: Andrew Bartlett <abartlet@samba.org>
Autobuild-Date: Mon May  9 12:25:33 CEST 2011 on sn-devel-104
2011-05-09 12:25:33 +02:00
Andrew Bartlett
cdd802af83 s4-messaging Rename messaging -> imessaging
This avoid symbol and structure conflicts between Samba3 and Samba4,
and chooses a less generic name.

Andrew Bartlett
2011-05-03 07:37:07 +02:00
Andrew Bartlett
4c8de5ab13 s4-cluster Rename server_id.node -> vnn to match Samba3 2011-05-03 07:37:07 +02:00
Andrew Bartlett
85eb4377db s4:cluster Rename .id to .pid in server_id
This also changes some DEBUG messages to use cluster_id_string()
rather than .id, to isolate them from this and other changes.

Andrew Bartlett
2011-05-03 07:37:06 +02:00
Stefan Metzmacher
578cbf1139 s4:libcli/smb2: convert smb2_connect_*() to tevent_req
metze
2011-04-28 20:35:49 +02:00
Andrew Bartlett
663dc94e63 auth: Move auth_session_info into IDL
This changes auth_session_info_transport to just be a wrapper, rather
than a copy that has to be kept in sync.

As auth_session_info was already wrapped in python, this required
changes to the existing pyauth wrapper and it's users.

Andrew Bartlett
2011-04-05 23:46:04 +02:00
Günther Deschner
b903c28939 librpc: bring more librpc prototypes in common.
Guenther
2011-03-23 23:59:11 +01:00
Stefan Metzmacher
72c1fe0081 librpc/rpc: move DCERPC_ flags to rpc_common.h
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Sun Mar 13 20:45:53 CET 2011 on sn-devel-104
2011-03-13 20:45:53 +01:00
Stefan Metzmacher
c1a2fd1cd1 s4:librpc/rpc: finaly make struct rpc_request and enum rpc_request_state private
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Sun Mar 13 17:46:02 CET 2011 on sn-devel-104
2011-03-13 17:46:02 +01:00
Stefan Metzmacher
81063f9a26 s4:librpc/rpc: remove unused dcerpc_request()
metze
2011-03-13 17:01:00 +01:00
Stefan Metzmacher
f8030ec080 s4:librpc/rpc: make dcerpc_request_recv() static
metze
2011-03-13 17:00:59 +01:00
Stefan Metzmacher
26351bf480 s4:pyrpc: use dcerpc_binding_handle_raw_call() instead of dcerpc_request()
metze
2011-03-13 16:53:16 +01:00
Stefan Metzmacher
fa0f0c2107 s4:pyrpc: fix memory leaks in error pathes
metze
2011-03-13 16:53:06 +01:00
Stefan Metzmacher
08dca92499 librpc/rpc: move struct dcerpc_binding to rpc_common.h
metze
2011-03-13 16:53:05 +01:00
Stefan Metzmacher
83c55ac67e librpc/rpc: move enum dcerpc_transport_t to rpc_common.h
metze
2011-03-13 16:33:06 +01:00
Stefan Metzmacher
b0d54da746 s4:librpc/rpc: s/dcerpc_security/dcecli_security
We'll use 'dcerpc_security' for the generic dcerpc
client and server code.

metze
2011-03-13 16:33:06 +01:00
Stefan Metzmacher
4d4c6315fa s4:librpc/rpc: remove unused dcerpc_ndr_request* code
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Sun Mar 13 11:19:59 CET 2011 on sn-devel-104
2011-03-13 11:19:59 +01:00
Stefan Metzmacher
b738e092a2 librpc/rpc: move dcerpc_binding_handle stuff to rpc_common.h
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Fri Mar 11 12:28:08 CET 2011 on sn-devel-104
2011-03-11 12:28:08 +01:00
Stefan Metzmacher
c774a50aaf s4:librpc/rpc: s/struct dcerpc_connection/struct dcecli_connection/g
The name 'struct dcerpc_connection' will be used in the new generic
dcerpc code. It will be used for client and server.

metze
2011-03-11 11:02:23 +01:00
Andrew Tridgell
5ec284d152 build: moved librpc/rpc/*.c into a rpccommon library
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>

Autobuild-User: Andrew Tridgell <tridge@samba.org>
Autobuild-Date: Thu Feb 24 02:42:37 CET 2011 on sn-devel-104
2011-02-24 02:42:37 +01:00
Stefan Metzmacher
67004581e6 s4:librpc: let dcerpc-samr library use RPC_NDR_SAMR subsystem
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Tue Feb 22 21:51:43 CET 2011 on sn-devel-104
2011-02-22 21:51:43 +01:00
Stefan Metzmacher
a308cdc371 s4:build: add RPC_NDR_ATSVC subsystem
metze
2011-02-22 21:04:23 +01:00
Andrew Tridgell
1bf4ff2ab2 s4-waf: added --enable-s3build configure option
this enables the build of the s3 binaries in the toplevel build

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-02-22 02:51:10 +01:00
Andrew Tridgell
acdfe48ebe s4-ndr: added NDR_WBINT to ndr_tables
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-02-22 02:51:08 +01:00
Matthieu Patou
e37db96d2a s4: avoid overwritting the dceprc.h file from toplevel librpc
Change back to what was the configuration of header_path before
177ddcb084 so that dcerpc.h is installed
in ${prefix}/include and not in ${prefix}/include/gen_ndr as the
toplevel librpc wants also to put a dcerpc.h file in this directory.

Add some documentation in order to avoid any new regression.

This change should fix problems for openchange team.

Autobuild-User: Matthieu Patou <mat@samba.org>
Autobuild-Date: Mon Feb 21 09:47:05 CET 2011 on sn-devel-104
2011-02-21 09:47:05 +01:00
Andrew Tridgell
bed374215f s4-idl: rename s4 server_id.idl to server_id4.idl
this avoids a conflict with the new s3 server_id.idl

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-02-18 18:41:00 +11:00
Andrew Bartlett
cfeceedfab librpc make ndr-standard a common library 2011-02-18 18:41:00 +11:00
Andrew Bartlett
177ddcb084 librpc push NDR_SECURITY and NDR_DCERPC to the top level wscript files
There isn't any reson to keep these private to source3 and source4 and
more, and doing so creates problems for the top level build.

Andrew Bartlett
2011-02-18 18:41:00 +11:00
Günther Deschner
3722f65359 librpc: make NDR_KRB5PAC a shared library (libndr-krb5pac.so).
Simo, please check.

Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Mon Feb 14 18:54:38 CET 2011 on sn-devel-104
2011-02-14 18:54:38 +01:00
Matthieu Patou
f8a156dbe6 librpc: add bindings for dnsp in python 2011-02-13 01:23:05 +03:00
Günther Deschner
ad0a3185ce librpc: move preg.idl to main directory.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Thu Feb 10 13:56:49 CET 2011 on sn-devel-104
2011-02-10 13:56:49 +01:00
Günther Deschner
4086c1e382 s4-waf: split out wscript_build for ndrdump binary.
Guenther

Autobuild-User: Günther Deschner <gd@samba.org>
Autobuild-Date: Tue Feb  8 14:50:54 CET 2011 on sn-devel-104
2011-02-08 14:50:54 +01:00
Andrew Tridgell
9f9b363447 s4-idl: make the source4 idl build independent of build directory
this allows the source4 idl to be built from any top level directory

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2011-02-07 13:22:00 +11:00
Andrew Bartlett
a3e99356ab s4-waf Don't install any Samba packages into PYTHONDIR
This causes the parts of Samba installed into PYTHONARCHDIR to then be
missed in mixed python/C module namespaces.

Andrew Bartlett
2011-02-02 15:21:13 +11:00
Günther Deschner
dd35fe181c waf: share libndr.so between samba3 and samba4.
Guenther
2011-01-25 11:42:46 +01:00
Matthias Dieter Wallnöfer
0932c91186 s4:librpc/rpc/dcerpc_connect.c - fix uninitialised variable 2011-01-12 19:52:19 +01:00
Matthieu Patou
25ae380fab idl: Add IDL for remote key backup protocol (rkbp)
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-01-12 09:08:06 +01:00
Matthieu Patou
9d9c212858 idl: remove protected storage
Signed-off-by: Stefan Metzmacher <metze@samba.org>
2011-01-12 09:06:04 +01:00
Jelmer Vernooij
5792fa90ac s4-python: Only set BASETYPE flag if subclassing is supported.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sat Jan  1 03:39:58 CET 2011 on sn-devel-104
2011-01-01 03:39:58 +01:00
Jelmer Vernooij
09a2f14c84 pyrpc: Add prototype for init function.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sat Dec 18 03:04:23 CET 2010 on sn-devel-104
2010-12-18 03:04:23 +01:00
Jelmer Vernooij
35fbc7bbda s4-smbtorture: Make test names lowercase and dot-separated.
This is consistent with the test names used by selftest, should
make the names less confusing and easier to integrate with other tools.

Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sat Dec 11 04:16:13 CET 2010 on sn-devel-104
2010-12-11 04:16:13 +01:00
Stefan Metzmacher
5fcbb16760 s4:pyrpc_util: s/typename/type_name to avoid c++ warnings
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Thu Dec  9 17:55:57 CET 2010 on sn-devel-104
2010-12-09 17:55:57 +01:00
Stefan Metzmacher
63574fda0e s4:python: add PyString_FromStringOrNULL() to pyrpc_util
metze
2010-12-08 19:06:52 +01:00
Andrew Tridgell
735c1cd2da s4-pkgconfig: add @LIB_RPATH@ to our link flags
this is only set when rpath is used on install. It ensures that
applications that link against Samba libraries get the rpath right

Autobuild-User: Andrew Tridgell <tridge@samba.org>
Autobuild-Date: Wed Dec  8 12:46:00 CET 2010 on sn-devel-104
2010-12-08 12:46:00 +01:00
Andrew Bartlett
4ea840c3a5 s4-librpc Handle all types of GUID in the GUID() initialiser
By taking a length-limited string, we can parse binary and string GUID
values, which is particularly useful when reading from ldb.

Andrew Bartlett
2010-12-01 00:14:40 +01:00
Matthias Dieter Wallnöfer
258dc02a9d s4:role transfer - use always type "enum drepl_role_master" for role specifications
Autobuild-User: Matthias Dieter Wallnöfer <mdw@samba.org>
Autobuild-Date: Sat Nov 27 16:03:43 CET 2010 on sn-devel-104
2010-11-27 16:03:42 +01:00
Arnaud Faucher
2ac5cedb71 Avoid the use of PyAPI_DATA, which is for internal Python API's.
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>

Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Mon Nov 22 00:52:56 CET 2010 on sn-devel-104
2010-11-22 00:52:56 +01:00
Andrew Tridgell
808edd0293 s4-rpc: make rpc connect less verbose 2010-11-21 23:10:14 +11:00
Ricardo Jorge
bd7647f0f9 pyrpc: Build the samba.dcerpc.srvsvc module.
Signed-off-by: Jelmer Vernooij <jelmer@samba.org>

Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sat Nov 20 19:52:36 CET 2010 on sn-devel-104
2010-11-20 19:52:35 +01:00
Jelmer Vernooij
4217734a51 credentials: Lowercase library name,
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sun Nov  7 01:48:44 UTC 2010 on sn-devel-104
2010-11-07 01:48:44 +00:00
Jelmer Vernooij
3deece5591 s4: Remove the old perl/m4/make/mk-based build system.
The new waf-based build system now has all the same functionality, and
the old build system has been broken for quite some time.

Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sun Oct 31 02:01:44 UTC 2010 on sn-devel-104
2010-10-31 02:01:44 +00:00
Andrew Tridgell
679eba61ea s4-build: removed some unnecessary dependencies
based on running waf --symbol-check
2010-10-30 23:49:01 +11:00
Andrew Tridgell
f5251c064e s4-ndr: make ndr-table a subsystem
its already part of the ndr-samba4 library

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-30 23:49:01 +11:00
Stefan Metzmacher
ba6afbdfb7 s4:librpc: we don't need dcerpc client bindings for dns.idl
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Tue Oct 26 19:35:59 UTC 2010 on sn-devel-104
2010-10-26 19:35:59 +00:00
Jelmer Vernooij
a702c07e02 talloc: change pytalloc-util to be a public library. 2010-10-26 10:17:19 -07:00
Jelmer Vernooij
a74e8be6d1 waf: Stop automaticaly changing dashes to underscores in library names. 2010-10-26 10:17:18 -07:00
Jelmer Vernooij
e4d9e974da waf: Don't auto-lowercase library names. 2010-10-26 10:17:18 -07:00
Jelmer Vernooij
8cf61377aa waf: Remove lib prefix from libraries manually. 2010-10-26 10:17:17 -07:00
Jelmer Vernooij
20b5268556 dcerpc_dns: Change back to subsystem for the moment. 2010-10-26 10:17:17 -07:00
Jelmer Vernooij
d9cbcdd410 s4: Drop duplicate 'lib' prefix for private libraries. 2010-10-26 10:17:16 -07:00
Stefan Metzmacher
005b50ad68 s4:librpc: we don't need dcerpc client bindings for dns.idl
metze

Autobuild-User: Stefan Metzmacher <metze@samba.org>
Autobuild-Date: Sun Oct 24 11:23:50 UTC 2010 on sn-devel-104
2010-10-24 11:23:50 +00:00
Jelmer Vernooij
8c99517a0c waf: Lowercase several library names. 2010-10-24 00:20:04 +00:00
Jelmer Vernooij
833480d3ad s4: Rename LIBSAMBA-* to libsamba-* 2010-10-24 00:20:04 +00:00
Jelmer Vernooij
ca16d805bd s4: Rename LIBSECURITY{_SESSION,} to libsecurity{_session,} 2010-10-24 00:20:04 +00:00
Jelmer Vernooij
bc44fcc6fb s4: Rename NDR_TABLE to ndr_table. 2010-10-23 22:24:06 +00:00
Kai Blin
719a6bbfed ndr dns: Add simple parser 2010-10-23 10:17:05 +00:00
Kai Blin
97868713a0 idl: Add idl describing DNS structures 2010-10-23 10:17:05 +00:00
Andrew Tridgell
4fa0ceb751 waf: RPC_NDR_WINBIND is samba4 specific
this caused problems with the s3 waf build
2010-10-21 20:56:38 +11:00
Andrew Tridgell
97ce2d8965 s4-librpc: fixed depenencies for libcli/security
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-21 19:03:27 +11:00
Andrew Tridgell
11bce8ce03 librpc: added a few more NDR_* targets to NDR_SAMBA
Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-21 19:03:26 +11:00
Andrew Tridgell
b4dd1accc8 s4-waf: don't depend directly on python modules
build rules should not list dependencies on python modules. Instead,
if code needs the module it should use the python API import calls to
access the module.

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-21 19:03:26 +11:00
Andrew Tridgell
cffbccb5cb s4-waf: make NDR_STANDARD a grouping library and add NDR_SAMBA4
this collects a number of subsystems into logical groups

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-21 19:03:25 +11:00
Andrew Tridgell
2dcb596e83 s4-waf: removed dependencies on missing subsystems
these were left over from the old config.mk system
2010-10-21 19:03:24 +11:00
Andrew Tridgell
0ad5937b4e s4-ndr: make NDR_TABLE a private library
this greatly reduces the size of ndrdump, and saves us a fair bit of
duplication

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-21 19:03:24 +11:00
Jelmer Vernooij
fb8bbd2506 dcerpc_samr: Fix -l arguments for dcerpc_samr and dcerpc_atsvc.
Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sun Oct 17 19:15:43 UTC 2010 on sn-devel-104
2010-10-17 19:15:42 +00:00
Jelmer Vernooij
5324b943e7 wafsamba: Fix handling of pyembed/pyext. 2010-10-10 23:54:04 +00:00
Jelmer Vernooij
d0c7ae5cd5 librpc: Remove unnecessary dependency on libsamba-hostconfig. 2010-10-11 01:06:36 +02:00
Jelmer Vernooij
c15e919a09 wafsamba: Clarify needs_python argument name, use pyembed/pyext where
applicable.

Allow using both pyembed and pyext, to prevent unresolved symbols.

Autobuild-User: Jelmer Vernooij <jelmer@samba.org>
Autobuild-Date: Sun Oct 10 03:54:01 UTC 2010 on sn-devel-104
2010-10-10 03:54:01 +00:00
Andrew Tridgell
9bae4cd3d9 s4-rpc: added target_principal binding handle option
this allows you to specify a target SPN for a connection

Pair-Programmed-With: Andrew Bartlett <abartlet@samba.org>
2010-10-01 22:31:57 -07:00
Andrew Tridgell
c4d2b6fbc2 s4-netlogon: added RODC DNS update call fwded to dnsupdate task
when we get a netlogon RODC DNS update, we send it to the dnsupdate
task
2010-09-27 22:55:05 -07:00
Stefan Metzmacher
d9d4ded71a s4:irpc: optionaly pass the security_token via IRPC requests.
metze
2010-09-27 09:59:21 -07:00
Günther Deschner
f2310cacde waf: add more NDR subsystems for shared IDL files.
Guenther
2010-09-27 07:12:09 +02:00
Günther Deschner
bd5f932eef s4-waf: add NDR_EVENTLOG.
Guenther
2010-09-24 21:10:47 -07:00
Günther Deschner
204ba65772 s4-waf: rename subsystem NDR_LSAPRC to NDR_LSA.
Guenther
2010-09-24 21:10:47 -07:00
Günther Deschner
0261b96bd8 s4-waf: move the RPC_NDR subsystems to main librpc wscript_build.
Guenther
2010-09-23 14:48:34 -07:00