ldaprot.h revision 7c478bd95313f5f23a4c958a745db2134aa03244
/*
* Copyright (c) 2001 by Sun Microsystems, Inc.
* All rights reserved.
*/
#pragma ident "%Z%%M% %I% %E% SMI"
/*
* The contents of this file are subject to the Netscape Public
* License Version 1.1 (the "License"); you may not use this file
* except in compliance with the License. You may obtain a copy of
* the License at http://www.mozilla.org/NPL/
*
* Software distributed under the License is distributed on an "AS
* IS" basis, WITHOUT WARRANTY OF ANY KIND, either express or
* implied. See the License for the specific language governing
* rights and limitations under the License.
*
* The Original Code is Mozilla Communicator client code, released
* March 31, 1998.
*
* The Initial Developer of the Original Code is Netscape
* Communications Corporation. Portions created by Netscape are
* Copyright (C) 1998-1999 Netscape Communications Corporation. All
* Rights Reserved.
*
* Contributor(s):
*/
#ifndef _LDAPROT_H
#define _LDAPROT_H
#ifdef __cplusplus
extern "C" {
#endif
#define LDAP_VERSION1 1
#define LDAP_VERSION2 2
#define LDAP_VERSION3 3
#define LDAP_VERSION LDAP_VERSION2
#define COMPAT20
#define COMPAT30
#define COMPAT
#endif
#define LDAP_URL_PREFIX "ldap://"
#define LDAP_URL_PREFIX_LEN 7
#define LDAPS_URL_PREFIX "ldaps://"
#define LDAPS_URL_PREFIX_LEN 8
#define LDAP_REF_STR "Referral:\n"
#define LDAP_REF_STR_LEN 10
/*
* specific LDAP instantiations of BER types we know about
*/
#ifdef _SOLARIS_SDK
#endif /* ifdef _SOLARIS_SDK */
#ifndef _SOLARIS_SDK
/* general stuff */
/* possible operations a client can invoke */
/* U-M LDAP release 3.0 compatibility stuff */
#define LDAP_REQ_UNBIND_30 0x62L
#define LDAP_REQ_DELETE_30 0x6aL
#define LDAP_REQ_ABANDON_30 0x70L
/* U-M LDAP 3.0 compatibility auth methods */
/*
* old broken stuff for backwards compatibility - forgot application tag
* and constructed/primitive bit
*/
#define OLD_LDAP_REQ_BIND 0x00L
#define OLD_LDAP_REQ_UNBIND 0x02L
#define OLD_LDAP_REQ_SEARCH 0x03L
#define OLD_LDAP_REQ_MODIFY 0x06L
#define OLD_LDAP_REQ_ADD 0x08L
#define OLD_LDAP_REQ_DELETE 0x0aL
#define OLD_LDAP_REQ_MODRDN 0x0cL
#define OLD_LDAP_REQ_MODDN 0x0cL
#define OLD_LDAP_REQ_COMPARE 0x0eL
#define OLD_LDAP_REQ_ABANDON 0x10L
/* old broken stuff for backwards compatibility */
#define OLD_LDAP_RES_BIND 0x01L
#define OLD_LDAP_RES_SEARCH_ENTRY 0x04L
#define OLD_LDAP_RES_SEARCH_RESULT 0x05L
#define OLD_LDAP_RES_MODIFY 0x07L
#define OLD_LDAP_RES_ADD 0x09L
#define OLD_LDAP_RES_DELETE 0x0bL
#define OLD_LDAP_RES_MODRDN 0x0dL
#define OLD_LDAP_RES_MODDN 0x0dL
#define OLD_LDAP_RES_COMPARE 0x0fL
/* U-M LDAP 3.0 compatibility auth methods */
/* old broken stuff */
#define OLD_LDAP_AUTH_SIMPLE 0x00L
#define OLD_LDAP_AUTH_KRBV4 0x01L
#define OLD_LDAP_AUTH_KRBV42 0x02L
/* U-M LDAP 3.0 compatibility filter types */
/* filter types */
/* old broken stuff */
#define OLD_LDAP_FILTER_AND 0x00L
#define OLD_LDAP_FILTER_OR 0x01L
#define OLD_LDAP_FILTER_NOT 0x02L
#define OLD_LDAP_FILTER_EQUALITY 0x03L
#define OLD_LDAP_FILTER_SUBSTRINGS 0x04L
#define OLD_LDAP_FILTER_GE 0x05L
#define OLD_LDAP_FILTER_LE 0x06L
#define OLD_LDAP_FILTER_PRESENT 0x07L
#define OLD_LDAP_FILTER_APPROX 0x08L
/* substring filter component types */
/* extended filter component types */
/* U-M LDAP 3.0 compatibility substring filter component types */
/* old broken stuff */
#define OLD_LDAP_SUBSTRING_INITIAL 0x00L
#define OLD_LDAP_SUBSTRING_ANY 0x01L
#define OLD_LDAP_SUBSTRING_FINAL 0x02L
#endif /* _SOLARIS_SDK */
#ifdef __cplusplus
}
#endif
#endif /* _LDAPROT_H */