script/debugoc: Add option to only print openchange process ID w/o gdb

Usefull for guys that want to debug with something else, like Eclipse

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
WIP: openchangedb: Impelement Logger module

Important part is openchangedb.c:openchangedb_initialize()
For now it is very simple and not flexibble, but this approach
will allow us to 'stack' backend chains.

openchangedb_logger is an example for doing staff during backend calls.
My aim is to make it configurable through loadparm_context like:
  mapiproxy:openchangedb = logger,mysql
Other thing would be to have a simple registry for backend modules,
so we could get rid of this clumsy if (myslq)... else if(ldb)...
WIP: MAPISTATUS: Use MAPI_SUCCESS for success code name

It is hard now to search into log files for MAPI errors,
as we always put the prevfix MAPI_E_ even in case of success.

MS defines success for mapi ops to be SUCCESS_SUCCESS
and mark failures with MAPI_E_ (mapi error).
IMO, in our case MAPI_SUCCESS is a bit better.

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
oxcmsg: Implementation for partial UserDNs in ModifyRecipients call

When Outlook passes some value in RecipientRow.prefix_size, then
we should restore the full legacyExchangeDN in recipient_x500name
using szDNPrefix we supplied to Outlook during Connect op.

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
build: Don't rmdir on setup/mapistore, just remove mapistore_namedprops_v2.ldif

mapistore_namedprops_v2.ldif is generated by script/makepropslist.py script

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
setup: Move enable/disable account handlers after create account

This would allow executing the script as:
openchange_newuser --create --enable newName

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
oxcfxics: Fail RopSyncImportHierarchyChange if we can't open perent folder
for SyncContext

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
oxcfxics/RopSyncImportHierarchyChange: use parent_folder var to open underlying folder

todo: commit message is not very good - need to elaborate more on that

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
Create commandline tool to list Mapistore contexts in JSON

I used this into Python script to enum somehow all folders
Mapistore backend knows about. This is due to the fact that
currently Python bindings are not working (and quite outdated)

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
exchange_emsmdb/dcesrv_EcDoRpcExt2: Fix use-after free in

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
mapistore_replica: ensure the user mapistore directory exists before any mapistore operation occurs

This fixes a regression introduced by moving Indexing code to MqSQL land.
Previously this code relied on indexing_tdb for precreating
directory strcture.

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>
mapistore_replica: Initialize replica database if it freshly created

Signed-off-by: Kamen Mazdrashki <kmazdrashki@zentyal.com>