Volker Lendecke
d3f9b0fab6
Next step disentangling async_req from NTSTATUS
...
Now I need to document this :-)
2009-02-02 20:15:03 +01:00
Volker Lendecke
c14b7e648b
Split up async_req into a generic and a NTSTATUS specific part
2009-02-01 19:05:39 +01:00
Volker Lendecke
7967d8c779
Move rpc_pipe_open_internal to srv_pipe_hnd.c
...
This is a smbd-only function
2009-02-01 14:34:23 +01:00
Volker Lendecke
57de60a83f
cli_get_pipe_name_from_interface does not really need a talloc_ctx
2009-02-01 14:34:22 +01:00
Volker Lendecke
f6d08849e1
Fix memleaks
2009-01-30 21:29:35 +01:00
Volker Lendecke
aef749b53f
pass NULL to prs_give_memory, that is a pointer
2009-01-30 21:29:35 +01:00
Volker Lendecke
22e3004829
Add the "SMBD" rpc transport
...
The idea of this is that all client utils like smbpasswd and also for example
"net join" do not access our internal databases like passdb and secrets.tdb
directly anymore but pass everything throught the well-established RPC
interfaces.
The way you use this is the following: With rpc_cli_smbd_conn_init() or its
async variant you initialize a "struct rpc_cli_smbd_conn". This structure is
the link to a freshly forked smbd, ready to be used for RPC services. You
should only ever have one such structure in your program. More don't hurt, but
are plainly unnecessary.
If you want to use the SAMR pipe to change a passwort, you connect to that pipe
with rpc_pipe_open_local. Do you normal rpccli_samr calls on that and your
locally forked smbd will connect to passdb for you.
GD, this might make the distinction between the _l and _r calls in libnetapi
mostly unnecessary. At least it is intended to do so... :-)
2009-01-30 12:48:00 +01:00
Volker Lendecke
b873ede89d
Make rpc_transport_np_init async
2009-01-30 12:47:59 +01:00
Volker Lendecke
b7094c0b80
Abstract away the transport in cli_pipe.c
...
Sorry for the monster checkin, I could not really find a way to do this in
steps.
2009-01-22 22:59:54 +01:00
Volker Lendecke
b7bd71b349
Add the socket rpc client transport
2009-01-22 22:59:54 +01:00
Volker Lendecke
c5b4371054
Add the named pipe rpc client transport
2009-01-22 22:59:53 +01:00
Volker Lendecke
031f246941
Fix a segfault: rpccli_* expect the reply_pdu to always be initialized
2009-01-22 17:54:16 +01:00
Volker Lendecke
3662c2b0f6
cli_get_pipe_name_from_iface does not need the cli_state
...
I leave the TALLOC_CTX in, we might have to allocate it in the future
2009-01-22 11:38:00 +01:00
todd stecher
989ad44d32
Memory leaks and other fixes found by Coverity
2009-01-21 17:13:03 -08:00
Jelmer Vernooij
11a25f9050
Allow calling DCE/RPC server implementations directly using
...
rpc_pipe_client.
2009-01-21 14:05:51 +01:00
Volker Lendecke
0dbd396862
Add a macro async_req_setup()
...
This streamlines setting up a multi-step async request a bit
2009-01-18 16:45:07 +01:00
Volker Lendecke
c45b6ec29a
Add code to torture the fragmentation code a bit
2009-01-18 15:40:45 +01:00
Volker Lendecke
a158ebbe49
Remove unused functions
2009-01-18 15:40:45 +01:00
Volker Lendecke
28c35b4c04
Make rpc_pipe_bind async
2009-01-18 15:40:45 +01:00
Volker Lendecke
ecb5184ce5
Fix an uninitialized variable
2009-01-18 15:40:45 +01:00
Volker Lendecke
3f9f188877
Remove sync rpc_api_pipe_req
2009-01-18 15:40:45 +01:00
Volker Lendecke
396ed3b363
Add async rpc_api_pipe_req
2009-01-18 15:40:45 +01:00
Volker Lendecke
c655f19e1f
Add rpc_write_send/recv
2009-01-18 15:40:44 +01:00
Volker Lendecke
f96335afc0
Remove unused sync functions
2009-01-18 15:40:44 +01:00
Volker Lendecke
f6740aa7ad
Make rpc_api_pipe async
2009-01-18 15:40:44 +01:00
Volker Lendecke
761d164420
Rename the async version of get_complete_pdu to get_complete_frag
2009-01-18 15:40:44 +01:00
Volker Lendecke
5e6f3eaae9
Move initialization of the reply prs_struct to rpc_api_pipe
2009-01-18 15:40:44 +01:00
Volker Lendecke
5987c82697
Always check the max send sizein rpc_api_pipe, not just with DEVELOPER
2009-01-18 15:40:44 +01:00
Volker Lendecke
6d47418bc1
Make cli_api_pipe async
...
Also move the transport switch to this routine
2009-01-18 15:40:43 +01:00
Volker Lendecke
173d6c84a6
Remove sync rpc_read wrapper
2009-01-18 15:40:43 +01:00
Volker Lendecke
5d71fe8043
Make cli_pipe_get_current_pdu async, rename it to get_current_pdu
2009-01-18 15:40:43 +01:00
Volker Lendecke
30413f12b9
Make rpc_read async
2009-01-18 15:40:43 +01:00
Volker Lendecke
9b3c38f4af
Slightly simplify the paths after rpc_api_pipe()
2009-01-17 11:27:32 +01:00
Volker Lendecke
8c983af56d
Make rpc_read look like a real read call
...
It doesn't really need to know about prs_structs
2009-01-14 17:08:40 +01:00
Volker Lendecke
e1aeb486e8
Make rpc_read() match the control flow normally used in Samba
...
Replace do { .. } while () with a while () { .. }
2009-01-14 17:08:40 +01:00
Volker Lendecke
11e3388083
Simplify rpc_read a bit
...
rpc_read always reads the whole bytes it was asked to read. So it is not really
necessary for it to update the current_pdu_offset, for clarity this can better
be done in the caller.
2009-01-14 17:08:39 +01:00
Volker Lendecke
15dd11b31e
Remove an unnecessary size check
...
rpc_read is only ever called with at most fraglen-RPC_HEADER_SIZE length
2009-01-14 17:08:39 +01:00
Volker Lendecke
274f575b24
Check the fragment size the server has sent us
2009-01-14 17:08:39 +01:00
Volker Lendecke
583d7913c8
Slightly simplify rpc_read: It should not do the resize
2009-01-14 17:08:39 +01:00
Volker Lendecke
87f9f0b01a
Always read with offset 0 from a named pipe
2009-01-14 17:08:39 +01:00
Volker Lendecke
ce5eded7e0
Move cli_api_pipe() to its only user cli_pipe.c
2009-01-11 22:53:24 +01:00
Günther Deschner
22a96cbe31
s3-svcctl: remove last traces of hand-marshalled svcctl code.
...
Guenther
2009-01-09 17:08:19 +01:00
Günther Deschner
03611c6c9d
s3-svcctl: remove old marshalling of svcctl_EnumServicesStatusW.
...
Guenther
2009-01-09 17:08:18 +01:00
Günther Deschner
f93b0fcd95
s3-lsa: remove all init_lsa* functions.
...
Guenther
2009-01-06 16:02:13 +01:00
Günther Deschner
e2fa47a04c
s3-lsa: avoid all init_lsa* functions.
...
Guenther
2009-01-06 16:02:13 +01:00
Günther Deschner
b0f7137883
s3-srvsvc: remove all init_srvsvc* functions.
...
Guenther
2009-01-06 16:02:12 +01:00
Günther Deschner
be8c532352
s3-samr: remove all init_samr_alias* functions.
...
Guenther
2009-01-06 16:02:12 +01:00
Günther Deschner
0b26f84542
s3-samr: remove all init_samr_group* functions.
...
Guenther
2009-01-06 16:02:11 +01:00
Günther Deschner
15ec090299
s3-samr: remove all init_samr_dom* functions.
...
Guenther
2009-01-06 16:02:11 +01:00
Günther Deschner
52b250fe83
s3-samr: remove init_samr_user* functions.
...
Guenther
2009-01-06 16:02:10 +01:00