summaryrefslogtreecommitdiff
path: root/source4/rpc_server
AgeCommit message (Collapse)AuthorFilesLines
2007-10-10r3320: fixed bugs in the rpc_server code in handling partial packet receives ↵Andrew Tridgell2-5/+3
and sends it now passes the non-blocking test suite (This used to be commit 6cdf485fb263c69d62ea2e98236d92ffbf6b7a3e)
2007-10-10r3304: changed the API to lib/socket/ a little.Andrew Tridgell1-10/+18
The main change is to make socket_recv() take a pre-allocated buffer, rather than allocating one itself. This allows non-blocking users of this API to avoid a memcpy(). As a result our messaging code is now about 10% faster, and the ncacn_ip_tcp and ncalrpc code is also faster. The second change was to remove the unused mem_ctx argument from socket_send(). Having it there implied that memory could be allocated, which meant the caller had to worry about freeing that memory (if for example it is sending in a tight loop using the same memory context). Removing that unused argument keeps life simpler for users. (This used to be commit a16e4756cd68ca8aab4ffc59d4d9db0b6e44dbd1)
2007-10-10r3278: - rewrote the client side rpc connection code to use lib/socket/Andrew Tridgell1-4/+3
rather than doing everything itself. This greatly simplifies the code, although I really don't like the socket_recv() interface (it always allocates memory for you, which means an extra memcpy in this code) - fixed several bugs in the socket_ipv4.c code, in particular client side code used a non-blocking connect but didn't handle EINPROGRESS, so it had no chance of working. Also fixed the error codes, using map_nt_error_from_unix() - cleaned up and expanded map_nt_error_from_unix() - changed interpret_addr2() to not take a mem_ctx. It makes absolutely no sense to allocate a fixed size 4 byte structure like this. Dozens of places in the code were also using interpret_addr2() incorrectly (precisely because the allocation made no sense) (This used to be commit 7f2c771b0e0e98c5c9e5cf662592d64d34ff1205)
2007-10-10r3218: Fix the buildVolker Lendecke1-1/+1
(This used to be commit 478ba629158e8ce5e15467105b1013ba60f04ec1)
2007-10-10r3209: - Create directory for ncalrpc with correct modeJelmer Vernooij1-2/+4
- Support binding strings like : ncacn_np:[sign] ncacn_np:myhost[seal,sign,endpoint] again (This used to be commit b53f4cd1697345065c7d979ba63237bf828dc07f)
2007-10-10r3208: fixed permissions of ncalrpc directory creationAndrew Tridgell1-1/+1
(This used to be commit adbfd206f4e077ed915a014e89a970470b43e125)
2007-10-10r3205: Create ncalrpc directory if it didn't exist yetJelmer Vernooij1-0/+5
(This used to be commit 1161c33794cdb16a3d09a66258f46e0020c4aeef)
2007-10-10r3167: Add a member 'endpoint' to the dcerpc_binding struct to use instead ofJelmer Vernooij2-28/+13
options[0]. (This used to be commit 18582083af800abd3d8de40eb73255c8ae6598dd)
2007-10-10r3165: Support local connections in Gtk+ toolsJelmer Vernooij1-1/+1
(This used to be commit 3de0cf22ddd6b7fb4a2214f3f99d37174c54840f)
2007-10-10r3163: Add server side support for ncalrpc: and ncacn_unix_stream:Jelmer Vernooij4-236/+336
Examples of binding strings are : ncalrpc:[EPMAPPER] ncacn_unix_stream:[/tmp/epmapper] N.B. The unix socket support in lib/socket/ appears to close and remove the socket it is listening on after the first client disconnects so until that has been fixed, it is only possible to do one ncalrpc: or ncacn_unix_stream: request per instance of smbd :-) Support for looking up NCALRPC names via the endpoint mapper will be added later. (This used to be commit 426f3e63cae3d306dcdc13ee4b655eed30057ff8)
2007-10-10r3158: Use the new tower build functions to generate protocol towers, making itJelmer Vernooij1-89/+38
easier to deal with more different transports. (This used to be commit ee9bcfddf01ed65082bdf0bb2b43e4f3a66c3f5b)
2007-10-10r3136: - Allow specifying socket type when adding smbd serviceJelmer Vernooij1-1/+1
- Make sure a epm_tower struct is completely initialized - Some more minor fixes (This used to be commit d560dcbdb85cb2c6915bdb9e2f82f1872b0f5a52)
2007-10-10r3118: Eliminate struct dcesrv_ep_description and replace it withJelmer Vernooij4-77/+44
struct dcerpc_binding. (This used to be commit 2046e14cf8d010d4e715124859df2c1c3c782266)
2007-10-10r3114: - More work on merging the various structs that describe endpointsJelmer Vernooij4-21/+28
- Add protocol sequence to dcerpc transports (will be used later on) - Add more transports to the list (This used to be commit ab110192e6e2c1e5a3b2befe7b61158744f15d18)
2007-10-10r3112: Fix two more instances of epm_towers (sorry, metze!)Jelmer Vernooij1-1/+1
(This used to be commit 7baf493966aa3fb61623d6030b5ccc26a5fcb186)
2007-10-10r3111: Add a few more protocol identifiers, rhs for ncalrpcJelmer Vernooij1-4/+4
(This used to be commit 53567a83cbca9df60bef76a15df24d2cd89a16b0)
2007-10-10r3080: Make the Samba4 SAMR server pass the new, nasty torture test (now thatAndrew Bartlett1-0/+14
SAMR_FIELD_PASSWORD has been split up). Andrew Bartlett (This used to be commit 5f2295a5fb422ad028e67b240e55206acefb48bd)
2007-10-10r3077: Add initial handling of Account Flags in SAMR user info level 21 and 25.Andrew Bartlett1-0/+9
Andrew Bartlett (This used to be commit 51774a9bcad97686e5259ac8d753b3df58072622)
2007-10-10r3076: Fix memory leak.Andrew Bartlett1-1/+3
Andrew Bartlett (This used to be commit 4091fee8e807e5cd7089dc6753324766d10678c2)
2007-10-10r3043: Use binding strings for specifying endpoints. The property forJelmer Vernooij2-11/+28
specifying a endpoint is now also 'endpoint' instead of 'endpoints'. The default endpoint (if none is specified) is still "ncacn_np:[\\pipe\\ifacename]", where ifacename is the name of the interface. Examples: [ uuid(60a15ec5-4de8-11d7-a637-005056a20182), endpoint("ncacn_np:[\\pipe\\rpcecho]", "ncacn_ip_tcp:") ] interface rpcecho { void dummy(); } dcerpc_binding is now converted to ep_description in the server, but I hope to completely eliminate ep_description later on. The eventual goal of all these changes is to make it easier to add transports as I'm going to add support for ncalrpc (local RPC over named pipes) and ncacn_unix_stream (Unix sockets). (This used to be commit f3da7c8b443a29b0c656c687a277384ae1353792)
2007-10-10r3005: added talloc wrappers around tdb_open() and ldb_connect(), so that theAndrew Tridgell2-101/+43
caller doesn't have to worry about the constraint of only opening a database a single time in a process. These wrappers will ensure that only a single open is done, and will auto-close when the last instance is gone. When you are finished with a database pointer, use talloc_free() to close it. note that this code does not take account of the threads process model, and does not yet take account of symlinks or hard links to tdb files. (This used to be commit 04e1171996612ddb15f84134cadded68f0d173b2)
2007-10-10r2992: drsuapi uses WERROR not NTSTATUSStefan Metzmacher2-50/+48
metze (This used to be commit 757f67c08b0b1309d8a0b900539111c7bc430b0e)
2007-10-10r2991: add drsuapi_DsGetDomainControllerInfo() idl and torture testStefan Metzmacher1-3/+3
metze (This used to be commit 98ca7640c59aa8694abde03f5661b8908cf088bb)
2007-10-10r2974: fix the buildStefan Metzmacher1-1/+1
metze (This used to be commit 1bb71e7a8699bfd32d171a48c4c3b5f35faf3e51)
2007-10-10r2970: - give somefields names and typdef enums for the possible valuesStefan Metzmacher3-47/+133
- do more crackname tests in the torture test - move server code for cracknames to a different file metze (This used to be commit 18050ea6037b3c0c7cfe975eb9c872368b9e3328)
2007-10-10r2954: add server cracknames code:Stefan Metzmacher1-1/+41
- we currently only do it for our REALM metze (This used to be commit e2df8c4285d3430085594a3a3b5534c514acd1f9)
2007-10-10r2953: add NTSTATUS_TALLOC_CHECK(x)Stefan Metzmacher1-0/+4
metze (This used to be commit a2cc9517208adedbcbed4b01d18a1478f75d70df)
2007-10-10r2952: add idl and torture test for DsCrackNamesStefan Metzmacher1-3/+3
(I need to find out what the fields mean but it works) metze (This used to be commit eff51fc623f2e7b57e7e53eb81760684815db2f4)
2007-10-10r2938: Use IDL to dissect the RHS of floors in protocol towersJelmer Vernooij1-10/+7
(This used to be commit 273d0049b5339e3288b264e5a4393bfab1d4e239)
2007-10-10r2921: Add a few more protocols and fix the numbers associated with some ofJelmer Vernooij1-10/+10
the current ones. It took me three hours to realise that the DCOM standard contains false protocol numbers (apparently someone converted the protocol numbers to hex twice, i.e. 13 -> 0c and 14 to 0d). There are no longer duplicates in the list with protocol numbers now. (This used to be commit f355cd426462a72575ef3c3b769f676334976986)
2007-10-10r2889: add DRSUAPI serverStefan Metzmacher4-0/+370
- with DsBind and DsUnbind implmented :-) the RPC-DRSUAPI test works metze (This used to be commit 536af87ef12024615728ce0060b557f6f504e33f)
2007-10-10r2887: fix commentStefan Metzmacher1-1/+1
metze (This used to be commit 5143a9bd8aa84b80763c304638a27395b53b54cc)
2007-10-10r2792: got rid of talloc_ldb_alloc() and instead created talloc_realloc_fn(),Andrew Tridgell3-12/+12
so talloc now doesn't contain any ldb specific functions. allow NULL to be passed to a couple more talloc() functions (This used to be commit 1246f80d806fb5f63cfbf3879de6d546384552a8)
2007-10-10r2734: the samdb_destructor can be staticAndrew Tridgell1-1/+1
(This used to be commit feb63e74f923f2a50c6836e18a6c2bda39644e71)
2007-10-10r2710: continue with the new style of providing a parent context wheneverAndrew Tridgell1-21/+25
possible to a structure creation routine. This makes for much easier global cleanup. (This used to be commit e14ee428ec357fab76a960387a9820a673786e27)
2007-10-10r2696: DCOM updates:Jelmer Vernooij5-11/+116
- Start working on OXIDResolver interface - Add torture test for SimplePing() (This used to be commit b54d14a01a71082251ff926ab57974c6eb3c0a41)
2007-10-10r2680: switched the libcli/raw/ code over to use talloc_reference(), which ↵Andrew Tridgell1-2/+1
simplifies things quite a bit (This used to be commit c82a9cf750829c4f6982ca3133295c8599023c4e)
2007-10-10r2675: added a convenience functionAndrew Tridgell1-47/+11
void *talloc_reference(const void *context, const void *ptr); this function makes a secondary reference to ptr, and hangs it off the given context. This greatly simplifies some of the current reference counting code in the samr server and I suspect it will be widely used in other places too. the way you use it is like this: domain_state->connect_state = talloc_reference(domain_state, connect_state); that makes the element connect_state of domain_state a secondary reference to connect_state. The connect_state structure will then only be freed when both domain_state and the original connect_state go away, allowing you to free them independently and in any order. you could do this alrady using a talloc destructor, and that is what the samr server did previously, but that meant this construct was being reinvented in several places. So this convenience function sets up the destructor for you, giving a much more convenient and less error prone API. (This used to be commit dc5315086156644fad093cbe6b02d999adba8540)
2007-10-10r2673: in the rpc server, free up the old call when we decide to extend anAndrew Tridgell1-1/+3
existing call rather than creating a new one. This prevents call structures hanging around on the rpc connection context until it is closed (This used to be commit c51ca7c0e73b97435c245cd440a4fb979cf6a4f3)
2007-10-10r2671: we're getting too many errors caused by the talloc_realloc() API notAndrew Tridgell2-5/+7
taking a context (so when you pass a NULL pointer you end up with memory in a top level context). Fixed it by changing the API to take a context. The context is only used if the pointer you are reallocing is NULL. (This used to be commit 8dc23821c9f54b2f13049b5e608a0cafb81aa540)
2007-10-10r2670: use a destructor to auto-close the samr ldb when the last userAndrew Tridgell1-15/+18
disconnects. Previously the ldb was always kept open. (This used to be commit d78eea9eb8540f137d30aef5fbb397295312eb1b)
2007-10-10r2669: convert make_user_info() and associated functions from malloc to tallocAndrew Tridgell1-2/+4
(This used to be commit 278cef77f083c002d17ecbbe18c20825a380eda3)
2007-10-10r2663: fix an epmapper server leak - another talloc_realloc(NULL, ) leakAndrew Tridgell1-3/+3
(This used to be commit 2662be3a2be04aa7f4dcfde3453389595bf43496)
2007-10-10r2660: - converted the libcli/raw/ library to use talloc_increase_ref_count()Andrew Tridgell1-4/+0
rather than manual reference counts - properly support SMBexit in the cifs and posix backends - added a logoff method to all backends With these changes the RAW-CONTEXT test now passes against the posix backend (This used to be commit c315d6ac1cc40546fde1474702a6d66d07ee13c8)
2007-10-10r2648: - use a destructor on struct server_connection to simplify theAndrew Tridgell1-2/+3
connection termination cleanup, and to ensure that the event contexts are properly removed for every process model - gave auth_context the new talloc treatment, which removes another source of memory leaks. (This used to be commit 230e1cd777b0fba82dffcbd656cfa23c155d0560)
2007-10-10r2646: - use a talloc destructor to ensure that sockets from the new socketAndrew Tridgell2-4/+2
library are closed on abnormal termination - convert the service.h structures to the new talloc methods (This used to be commit 2dc334a3284858eb1c7190f9687c9b6c879ecc9d)
2007-10-10r2635: mem_ctx cleanups on the lsa and netlogon pipes in the rpc serverAndrew Tridgell3-50/+19
(This used to be commit 1ee5ed4197f49f12372835f66160801f19ee35a6)
2007-10-10r2629: convert gensec to the new talloc modelAndrew Tridgell1-1/+1
by making our gensec structures a talloc child of the open connection we can be sure that it will be destroyed when the connection is dropped. (This used to be commit f12ee2f241aab1549bc1d9ca4c35a35a1ca0d09d)
2007-10-10r2628: got rid of some warnings and converted a few more places to use ↵Andrew Tridgell1-2/+2
hierarchical memory allocation (This used to be commit 26da45a8019a2d6c9ff2ac2a6739c7d0b42b00de)
2007-10-10r2627: use the new talloc capabilities in a bunch more places in the rpcAndrew Tridgell8-90/+61
server code. This fixes a number of memory leaks I found when testing with valgrind and smbtorture, as the cascading effect of a talloc_free() ensures that anything derived from the top level object is destroyed on disconnect. (This used to be commit 76d0b8206ce64d6ff4a192979c43dddbec726d6e)