MAPIProxy 2.0 API Documentation

- Main Page
- Related Pages
- Data Structures
- Files

- File List
- Globals

Functions
dcesrv_mapiproxy_nspi.c File Reference

NSPI hook functions. More...

`#include "mapiproxy/dcesrv_mapiproxy.h"`
`#include "mapiproxy/dcesrv_mapiproxy_proto.h"`
`#include "libmapi/mapidefs.h"`
`#include "libmapi/property_altnames.h"`

## Functions
bool | mapiproxy_NspiDNToMId (struct dcesrv_call_state *dce_call, struct NspiDNToMId *r)
bool | mapiproxy_NspiGetProps (struct dcesrv_call_state *dce_call, struct NspiGetProps *r)
bool | mapiproxy_NspiQueryRows (struct dcesrv_call_state *dce_call, struct NspiQueryRows *r)
static char * | x500_get_servername (const char *dn)

## Detailed Description

NSPI hook functions.

## Function Documentation

bool mapiproxy_NspiDNToMId | ( | struct dcesrv_call_state * | dce_call,
|  | struct NspiDNToMId * | r
| ) |  |

This function looks if the server DN string in the request holds the mapiproxy netbios name and replaces it with the original Exchange server one fetched from NspiQueryRows or NspiGetProps.

Parameters

  dce_call | pointer to the session context
  r | pointer to the NspiDNToMId structure

Returns
  true on success or false if no occurrence of the mapiproxy netbios name was found.

Referenced by mapiproxy_op_dispatch().

bool mapiproxy_NspiGetProps | ( | struct dcesrv_call_state * | dce_call,
|  | struct NspiGetProps * | r
| ) |  |

This function replaces network address from the binding strings returned by Exchange for the PR_EMS_AB_NETWORK_ADDRESS property and limit the binding strings scope to ncacn_ip_tcp.

Parameters

  dce_call | pointer to the session context
  r | pointer to the NspiGetProps structure

Returns
  true on success, otherwise false

Referenced by mapiproxy_op_ndr_push().

bool mapiproxy_NspiQueryRows | ( | struct dcesrv_call_state * | dce_call,
|  | struct NspiQueryRows * | r
| ) |  |

This function replaces the Exchange server name with mapiproxy netbios name for the PR_EMS_AB_HOME_MDB property and saves the original name in a global variable for further usage - such as mapiproxy_NspiDNToMId.

Parameters

  dce_call | pointer to the session context
  r | pointer to the NspiQueryRows structure

See Also
  mapiproxy_NspiDNToMId

References x500_get_servername().

Referenced by mapiproxy_op_ndr_push().

static char* x500_get_servername | ( | const char * | dn | ) |
| static

Retrieve the servername from a DN string

Parameters

  dn | the DN string

Returns
  a talloc'd server name

Referenced by mapiproxy_NspiQueryRows().

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