dcesrv_mapiproxy_server.c File Reference

mapiproxy server modules management More...

#include "libmapi/libmapi.h"
#include "mapiproxy/dcesrv_mapiproxy.h"
#include "libmapiproxy.h"
#include "utils/dlinklist.h"

Functions

const struct mapiproxy_modulemapiproxy_server_byname (const char *name)
 
const struct mapiproxy_modulemapiproxy_server_bystatus (const char *name, enum mapiproxy_status status)
 
NTSTATUS mapiproxy_server_dispatch (struct dcesrv_call_state *dce_call, TALLOC_CTX *mem_ctx, void *r, struct mapiproxy *mapiproxy)
 
_PUBLIC_ TDB_CONTEXT * mapiproxy_server_emsabp_tdb_init (struct loadparm_context *lp_ctx)
 
_PUBLIC_ NTSTATUS mapiproxy_server_init (struct dcesrv_context *dce_ctx)
 
static NTSTATUS mapiproxy_server_load (struct dcesrv_context *dce_ctx)
 
_PUBLIC_ bool mapiproxy_server_loaded (const char *endpoint)
 
_PUBLIC_ void * mapiproxy_server_openchangedb_init (struct loadparm_context *lp_ctx)
 
static NTSTATUS mapiproxy_server_overwrite (TALLOC_CTX *mem_ctx, const char *name, const char *endpoint)
 
NTSTATUS mapiproxy_server_register (const void *_server_module)
 
NTSTATUS mapiproxy_server_unbind (struct server_id server_id, uint32_t context_id)
 

Variables

static TDB_CONTEXT * emsabp_tdb_ctx = NULL
 
int num_server_modules
 
static void * openchange_ldb_ctx = NULL
 
static struct mapiproxy_module_listserver_list = NULL
 
static struct server_module * server_modules = NULL
 

Detailed Description

mapiproxy server modules management

Function Documentation

◆ mapiproxy_server_byname()

const struct mapiproxy_module * mapiproxy_server_byname ( const char * name)

◆ mapiproxy_server_bystatus()

const struct mapiproxy_module * mapiproxy_server_bystatus ( const char * name,
enum mapiproxy_status status )

◆ mapiproxy_server_dispatch()

NTSTATUS mapiproxy_server_dispatch ( struct dcesrv_call_state * dce_call,
TALLOC_CTX * mem_ctx,
void * r,
struct mapiproxy * mapiproxy )

◆ mapiproxy_server_emsabp_tdb_init()

_PUBLIC_ TDB_CONTEXT * mapiproxy_server_emsabp_tdb_init ( struct loadparm_context * lp_ctx)

Initialize an EMSABP TDB context available to all instances when Samba is not run in single mode.

Parameters
lp_ctxpointer to the loadparm context
Note
TDB database can't be opened twice with O_RDWR flags. We ensure here we have a general context initialized, which we'll reopen within forked instances

return Allocated TDB context on success, otherwise NULL

References emsabp_tdb_ctx, and EMSABP_TDB_NAME.

Referenced by emsabp_tdb_init().

◆ mapiproxy_server_init()

_PUBLIC_ NTSTATUS mapiproxy_server_init ( struct dcesrv_context * dce_ctx)

Initialize mapiproxy servers modules

Parameters
dce_ctxpointer to the connection context
Returns
NT_STATUS_OK on success otherwise NT error

References load_openchange_plugins(), and mapiproxy_server_load().

Referenced by mapiproxy_op_init_server().

◆ mapiproxy_server_load()

◆ mapiproxy_server_loaded()

_PUBLIC_ bool mapiproxy_server_loaded ( const char * endpoint)

◆ mapiproxy_server_openchangedb_init()

_PUBLIC_ void * mapiproxy_server_openchangedb_init ( struct loadparm_context * lp_ctx)

Initialize an openchangedb context available to all mapiproxy instances. This context points on the OpenChange dispatcher database used within emsmdb default provider.

Parameters
lp_ctxpointer to the loadparm context
Note
The memory context is not free'd leading and causes a loss record.
Returns
Allocated openchangedb context on success, otherwise NULL

References openchange_ldb_ctx, and openchangedb_initialize().

Referenced by emsmdbp_openchangedb_init().

◆ mapiproxy_server_overwrite()

static NTSTATUS mapiproxy_server_overwrite ( TALLOC_CTX * mem_ctx,
const char * name,
const char * endpoint )
static

◆ mapiproxy_server_register()

NTSTATUS mapiproxy_server_register ( const void * _server_module)
extern

References num_server_modules, and server_modules.

Referenced by samba_init_module().

◆ mapiproxy_server_unbind()

NTSTATUS mapiproxy_server_unbind ( struct server_id server_id ,
uint32_t context_id )

Variable Documentation

◆ emsabp_tdb_ctx

TDB_CONTEXT* emsabp_tdb_ctx = NULL
static

◆ num_server_modules

◆ openchange_ldb_ctx

void* openchange_ldb_ctx = NULL
static

◆ server_list

◆ server_modules

struct server_module * server_modules = NULL
static

Creative Commons License
Creative Commons Attribution icon Creative Commons Share Alike icon
This content is licensed under the Creative Commons
Attribution ShareAlike License v. 3.0:
http://creativecommons.org/licenses/by-sa/3.0/