1
0
mirror of https://github.com/samba-team/samba.git synced 2024-12-23 17:34:34 +03:00
Commit Graph

299 Commits

Author SHA1 Message Date
Volker Lendecke
fa62836839 Convert rpc_cli_transport->trans to tevent_req 2009-03-24 13:23:41 +01:00
Volker Lendecke
8e0d9d002a Convert rpc_cli_transport->write to tevent_req 2009-03-24 13:23:41 +01:00
Volker Lendecke
22badee4bf Convert rpc_cli_transport->read to tevent_req 2009-03-24 13:23:40 +01:00
Volker Lendecke
1724f2ff31 Convert rpc_api_pipe_req to tevent_req 2009-03-24 13:23:40 +01:00
Volker Lendecke
f88990ec7e Convert rpc_api_pipe to tevent_req 2009-03-24 13:23:40 +01:00
Volker Lendecke
545ed5b52e Convert cli_api_pipe to tevent_req 2009-03-24 13:23:40 +01:00
Volker Lendecke
7a429fb369 Convert get_complete_frag to tevent_req 2009-03-24 13:23:40 +01:00
Volker Lendecke
7573bb758e Convert rpc_write to tevent_req 2009-03-24 13:23:40 +01:00
Volker Lendecke
1dd0883458 Convert rpc_read to tevent_req 2009-03-24 13:23:40 +01:00
Günther Deschner
9fdeb7f7b3 s3-spoolss: remove custom syntax_spoolss and use the syntax defined in IDL.
Guenther
2009-03-18 14:18:42 +01:00
Jeremy Allison
f48a345e4a Remove pwd_cache.c, it was doing nothing. Make user_name, domain, and
password talloc'ed strings within the cli_struct.
Jeremy.
2009-03-13 17:49:24 -07:00
Volker Lendecke
0844cca1d5 Replace get_myname() with the talloc version from v3-3-test 2009-02-13 12:15:03 +01:00
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
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
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
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
Volker Lendecke
19b783cce9 Async wrapper for open_socket_out_send/recv 2009-01-04 16:42:40 +01:00