Complete Contents
Getting Started
Chapter 1 Understanding Server Plug-Ins
Chapter 2 Writing and Compiling Plug-Ins
Chapter 3 Calling the Front-End API Functions
Chapter 4 Quick Start
Chapter 5 Writing Database Plug-Ins
Chapter 6 Writing Pre/Post-Operation Plug-Ins
Chapter 7 Defining Functions for LDAP Operations
Chapter 8 Defining Functions for Database Operations
Chapter 9 Defining Functions for Authentication
Chapter 10 Writing Entry Store/Fetch Plug-Ins
Chapter 11 Writing Extended Operation Plug-Ins
Chapter 12 Writing Matching Rule Plug-Ins
Chapter 13 Data Type and Structure Reference
Chapter 14 Function Reference
Chapter 15 Parameter Reference
Glossary
Previous Next Contents Bookshelf Function List



 slapi_send_ldap_referral()
Processes an entry's LDAP v3 referrals (which are found in the entry's ref attribute). For LDAP v3 clients, this function sends the LDAP referrals back to the client. For LDAP v2 clients, this function copies the referrals to an array of berval structures that you can pass to slapi_send_ldap_result() function at a later time.

Syntax

#include "slapi-plugin.h"
int slapi_send_ldap_referral( Slapi_PBlock *pb, Slapi_Entry *e, struct berval **refs, struct berval ***urls );

Parameters

The function has the following parameters:
pb

Parameter block.
e

Pointer to the Slapi_Entry structure representing the entry that you are working with.
refs

Pointer to the NULL-terminated array of berval structures containing the LDAP v3 referrals (search result references) found in the entry.
urls

Pointer to the array of berval structures used to collect LDAP referrals for LDAP v2 clients.

Returns

0 if successful, or -1 if an error occurs.

Description

When you call this function, the server processes the LDAP referrals specified in the refs argument. The server processes referrals in different ways, depending on the version of the LDAP protocol supported by the client:

If you want to define your own function for sending referrals, write a function complies with the type definition send_ldap_referral_fn_ptr_t and set the SLAPI_PLUGIN_DB_REFERRAL_FN parameter in the parameter block to the name of your function.

Example

[To be added]

See Also

slapi_send_ldap_result(), slapi_send_ldap_search_entry().

 

© Copyright 1998 Netscape Communications Corporation