summaryrefslogtreecommitdiff
path: root/source3/rpc_server/rpc_server.c
AgeCommit message (Collapse)AuthorFilesLines
2012-03-24libreplace: Add getpeereid implementation.Jelmer Vernooij1-1/+2
2011-10-24idl: Improve MS-PAC IDLSimo Sorce1-1/+1
Change some misleading variable names to reflect the actual function. Add missing field name/types previously marked as unkown. Signed-off-by: Günther Deschner <gd@samba.org> Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Mon Oct 24 19:19:28 CEST 2011 on sn-devel-104
2011-09-15rpc_server: Improve debug message for sys_getpeereid().Andreas Schneider1-1/+2
Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Thu Sep 15 19:23:43 CEST 2011 on sn-devel-104
2011-08-29s3-lib: If we create a pipe socket, don't start to listen.Andreas Schneider1-0/+16
The create_pipe_sock() function should only create the socket as the name states and not start to listen on it too. We should start to listen on in the individual places as we need different backlog values. Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Mon Aug 29 13:21:43 CEST 2011 on sn-devel-104
2011-08-21s3-rpc_server: Add create_dcerpc_ncalrpc_socket().Andreas Schneider1-12/+28
Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Simo Sorce <idra@samba.org>
2011-08-21s3-rpc_server: Move config helpers in one place.Simo Sorce1-44/+1
Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Simo Sorce <idra@samba.org>
2011-08-21s3-rpc_server: Add helper to define/retrieve daemons configurationSimo Sorce1-0/+44
Wtith this set of helper functions we make it easy to configure if we want to use an embedded rpc server, or if we want to fork one. Or even just disable it and let a third party server be used when the service is configured as "external". Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Simo Sorce <idra@samba.org>
2011-08-21s3-rpc_server: Make dcerpc_ncacn_accept() public.Andreas Schneider1-17/+8
Signed-off-by: Andreas Schneider <asn@samba.org> Signed-off-by: Simo Sorce <idra@samba.org>
2011-08-10s3-rpc_server: add termination functionSimo Sorce1-2/+19
This way we can act when a client disconnects. Signed-off-by: Andreas Schneider <asn@samba.org>
2011-08-10s3-rpc: Expose some internal functionsSimo Sorce1-33/+40
This will allow to hook the prefork socket handlers to the rpc service. Signed-off-by: Andreas Schneider <asn@samba.org>
2011-08-09s3-rpc_server: Fix sending of packets over named pipe proxy.Andreas Schneider1-22/+27
We need for named pipes we need to send each fragment on its own to be a message. Signed-off-by: Simo Sorce <idra@samba.org> Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Tue Aug 9 11:55:18 CEST 2011 on sn-devel-104
2011-08-09s3-rpc_server: Free the children of p->mem_ctx.Andreas Schneider1-1/+5
Free the children of p->mem_ctx after processing a complete incoming and outgoing request. Signed-off-by: Simo Sorce <idra@samba.org>
2011-08-03s3-auth set session_info->sanitized_username in create_local_token()Andrew Bartlett1-1/+2
Rather than passing this value around the callers, and eventually setting it in register_existing_vuid(), we simply pass it to create_local_token(). This also removes the need for auth_ntlmssp_get_username(). Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-08-01s3-rpc_server: Added common function to create tcpip socket.Andreas Schneider1-23/+36
2011-07-28s3-rpc_server: Remove dead codeSimo Sorce1-16/+0
srv_str and cli_str are not used anymore.
2011-07-22s3-rpc_server: Do not set msg_ctx twiceSimo Sorce1-1/+0
msg_ctx was already passed to make_base_pipes_struct, no need to set it again. Autobuild-User: Simo Sorce <idra@samba.org> Autobuild-Date: Fri Jul 22 00:47:28 CEST 2011 on sn-devel-104
2011-07-21s3-rpc_server: Pass msg_ctx to make_base_pipes_struct().Andreas Schneider1-1/+1
Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Thu Jul 21 21:08:32 CEST 2011 on sn-devel-104
2011-07-21s3-rpc_server: Create common function to allocate pipes_structSimo Sorce1-37/+8
Avoid code duplication and fix bug where a new pipe was not added to InternalPipes upon creation in make_server_pipes_struct() Signed-off-by: Andreas Schneider <asn@samba.org> Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Thu Jul 21 19:50:02 CEST 2011 on sn-devel-104
2011-07-21s3-rpc_server: Remove unused endpoint information.Andreas Schneider1-18/+1
2011-07-21s3-rpc_server: Duplicate the pipe name.Andreas Schneider1-1/+8
2011-07-21s3-rpc_server: Free the np dir.Andreas Schneider1-0/+1
2011-07-21s3-rpc_server: Fix messaging context in the pipes struct.Andreas Schneider1-1/+4
2011-07-21s3-rpc_server: Add my copyright.Andreas Schneider1-0/+1
2011-07-20s3-rpc_server remove per-element copies of auth_session_infoAndrew Bartlett1-26/+2
This is not required any more now that they are the same structure, and shows the value in having a common structure across the codebase. In particular, now any additional state that needs to be added to the auth_session_info will be transparently available across the named pipe proxy, without a need to modify the mapping layer. Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-20s3-auth Use the common auth_session_infoAndrew Bartlett1-2/+2
This patch finally has the same structure being used to describe the authorization data of a user across the whole codebase. This will allow of our session handling to be accomplished with common code. Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-20s3-auth use auth_user_info not netr_SamInfo3 in auth3_session_infoAndrew Bartlett1-43/+28
This makes auth3_session_info identical to auth_session_info The logic to convert the info3 to a struct auth_user_info is essentially moved up the stack from the named pipe proxy in source3/rpc_server to create_local_token(). Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-20s3-rpc_server read and write the unix_token and unix_info across named_pipe_authAndrew Bartlett1-27/+40
This ensures that the exact same token is used on both sides of the pipe, when a full token is passed (ie, source3 to source3, but not yet source4 to to source3 as the unix info isn't calculated there yet). If we do not have unix_token, we fall back to the old behaviour and go via create_local_token(). (However, in this case the security_token is now overwritten, as it is better to have it match the rest of the session_info create_local_token() builds). Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-20s3-auth Use struct auth3_session_info outside the auth subsystemAndrew Bartlett1-2/+2
This seperation between the structure used inside the auth modules and in the wider codebase allows for a gradual migration from struct auth_serversupplied_info -> struct auth_session_info (from auth.idl) The idea here is that we keep a clear seperation between the structure before and after the local groups, local user lookup and the session key modifications have been processed, as the lack of this seperation has caused issues in the past. Andrew Bartlett Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-20Add my copyrightAndrew Bartlett1-0/+1
Signed-off-by: Andrew Tridgell <tridge@samba.org>
2011-07-18s3-rpc_server: Fixed segfaults in rpc daemons.Andreas Schneider1-1/+5
Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Mon Jul 18 14:01:02 CEST 2011 on sn-devel-104
2011-07-14s3-rpc_server: Pass event and messaging context to accept function.Andreas Schneider1-5/+14
Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Thu Jul 14 17:22:16 CEST 2011 on sn-devel-104
2011-07-04s3-rpc_server: Remove client_id and server_id from pipes struct.Andreas Schneider1-43/+0
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-07-04s3-rpc_server: Migrate rpc function to tsocket_address.Andreas Schneider1-1/+0
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-07-04s3-rpc_server: Add local and remote address to pipes struct.Andreas Schneider1-30/+43
Signed-off-by: Andrew Bartlett <abartlet@samba.org>
2011-06-01s3-rpc_server: Remove syntax from pipes_struct.Andreas Schneider1-1/+0
2011-06-01s3-rpc_server: Remove guessing of the syntax id.Andreas Schneider1-36/+4
This is only a wild guess. We don't know to which rpc service the client wants to talk until we read the the rpc bind packet.
2011-05-17s3:rpc_server: create lp_ncalrpc_dir() with 0755 before lp_ncalrpc_dir()/np ↵Stefan Metzmacher1-0/+11
with 0700 metze Autobuild-User: Stefan Metzmacher <metze@samba.org> Autobuild-Date: Tue May 17 13:01:14 CEST 2011 on sn-devel-104
2011-05-17Revert "s3-rpc_server: Force ncalrpc dir to be mode 755."Stefan Metzmacher1-1/+13
This reverts commit a032c9c8fe8aff455407485169b9445860f89606.
2011-05-16s3-rpc_server: Force ncalrpc dir to be mode 755.Andreas Schneider1-13/+1
This completes aae9353ecf56323b63da66aa84d8a0a4f219d94d. directory_create_or_exist() is not needed cause create_pipe_sock() takes care of setting up the directory correctly. Andrew please check! Autobuild-User: Andreas Schneider <asn@cryptomilk.org> Autobuild-Date: Mon May 16 17:54:20 CEST 2011 on sn-devel-104
2011-05-08ncalrpc: Force ncalrpc dir to be mode 755 in all usersAndrew Bartlett1-2/+2
This allows this directory to be shared between Samba3 and Samba4 in a Franky-style setup easily. Andrew Bartlett
2011-05-02s3-rpc_server: (re)move last globally included rpc_server prototypes.Günther Deschner1-0/+1
Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Mon May 2 16:05:31 CEST 2011 on sn-devel-104
2011-05-02s3: include ntdomain.h before including generated srv_ headers.Günther Deschner1-1/+1
Guenther
2011-05-02s3-proto: move more rpc_server prototypes out of proto.hGünther Deschner1-0/+1
Guenther
2011-04-29s3-proto: move more headers to rpc_server/rpc_ncacn_np.h where they origin from.Günther Deschner1-0/+1
Guenther Autobuild-User: Günther Deschner <gd@samba.org> Autobuild-Date: Fri Apr 29 22:05:07 CEST 2011 on sn-devel-104
2011-04-05auth: Move auth_session_info into IDLAndrew Bartlett1-7/+11
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-05s3-auth Rename user_session_key -> session_key to match auth_session_infoAndrew Bartlett1-1/+1
2011-04-05s3-auth use create_local_token() to transform server_info -> session_infoAndrew Bartlett1-6/+4
Before a auth_serversupplied_info struct can be used for authorization, the local groups and privileges must be calculated. create_local_token() now copies the server_info, and then sets the calulated token and unix groups. Soon, it will also transform the result into an expanded struct auth_session_info. Until then, the variable name (server_info vs session_info provides a clue to the developer about what information has been entered in the structure). By moving the calls to create_local_token within the codebase, we remove duplication, and ensure that the session key (where modified) is consistently copied into the new structure. Andrew Bartlett
2011-03-31s3: Fix a typoVolker Lendecke1-1/+1
Autobuild-User: Volker Lendecke <vlendec@samba.org> Autobuild-Date: Thu Mar 31 12:50:53 CEST 2011 on sn-devel-104
2011-03-30s3-includes: only include ntdomain.h where needed.Günther Deschner1-0/+1
Guenther
2011-03-30s3-auth: rpc_server needs auth.hGünther Deschner1-0/+1
Guenther