Back to index

openldap  2.4.31
Classes | Defines | Typedefs | Functions | Variables
componentlib.h File Reference
#include "portable.h"
#include <ac/string.h>
#include <ac/socket.h>
#include <ldap_pvt.h>
#include "lutil.h"
#include <ldap.h>
#include <slap.h>
#include <component.h>
#include <asn-incl.h>
#include "asn.h"
#include <asn-gser.h>
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  slap_component_type
struct  ComponentBits
struct  ComponentBMPString
struct  ComponentBool
struct  ComponentEnum
struct  ComponentIA5String
struct  ComponentInt
struct  ComponentList
struct  ComponentNull
struct  ComponentNumericString
struct  ComponentOcts
struct  ComponentOid
struct  ComponentPrintableString
struct  ComponentReal
struct  ComponentRelativeOid
struct  ComponentTeletexString
struct  ComponentUniversalString
struct  ComponentUTF8String
struct  ComponentVisibleString
struct  ComponentAnyInfo
struct  ComponentAny
struct  asntype_to_syntax
struct  asntype_to_comp_matchingrule
struct  asntype_to_comp_desc
struct  asntype_to_comp_type
struct  asntype_to_matchingrule
struct  asntype_to_matchingrule_table
struct  OID_Decoder_entry
struct  comp_irAttributeTypeAndValue

Defines

#define MAX_IDENTIFIER_LEN   32
#define COMPONENTNOT_NULL(ptr)   ((ptr) != NULL)
#define GASNBITS_PRESENT(abits)   ((abits)->value.bits != NULL)
#define COMPONENTBITS_PRESENT(abits)   ((abits)->value.bits != NULL)
#define ExtractingComponentBits(mem_op, cr, data)   NULL
#define MatchingComponentBMPString   MatchingComponentOcts
#define ExtractingComponentBMPString(mem_op, cr, data)   NULL
#define FreeComponentBMPString   FreeComponentOcts
#define ExtractingComponentBool(mem_op, cr, data)   NULL
#define FreeComponentBool(v)   NULL
#define ExtractingComponentEnum(mem_op, cr, data)   NULL
#define FreeComponentEnum   FreeComponentInt
#define GEncComponentIA5String   GEncComponentUTF8String
#define GDecComponentIA5String   GDecComponentUTF8String
#define MatchingComponentIA5String   MatchingComponentOcts
#define ExtractingComponentIA5String(mem_op, cr, data)   NULL
#define FreeComponentIA5String   FreeComponentOcts
#define GNOT_NULL(ptr)   ((ptr) != NULL)
#define ExtractingComponentInt(mem_op, cr, data)   NULL
#define FreeComponentInt(v)   NULL
#define ExtractingComponentNull(mem_op, cr, data)   NULL
#define FreeComponentNull   NULL
#define GEncComponentNumericString   GEncComponentUTF8String
#define GDecComponentNumericString   GDecComponentUTF8String
#define MatchingComponentNumericString   MatchingComponentOcts
#define ExtractingComponentNumericString(mem_op, cr, data)   NULL
#define FreeComponentNumericString   FreeComponentOcts
#define GASNOCTS_PRESENT(aocts)   ((aocts)->value.octs != NULL)
#define ExtractingComponentOcts(mem_op, cr, data)   NULL
#define GASNOID_PRESENT(aoid)   ASNOCTS_PRESENT(aoid)
#define ExtractingComponentOid(mem_op, cr, data)   NULL
#define FreeComponentOid   FreeComponentOcts
#define GEncComponentPrintableString   GEncComponentUTF8String
#define GDecComponentPrintableString   GDecComponentUTF8String
#define MatchingComponentPrintableString   MatchingComponentOcts
#define ExtractingComponentPrintableString(mem_op, cr, data)   NULL
#define FreeComponentPrintableString   FreeComponentOcts
#define ExtractingComponentReal(mem_op, cr, data)   NULL
#define FreeComponentReal(v)   NULL
#define ExtractingComponentRelativeOid(mem_op, cr, data)   NULL
#define FreeComponentRelativeOid   FreeComponentOid
#define MatchingComponentTeletexString   MatchingComponentOcts
#define ExtractingComponentTeletexString(mem_op, cr, data)
#define FreeComponentTeletexString   FreeComponentOcts
#define MatchingComponentUniversalString   MatchingComponentOcts
#define ExtractingComponentUniversalString(mem_op, cr, data)
#define FreeComponentUniversalString   FreeComponentOcts
#define MatchingComponentUTF8String   MatchingComponentOcts
#define ExtractingComponentUTF8String(mem_op, cr, data)
#define FreeComponentUTF8String   FreeComponentOcts
#define GEncComponentVisibleString   GEncComponentUTF8String
#define GDecComponentVisibleString   GDecComponentUTF8String
#define MatchingComponentVisibleString   MatchingComponentOcts
#define ExtractingComponentVisibleString(mem_op, cr, data)
#define FreeComponentVisibleString   FreeComponentOcts
#define BDecComponentAnyDefinedBy   BDecComponentAny
#define GDecComponentAnyDefinedBy   GDecComponentAny
#define MatchingComponentAnyDefinedBy   MatchingComponentAny
#define FreeComponentAnyDefinedBy   FreeComponentAny
#define GEncComponentUTCTime   GEncComponentUTF8String
#define GDecComponentUTCTime   GDecComponentVisibleString
#define BDecComponentUTCTime   BDecComponentOcts
#define MatchingComponentUTCTime   MatchingComponentOcts
#define ExtractingComponentUTCTime(mem_op, cr, data)   NULL
#define FreeComponentUTCTime   FreeComponentOcts
#define GDecComponentGeneralizedTime   GDecComponentVisibleString
#define BDecComponentGeneralizedTime   BDecComponentOcts
#define MatchingComponentGeneralizedTime   MatchingComponentOcts
#define ExtractingComponentGeneralizedTime(mem_op, cr, data)   NULL
#define FreeComponentGeneralizedTime   FreeComponentOcts
#define MAX_OID_LEN   256
#define MAX_OD_ENTRY   8
#define DEC_ALLOC_MODE_0   0x01
#define DEC_ALLOC_MODE_1   0x02
#define DEC_ALLOC_MODE_2   0x04
#define CALL_TAG_DECODER   0x08
#define CALL_CONTENT_DECODER   ~0x08
#define OID_ALL_COMP_MATCH   "1.2.36.79672281.1.13.6"
#define OID_COMP_FILTER_MATCH   "1.2.36.79672281.1.13.2"
#define MAX_LDAP_STR_LEN   128
#define INITIAL_DN_SIZE   128
#define INITIAL_ATTR_SIZE   256
#define INCREMENT_SIZE   32
#define MAX_ALIASING_ENTRY   128
#define RDN_MATCH_OID   "1.2.36.79672281.1.13.3"
#define DN_MATCH_OID   "2.5.13.1"

Typedefs

typedef struct slap_component_type ComponentType
typedef struct ComponentBits ComponentBits
typedef struct ComponentBMPString ComponentBMPString
typedef struct ComponentBool ComponentBool
typedef struct ComponentEnum ComponentEnum
typedef struct ComponentIA5String ComponentIA5String
typedef struct ComponentInt ComponentInt
typedef struct ComponentList ComponentList
typedef struct ComponentNull ComponentNull
typedef struct
ComponentNumericString 
ComponentNumericString
typedef struct ComponentOcts ComponentOcts
typedef struct ComponentOid ComponentOid
typedef struct
ComponentPrintableString 
ComponentPrintableString
typedef struct ComponentReal ComponentReal
typedef struct ComponentRelativeOid ComponentRelativeOid
typedef struct
ComponentTeletexString 
ComponentTeletexString
typedef struct
ComponentUniversalString 
ComponentUniversalString
typedef struct ComponentUTF8String ComponentUTF8String
typedef struct
ComponentVisibleString 
ComponentVisibleString
typedef int(* MatchFcn )(char *, void *, void *)
typedef void *(* ExtractFcn )(void *, ComponentReference *, void *)
typedef struct ComponentAnyInfo ComponentAnyInfo
typedef struct ComponentAny ComponentAny
typedef ComponentAny ComponentAnyDefinedBy
typedef ComponentVisibleString ComponentUTCTime
typedef ComponentVisibleString ComponentGeneralizedTime
typedef int converter_func LDAP_P ((struct berval *in))
typedef struct asntype_to_syntax AsnTypetoSyntax
typedef struct
asntype_to_comp_matchingrule 
AsnTypetoCompMatchingRule
typedef struct asntype_to_comp_desc AsnTypetoCompDesc
typedef struct asntype_to_comp_type AsnTypetoCompType
typedef struct
asntype_to_matchingrule 
AsnTypetoMatchingRule
typedef struct
asntype_to_matchingrule_table 
AsnTypetoMatchingRuleTable
typedef struct OID_Decoder_entry OD_entry
typedef ComponentList irRDNSequence
typedef ComponentList irRelativeDistinguishedName
typedef ComponentOid irAttributeType
typedef struct
comp_irAttributeTypeAndValue 
irAttributeTypeAndValue

Functions

int GEncComponentBits (GenBuf *b, ComponentBits *bits)
int GDecComponentBits (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentBits (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentBits (char *oid, ComponentSyntaxInfo *bits1, ComponentSyntaxInfo *bits2)
int GEncComponentBMPString (GenBuf *b, ComponentBMPString *bmp)
int GDecComponentBMPString (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentBMPString (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int GEncComponentBool (GenBuf *b, ComponentBool *bool)
int GDecComponentBool (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentBool (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentBool (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
int GEncComponentEnum (GenBuf *b, ComponentEnum *comp_enum)
int GDecComponentEnum (void *mem_op, GenBuf *a, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentEnum (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentEnum (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
int BDecComponentIA5StringTag (void *mem_op, GenBuf *b, void *v, AsnLen *bytesDecoded, int mode)
int BDecComponentIA5String (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int GEncComponentInt (GenBuf *b, ComponentInt *comp_int)
int GDecComponentInt (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentInt (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentInt (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
int GEncComponentNull (GenBuf *b, ComponentNull *comp_null)
int GDecComponentNull (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentNull (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentNullTag (void *mem_op, GenBuf *b, void *v, AsnLen *bytesDecoded, int mode)
int MatchingComponentNull (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
int BDecComponentNumericString (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int GEncComponentOcts (GenBuf *b, ComponentOcts *octs)
int GDecComponentOcts (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentOctsTag (void *mem_op, GenBuf *b, void *v, AsnLen *bytesDecoded, int mode)
int BDecComponentOcts (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentOcts (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
void FreeComponentOcts (ComponentOcts *octs)
int GEncComponentOid (GenBuf *b, ComponentOid *oid)
int GDecComponentOid (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentOid (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentOid (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
int BDecComponentPrintableString (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentPrintableStringTag (void *mem_op, GenBuf *b, void *v, AsnLen *bytesDecoded, int mode)
int GEncComponentReal (GenBuf *b, ComponentReal *comp_real)
int GDecComponentReal (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentReal (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentReal (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
int GEncComponentRelativeOid (GenBuf *b, ComponentRelativeOid *r_oid)
int GDecComponentRelativeOid (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentRelativeOid (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentRelativeOid (char *oid, ComponentSyntaxInfo *a, ComponentSyntaxInfo *b)
int GEncComponentTeletexString (GenBuf *b, ComponentTeletexString *tel_str)
int GDecComponentTeletexString (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentTeletexStringTag (void *mem_op, GenBuf *b, void *v, AsnLen *bytesDecoded, int mode)
int BDecComponentTeletexString (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *v, AsnLen *bytesDecoded, int mode)
int GEncComponentUniversalString (GenBuf *b, ComponentUniversalString *uni_str)
int GDecComponentUniversalString (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentUniversalString (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int GEncComponentUTF8String (GenBuf *b, ComponentUTF8String *utf_str)
int GDecComponentUTF8String (void *mem_op, GenBuf *b, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentUTF8String (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int BDecComponentVisibleString (void *mem_op, GenBuf *b, AsnTag tagId, AsnLen len, void *result, AsnLen *bytesDecoded, int mode)
int GEncComponentAny (GenBuf *b, ComponentAny *comp_any)
int BDecComponentAny (void *mem_op, GenBuf *b, ComponentAny *result, AsnLen *bytesDecoded, int mode)
int GDecComponentAny (void *mem_op, GenBuf *b, ComponentAny *result, AsnLen *bytesDecoded, int mode)
int MatchingComponentAny (char *oid, ComponentAny *a, ComponentAny *b)
void FreeComponentAny (ComponentAny *)
void InstallAnyByComponentInt (int anyId, ComponentInt intId, unsigned int size, EncodeFcn encode, gser_decoder_func *G_decode, ber_tag_decoder_func B_decode, ExtractFcn extract, MatchFcn match, FreeFcn free, PrintFcn print)
void InstallAnyByComponentOid (int anyId, AsnOid *oid, unsigned int size, EncodeFcn encode, gser_decoder_func *G_decode, ber_tag_decoder_func *B_decode, ExtractFcn extract, MatchFcn match, FreeFcn free, PrintFcn print)
int CheckSelectTypeCorrect (void *mem_op, ComponentAnyInfo *v, struct berval *select)
OidDecoderMapping * RetrieveOidDecoderMappingbyBV (struct berval *in)
OidDecoderMapping * RetrieveOidDecoderMappingbyOid (char *ch_oid, int oid_len)
OidDecoderMapping * RetrieveOidDecoderMappingbyDesc (char *desc, int desc_len)
int GEncComponentGeneralizedTime (GenBuf *b, ComponentGeneralizedTime *gen_time)
void m_convert_asn_to_ldap (ComponentSyntaxInfo *csi, struct berval *bv)
int m_convert_assert_to_comp (gser_decoder_func *decoder, struct berval *bv, ComponentSyntaxInfo **csi, int len, int mode)
voidm_convert_attr_to_comp (Attribute *a, struct berval *bv)
MatchingRuleretrieve_matching_rule (char *mr_oid, AsnTypeId type)
int increment_bv_mem (struct berval *in)
int intToAscii (int value, char *buf)
int ConvertRDN2RFC2253 (irRelativeDistinguishedName *in, struct berval *out)
int ConvertRDNSequence2RFC2253 (irRDNSequence *in, struct berval *out)
voidcomp_nibble_memory_allocator (int init_mem, int inc_mem)
ComponentDesc * get_ComponentDesc (int id)

Variables

AsnTypetoSyntax asn_to_syntax_mapping_tbl []
AsnTypetoCompMatchingRule asntype_to_compMR_mapping_tbl []
AsnTypetoCompType asntype_to_compType_mapping_tbl []
AsnTypetoCompDesc asntype_to_compdesc_mapping_tbl []

Class Documentation

struct slap_component_type

Definition at line 32 of file componentlib.h.

Collaboration diagram for slap_component_type:
Class Members
MatchingRule * ct_approx
LDAPAttributeType ct_atype
MatchingRule * ct_equality
MatchingRule * ct_ordering
MatchingRule * ct_substr
struct slap_attribute_type ** ct_subtypes
struct slap_attribute_type * ct_sup
Syntax * ct_syntax
struct ComponentBits

Definition at line 53 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnBits value
struct ComponentBMPString

Definition at line 72 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
BMPString value
struct ComponentBool

Definition at line 90 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnBool value
struct ComponentEnum

Definition at line 108 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnEnum value
struct ComponentIA5String

Definition at line 127 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
IA5String value
struct ComponentInt

Definition at line 148 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
int value
struct ComponentList

Definition at line 167 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
AsnList comp_list
char id_buf
void * syntax
struct ComponentNull

Definition at line 178 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnNull value
struct ComponentNumericString

Definition at line 197 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
NumericString value
struct ComponentOcts

Definition at line 215 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnOcts value
struct ComponentOid

Definition at line 235 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnOid value
struct ComponentPrintableString

Definition at line 254 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
PrintableString value
struct ComponentReal

Definition at line 272 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnReal value
struct ComponentRelativeOid

Definition at line 291 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
AsnRelativeOid value
struct ComponentTeletexString

Definition at line 309 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
TeletexString value
struct ComponentUniversalString

Definition at line 329 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
UniversalString value
struct ComponentUTF8String

Definition at line 347 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
UTF8String value
struct ComponentVisibleString

Definition at line 365 of file componentlib.h.

Class Members
ComponentDesc * comp_desc
char id_buf
void * syntax
VisibleString value
struct ComponentAnyInfo

Definition at line 387 of file componentlib.h.

Collaboration diagram for ComponentAnyInfo:
Class Members
int anyId
ber_tag_decoder_func * BER_Decode
EncodeFcn Encode
ExtractFcn Extract
FreeFcn Free
gser_decoder_func * GSER_Decode
ComponentInt intId
MatchFcn Match
AsnOid oid
PrintFcn Print
unsigned int size
struct ComponentAny

Definition at line 404 of file componentlib.h.

Collaboration diagram for ComponentAny:
Class Members
ComponentAnyInfo * cai
ComponentDesc * comp_desc
char id_buf
void * syntax
void * value
struct asntype_to_syntax

Definition at line 460 of file componentlib.h.

Collaboration diagram for asntype_to_syntax:
Class Members
Syntax * ats_syn
char * ats_syn_name
char * ats_syn_oid
AsnTypeId ats_typeId
struct asntype_to_comp_matchingrule

Definition at line 469 of file componentlib.h.

Class Members
char * atc_approx
char * atc_equality
char * atc_ordering
char * atc_substr
AsnTypeId atc_typeId
struct asntype_to_comp_desc

Definition at line 477 of file componentlib.h.

Class Members
ComponentDesc atcd_cd
AsnTypeId atcd_typeId
struct asntype_to_comp_type

Definition at line 482 of file componentlib.h.

Collaboration diagram for asntype_to_comp_type:
Class Members
AsnTypeId ac_asn_id
ComponentType ac_comp_type
struct asntype_to_matchingrule

Definition at line 488 of file componentlib.h.

Collaboration diagram for asntype_to_matchingrule:
Class Members
MatchingRule * atmr_mr
char * atmr_mr_name
char * atmr_syn_oid
AsnTypeId atmr_typeId
struct asntype_to_matchingrule_table

Definition at line 496 of file componentlib.h.

Collaboration diagram for asntype_to_matchingrule_table:
Class Members
char * atmr_oid
struct
asntype_to_matchingrule_table *
atmr_table_next
struct OID_Decoder_entry

Definition at line 508 of file componentlib.h.

Collaboration diagram for OID_Decoder_entry:
Class Members
ber_decoder_func * oe_ber_decoder
converter_func * oe_converter
gser_decoder_func * oe_gser_decoder
struct OID_Decoder_entry * oe_next
char oe_oid
struct OID_Decoder_entry * oe_prev
struct comp_irAttributeTypeAndValue

Definition at line 570 of file componentlib.h.

Collaboration diagram for comp_irAttributeTypeAndValue:
Class Members
ComponentDesc * comp_desc
char id_buf
Syntax * syntax
irAttributeType type
ComponentAnyDefinedBy value

Define Documentation

Definition at line 415 of file componentlib.h.

Definition at line 452 of file componentlib.h.

Definition at line 441 of file componentlib.h.

#define CALL_CONTENT_DECODER   ~0x08

Definition at line 548 of file componentlib.h.

#define CALL_TAG_DECODER   0x08

Definition at line 547 of file componentlib.h.

#define COMPONENTBITS_PRESENT (   abits)    ((abits)->value.bits != NULL)

Definition at line 62 of file componentlib.h.

#define COMPONENTNOT_NULL (   ptr)    ((ptr) != NULL)

Definition at line 30 of file componentlib.h.

#define DEC_ALLOC_MODE_0   0x01

Definition at line 544 of file componentlib.h.

#define DEC_ALLOC_MODE_1   0x02

Definition at line 545 of file componentlib.h.

#define DEC_ALLOC_MODE_2   0x04

Definition at line 546 of file componentlib.h.

#define DN_MATCH_OID   "2.5.13.1"

Definition at line 580 of file componentlib.h.

#define ExtractingComponentBits (   mem_op,
  cr,
  data 
)    NULL

Definition at line 67 of file componentlib.h.

#define ExtractingComponentBMPString (   mem_op,
  cr,
  data 
)    NULL

Definition at line 84 of file componentlib.h.

#define ExtractingComponentBool (   mem_op,
  cr,
  data 
)    NULL

Definition at line 102 of file componentlib.h.

#define ExtractingComponentEnum (   mem_op,
  cr,
  data 
)    NULL

Definition at line 121 of file componentlib.h.

#define ExtractingComponentGeneralizedTime (   mem_op,
  cr,
  data 
)    NULL

Definition at line 454 of file componentlib.h.

#define ExtractingComponentIA5String (   mem_op,
  cr,
  data 
)    NULL

Definition at line 141 of file componentlib.h.

#define ExtractingComponentInt (   mem_op,
  cr,
  data 
)    NULL

Definition at line 161 of file componentlib.h.

#define ExtractingComponentNull (   mem_op,
  cr,
  data 
)    NULL

Definition at line 191 of file componentlib.h.

#define ExtractingComponentNumericString (   mem_op,
  cr,
  data 
)    NULL

Definition at line 209 of file componentlib.h.

#define ExtractingComponentOcts (   mem_op,
  cr,
  data 
)    NULL

Definition at line 229 of file componentlib.h.

#define ExtractingComponentOid (   mem_op,
  cr,
  data 
)    NULL

Definition at line 248 of file componentlib.h.

#define ExtractingComponentPrintableString (   mem_op,
  cr,
  data 
)    NULL

Definition at line 266 of file componentlib.h.

#define ExtractingComponentReal (   mem_op,
  cr,
  data 
)    NULL

Definition at line 284 of file componentlib.h.

#define ExtractingComponentRelativeOid (   mem_op,
  cr,
  data 
)    NULL

Definition at line 303 of file componentlib.h.

#define ExtractingComponentTeletexString (   mem_op,
  cr,
  data 
)

Definition at line 322 of file componentlib.h.

#define ExtractingComponentUniversalString (   mem_op,
  cr,
  data 
)

Definition at line 341 of file componentlib.h.

#define ExtractingComponentUTCTime (   mem_op,
  cr,
  data 
)    NULL

Definition at line 443 of file componentlib.h.

#define ExtractingComponentUTF8String (   mem_op,
  cr,
  data 
)

Definition at line 359 of file componentlib.h.

#define ExtractingComponentVisibleString (   mem_op,
  cr,
  data 
)

Definition at line 377 of file componentlib.h.

Definition at line 418 of file componentlib.h.

Definition at line 85 of file componentlib.h.

#define FreeComponentBool (   v)    NULL

Definition at line 103 of file componentlib.h.

Definition at line 122 of file componentlib.h.

Definition at line 455 of file componentlib.h.

Definition at line 142 of file componentlib.h.

#define FreeComponentInt (   v)    NULL

Definition at line 162 of file componentlib.h.

#define FreeComponentNull   NULL

Definition at line 192 of file componentlib.h.

Definition at line 210 of file componentlib.h.

Definition at line 249 of file componentlib.h.

Definition at line 267 of file componentlib.h.

#define FreeComponentReal (   v)    NULL

Definition at line 285 of file componentlib.h.

Definition at line 304 of file componentlib.h.

Definition at line 323 of file componentlib.h.

Definition at line 342 of file componentlib.h.

Definition at line 444 of file componentlib.h.

Definition at line 360 of file componentlib.h.

Definition at line 378 of file componentlib.h.

#define GASNBITS_PRESENT (   abits)    ((abits)->value.bits != NULL)

Definition at line 61 of file componentlib.h.

#define GASNOCTS_PRESENT (   aocts)    ((aocts)->value.octs != NULL)

Definition at line 223 of file componentlib.h.

#define GASNOID_PRESENT (   aoid)    ASNOCTS_PRESENT(aoid)

Definition at line 243 of file componentlib.h.

Definition at line 416 of file componentlib.h.

Definition at line 451 of file componentlib.h.

Definition at line 136 of file componentlib.h.

Definition at line 206 of file componentlib.h.

Definition at line 262 of file componentlib.h.

Definition at line 440 of file componentlib.h.

Definition at line 374 of file componentlib.h.

Definition at line 135 of file componentlib.h.

Definition at line 205 of file componentlib.h.

Definition at line 261 of file componentlib.h.

Definition at line 439 of file componentlib.h.

Definition at line 373 of file componentlib.h.

#define GNOT_NULL (   ptr)    ((ptr) != NULL)

Definition at line 156 of file componentlib.h.

#define INCREMENT_SIZE   32

Definition at line 559 of file componentlib.h.

#define INITIAL_ATTR_SIZE   256

Definition at line 558 of file componentlib.h.

#define INITIAL_DN_SIZE   128

Definition at line 557 of file componentlib.h.

Definition at line 417 of file componentlib.h.

Definition at line 83 of file componentlib.h.

Definition at line 453 of file componentlib.h.

Definition at line 140 of file componentlib.h.

Definition at line 208 of file componentlib.h.

Definition at line 265 of file componentlib.h.

Definition at line 321 of file componentlib.h.

Definition at line 340 of file componentlib.h.

Definition at line 442 of file componentlib.h.

Definition at line 358 of file componentlib.h.

Definition at line 376 of file componentlib.h.

#define MAX_ALIASING_ENTRY   128

Definition at line 564 of file componentlib.h.

#define MAX_IDENTIFIER_LEN   32

Definition at line 29 of file componentlib.h.

#define MAX_LDAP_STR_LEN   128

Definition at line 552 of file componentlib.h.

#define MAX_OD_ENTRY   8

Definition at line 503 of file componentlib.h.

#define MAX_OID_LEN   256

Definition at line 502 of file componentlib.h.

#define OID_ALL_COMP_MATCH   "1.2.36.79672281.1.13.6"

Definition at line 550 of file componentlib.h.

#define OID_COMP_FILTER_MATCH   "1.2.36.79672281.1.13.2"

Definition at line 551 of file componentlib.h.

#define RDN_MATCH_OID   "1.2.36.79672281.1.13.3"

Definition at line 579 of file componentlib.h.


Typedef Documentation

typedef struct ComponentAny ComponentAny

Definition at line 413 of file componentlib.h.

typedef struct ComponentAnyInfo

Definition at line 402 of file componentlib.h.

typedef struct ComponentBits ComponentBits
typedef struct ComponentBool ComponentBool
typedef struct ComponentEnum ComponentEnum

Definition at line 449 of file componentlib.h.

typedef struct ComponentInt ComponentInt
typedef struct ComponentList ComponentList
typedef struct ComponentNull ComponentNull
typedef struct ComponentOcts ComponentOcts
typedef struct ComponentOid ComponentOid
typedef struct ComponentReal ComponentReal

Definition at line 438 of file componentlib.h.

typedef void*(* ExtractFcn)(void *, ComponentReference *, void *)

Definition at line 385 of file componentlib.h.

Definition at line 569 of file componentlib.h.

Definition at line 567 of file componentlib.h.

Definition at line 568 of file componentlib.h.

Definition at line 457 of file componentlib.h.

typedef int(* MatchFcn)(char *, void *, void *)

Definition at line 384 of file componentlib.h.

typedef struct OID_Decoder_entry OD_entry

Function Documentation

int BDecComponentAny ( void mem_op,
GenBuf *  b,
ComponentAny result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1864 of file componentlib.c.

                                                                                                  {
       int rc;
        ComponentAny *k, **k2;
                                                                          
        k = (ComponentAny*) result;

       if ( !k ) return (-1);
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentAny**) result;
                *k2 = (ComponentAny*) CompAlloc( mem_op, sizeof( ComponentAny ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       
       if ((result->cai != NULL) && (result->cai->BER_Decode != NULL)) {
              result->cai->BER_Decode ( mem_op, b, (ComponentSyntaxInfo*)&result->value, (int*)bytesDecoded, DEC_ALLOC_MODE_0 );

              k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
              if ( !k->comp_desc )  {
                     if ( k ) CompFree ( mem_op, k );
                     return LDAP_DECODING_ERROR;
              }
              k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentAny;
              k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentAny;
              k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentAny;
              k->comp_desc->cd_free = (comp_free_func*)FreeComponentAny;
              k->comp_desc->cd_extract_i = NULL;
              k->comp_desc->cd_type = ASN_BASIC;
              k->comp_desc->cd_type_id = BASICTYPE_ANY;
              k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentAny;
              return LDAP_SUCCESS;
       }
       else {
              Asn1Error ("ERROR - Component ANY Decode routine is NULL\n");
              return 0;
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentBits ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 119 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentBits* k, **k2;
       AsnBits result;
                                                                          
        k = (ComponentBits*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentBits**) v;
                *k2 = (ComponentBits*) CompAlloc( mem_op, sizeof( ComponentBits ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
        
       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnBits ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnBitsContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }

       if ( rc < 0 ) {
              if ( k ) CompFree( mem_op,  k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_BITSTRING);
 
       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentBMPString ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 213 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentBMPString* k, **k2;
       BMPString result;
                                                                          
        k = (ComponentBMPString*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentBMPString**) v;
                *k2 = (ComponentBMPString*) CompAlloc( mem_op, sizeof( ComponentBMPString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecBMPString ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecBMPStringContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }

       if ( rc < 0 ) {
              if ( k ) CompFree( mem_op, k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_BMP_STR);
 
       return LDAP_SUCCESS;

}

Here is the caller graph for this function:

int BDecComponentBool ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 466 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        ComponentBool* k, **k2;
       AsnBool result;
                                                                          
        k = (ComponentBool*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentBool**) v;
                *k2 = (ComponentBool*) CompAlloc( mem_op, sizeof( ComponentBool ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnBool ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnBoolContent( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_BOOLEAN);

        return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentEnum ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 592 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentEnum* k, **k2;
       AsnEnum result;
                                                                          
        k = (ComponentEnum*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentEnum**) v;
                *k2 = (ComponentEnum*) CompAlloc( mem_op, sizeof( ComponentEnum ) );
              if ( k ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnEnum ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnEnumContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result;

        k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k  ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentEnum;
        k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentEnum;
        k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentEnum;
       k->comp_desc->cd_free = (comp_free_func*)NULL;
        k->comp_desc->cd_extract_i = NULL;
        k->comp_desc->cd_type = ASN_BASIC;
        k->comp_desc->cd_type_id = BASICTYPE_ENUMERATED;
        k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentEnum;

       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentIA5String ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 661 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentIA5String* k, **k2;
       IA5String result;
                                                                          
        k = (ComponentIA5String*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentIA5String**) v;
                *k2 = (ComponentIA5String*) CompAlloc( mem_op, sizeof( ComponentIA5String ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecIA5String ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecIA5StringContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result;

        k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentIA5String;
        k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentIA5String;
        k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentIA5String;
       k->comp_desc->cd_free = (comp_free_func*)FreeComponentIA5String;
        k->comp_desc->cd_extract_i = NULL;
        k->comp_desc->cd_type = ASN_BASIC;
        k->comp_desc->cd_type_id = BASICTYPE_IA5_STR;
        k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentIA5String;

       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentIA5StringTag ( void mem_op,
GenBuf *  b,
void v,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 656 of file componentlib.c.

                                                                                               {
       return BDecComponentIA5String ( mem_op, b, 0, 0, v, bytesDecoded, mode|CALL_TAG_DECODER );
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentInt ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 787 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentInt* k, **k2;
       AsnInt result;
                                                                          
        k = (ComponentInt*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentInt**) v;
                *k2 = (ComponentInt*) CompAlloc( mem_op, sizeof( ComponentInt ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnInt ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnIntContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       k->value = result;

       k->comp_desc = get_component_description (BASICTYPE_INTEGER );
        
        return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentNull ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 907 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentNull* k, **k2;
       AsnNull result;

        k = (ComponentNull*) v;
                                                                         
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentNull**) v;
                *k2 = (ComponentNull*) CompAlloc( mem_op, sizeof( ComponentNull ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnNull ( mem_op, b, &result, bytesDecoded );
       }
       else {
              rc = BDecAsnNullContent ( mem_op, b, tagId, len, &result, bytesDecoded);
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;

       k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentNull;
       k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentNull;
       k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentNull;
       k->comp_desc->cd_free = (comp_free_func*)FreeComponentNull;
       k->comp_desc->cd_extract_i = NULL;
       k->comp_desc->cd_type = ASN_BASIC;
       k->comp_desc->cd_type_id = BASICTYPE_NULL;
       k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentNull;
       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentNullTag ( void mem_op,
GenBuf *  b,
void v,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 901 of file componentlib.c.

{
       return BDecComponentNull ( mem_op, b, 0, 0, v,bytesDecoded, mode|CALL_TAG_DECODER );
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentNumericString ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 963 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentNumericString* k, **k2;
       NumericString result;

        k = (ComponentNumericString*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentNumericString**) v;
                *k2 = (ComponentNumericString*) CompAlloc( mem_op, sizeof( ComponentNumericString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecNumericString ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecNumericStringContent ( mem_op, b, tagId, len, &result, bytesDecoded);
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;

        k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentNumericString;
        k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentNumericString;
        k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentNumericString;
       k->comp_desc->cd_free = (comp_free_func*)FreeComponentNumericString;
        k->comp_desc->cd_extract_i = NULL;
        k->comp_desc->cd_type = ASN_BASIC;
        k->comp_desc->cd_type_id = BASICTYPE_NUMERIC_STR;
        k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentNumericString;

       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentOcts ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1111 of file componentlib.c.

{
        char *peek_head, *data;
        int i, strLen, rc;
        void* component_values;
        ComponentOcts* k, **k2;
       AsnOcts result;
                                                                          
        k = (ComponentOcts*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentOcts**) v;
                *k2 = (ComponentOcts*) CompAlloc( mem_op, sizeof( ComponentOcts ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnOcts ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnOctsContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;

        k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentOcts;
        k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentOcts;
        k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentOcts;
       k->comp_desc->cd_free = (comp_free_func*)FreeComponentOcts;
        k->comp_desc->cd_extract_i = NULL;
        k->comp_desc->cd_type = ASN_BASIC;
        k->comp_desc->cd_type_id = BASICTYPE_OCTETSTRING;
        k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentOcts;
       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentOctsTag ( void mem_op,
GenBuf *  b,
void v,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1106 of file componentlib.c.

                                                                                          {
       return BDecComponentOcts ( mem_op, b, 0, 0, v, bytesDecoded, mode|CALL_TAG_DECODER );
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentOid ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1286 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentOid* k, **k2;
       AsnOid result;
                                                                          
        k = (ComponentOid*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentOid**) v;
                *k2 = (ComponentOid*) CompAlloc( mem_op, sizeof( ComponentOid ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       
       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnOid ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnOidContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;

       k->comp_desc = get_component_description (BASICTYPE_OID);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentPrintableString ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1332 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentPrintableString* k, **k2;
       AsnOid result;
                                                                          
        k = (ComponentPrintableString*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentPrintableString**) v;
                *k2 = (ComponentPrintableString*) CompAlloc( mem_op, sizeof( ComponentPrintableString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ) {
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecPrintableString ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecPrintableStringContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;

       k->comp_desc = get_component_description (BASICTYPE_PRINTABLE_STR);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentPrintableStringTag ( void mem_op,
GenBuf *  b,
void v,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1326 of file componentlib.c.

{
       return BDecComponentPrintableString ( mem_op, b, 0, 0, v, bytesDecoded, mode|CALL_TAG_DECODER );
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentReal ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1488 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentReal* k, **k2;
       AsnReal result;
                                                                          
        k = (ComponentReal*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentReal**) v;
                *k2 = (ComponentReal*) CompAlloc( mem_op, sizeof( ComponentReal ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnReal ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnRealContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_REAL);

        return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentRelativeOid ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1602 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentRelativeOid* k, **k2;
       AsnRelativeOid result;
                                                                          
        k = (ComponentRelativeOid*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentRelativeOid**) v;
                *k2 = (ComponentRelativeOid*) CompAlloc( mem_op, sizeof( ComponentRelativeOid ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       
       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecAsnRelativeOid ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecAsnRelativeOidContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_OID);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentTeletexString ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void v,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1377 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentTeletexString* k, **k2;
       AsnOid result;
                                                                          
        k = (ComponentTeletexString*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentTeletexString**) v;
                *k2 = (ComponentTeletexString*) CompAlloc( mem_op, sizeof( ComponentTeletexString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( mode & CALL_TAG_DECODER ) {
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecTeletexString ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecTeletexStringContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;

       k->comp_desc = get_component_description (BASICTYPE_T61_STR);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentTeletexStringTag ( void mem_op,
GenBuf *  b,
void v,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1371 of file componentlib.c.

{
       return BDecComponentTeletexString ( mem_op, b, 0, 0, v, bytesDecoded, mode|CALL_TAG_DECODER );
}

Here is the call graph for this function:

Here is the caller graph for this function:

int BDecComponentUniversalString ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1674 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentUniversalString* k, **k2;
       UniversalString result;

        k = (ComponentUniversalString*) v;

        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentUniversalString**) v;
                *k2 = (ComponentUniversalString*) CompAlloc( mem_op, sizeof( ComponentUniversalString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       
       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecUniversalString ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecUniversalStringContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_UNIVERSAL_STR);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentUTF8String ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 306 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentUTF8String* k, **k2;
       UTF8String result;
                                                                          
        k = (ComponentUTF8String*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentUTF8String**) v;
                *k2 = (ComponentUTF8String*) CompAlloc( mem_op, sizeof( ComponentUTF8String ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       
       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecUTF8String ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecUTF8StringContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       if ( rc < 0 ) {
              if ( k ) CompFree( mem_op,  k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_UTF8_STR);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int BDecComponentVisibleString ( void mem_op,
GenBuf *  b,
AsnTag  tagId,
AsnLen  len,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1716 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentVisibleString* k, **k2;
       VisibleString result;
                                                                          
        k = (ComponentVisibleString*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentVisibleString**) v;
                *k2 = (ComponentVisibleString*) CompAlloc( mem_op, sizeof( ComponentVisibleString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       
       if ( mode & CALL_TAG_DECODER ){
              mode = mode & CALL_CONTENT_DECODER;
              rc = BDecVisibleString ( mem_op, b, &result, bytesDecoded );
       } else {
              rc = BDecVisibleStringContent ( mem_op, b, tagId, len, &result, bytesDecoded );
       }
       k->value = result;
       k->comp_desc = get_component_description (BASICTYPE_VISIBLE_STR);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int CheckSelectTypeCorrect ( void mem_op,
ComponentAnyInfo v,
struct berval select 
)

Definition at line 1751 of file componentlib.c.

                                                                                      {
       int strLen;
       AttributeType* ad_type;
       char* oid;
       char* result;

       if ( IsNumericOid ( select->bv_val , select->bv_len ) ) {
              oid = select->bv_val;
              strLen = select->bv_len;
       } else {
              ad_type = at_bvfind( select );

              if ( !ad_type )
                     return LDAP_DECODING_ERROR;

              oid = ad_type->sat_atype.at_oid;
              strLen = strlen ( oid );
       }
       result = EncodeComponentOid ( mem_op, oid , &strLen );
       if ( !result || strLen <= 0 ) return (-1);

       if ( cai->oid.octetLen == strLen &&
              strncmp ( cai->oid.octs, result, strLen ) == 0 )
              return (1);
       else
              return (-1);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void* comp_nibble_memory_allocator ( int  init_mem,
int  inc_mem 
)

Definition at line 716 of file init.c.

                                                           {
       void* nm;
       nm = (void*)InitNibbleMemLocal( (unsigned long)init_mem, (unsigned long)inc_mem );
       if ( !nm ) return NULL;
       else return (void*)nm;
}

Here is the caller graph for this function:

Definition at line 2333 of file componentlib.c.

                                                                           {
       int rc, pos = 0;
       out->bv_val = (char*)malloc( INITIAL_DN_SIZE );
       out->bv_len = INITIAL_DN_SIZE;

       rc = ConvertRelativeDistinguishedName2RFC2253 ( in, out , &pos);
       if ( rc != LDAP_SUCCESS ) return rc;
       out->bv_val[pos] = '\0';
       out->bv_len = pos;
       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int ConvertRDNSequence2RFC2253 ( irRDNSequence in,
struct berval out 
)

Definition at line 2346 of file componentlib.c.

                                                                    {
       irRelativeDistinguishedName* rdn_seq;
       AsnList* seq = &in->comp_list;
       int pos = 0, rc ;

       out->bv_val = (char*)malloc( INITIAL_DN_SIZE );
       out->bv_len = INITIAL_DN_SIZE;

       FOR_EACH_LIST_ELMT( rdn_seq, seq )
       {
              rc = ConvertRelativeDistinguishedName2RFC2253( rdn_seq, out, &pos );
              if ( rc != LDAP_SUCCESS ) return LDAP_INVALID_SYNTAX;

              if ( out->bv_len < pos + 1/*for ','*/ )
                     increment_bv_mem_by_size ( out, INCREMENT_SIZE );
              /*Between RDN, put comma*/
              out->bv_val[pos++] = ',';
       }
       pos--;/*remove the last '+'*/
       out->bv_val[pos] = '\0';
       out->bv_len =pos;
       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

Definition at line 1980 of file componentlib.c.

                                     {
       if ( any->cai != NULL && any->cai->Free != NULL ) {
              any->cai->Free( any->value );
              free ( ((ComponentSyntaxInfo*)any->value)->csi_comp_desc );
              free ( any->value );
       }
       else
              Asn1Error ("ERROR - ANY Free routine is NULL\n");
}

Here is the caller graph for this function:

Definition at line 1014 of file componentlib.c.

                                      {
       FreeAsnOcts( &v->value );
}

Here is the caller graph for this function:

int GDecComponentAny ( void mem_op,
GenBuf *  b,
ComponentAny result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1904 of file componentlib.c.

                                                                                                  {
        ComponentAny *k, **k2;
                                                                          
        k = (ComponentAny*) result;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentAny**) result;
                *k2 = (ComponentAny*) CompAlloc( mem_op, sizeof( ComponentAny ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       if ((result->cai != NULL) && (result->cai->GSER_Decode != NULL)) {
              result->value = (void*) CompAlloc ( mem_op, result->cai->size );
              if ( !result->value ) return 0;
              result->cai->GSER_Decode ( mem_op, b, result->value, (int*)bytesDecoded, DEC_ALLOC_MODE_1);
              k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
              if ( !k->comp_desc )  {
                     if ( k ) CompFree ( mem_op, k );
                     return LDAP_DECODING_ERROR;
              }
              k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentAny;
              k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentAny;
              k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentAny;
              k->comp_desc->cd_free = (comp_free_func*)FreeComponentAny;
              k->comp_desc->cd_type = ASN_BASIC;
              k->comp_desc->cd_extract_i = NULL;
              k->comp_desc->cd_type_id = BASICTYPE_ANY;
              k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentAny;
              return LDAP_SUCCESS;
       }
       else {
              Asn1Error ("ERROR - ANY Decode routine is NULL\n");
              return 0;
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

int GDecComponentBits ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 83 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentBits* k, **k2;
       GAsnBits result;

        k = (ComponentBits*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentBits**) v;
                *k2 = (ComponentBits*) CompAlloc( mem_op, sizeof( ComponentBits ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
        
       if ( GDecAsnBitsContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree( mem_op,  k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_BITSTRING);

       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int GDecComponentBMPString ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 173 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentBMPString* k, **k2;
       GBMPString result;
                                                                          
        k = (ComponentBMPString*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentBMPString**) v;
                *k2 = (ComponentBMPString*) CompAlloc( mem_op, sizeof( ComponentBMPString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

        *bytesDecoded = 0;

       if ( GDecBMPStringContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree( mem_op, k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_BMP_STR);
 
       return LDAP_SUCCESS;

}

Here is the caller graph for this function:

int GDecComponentBool ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 430 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        ComponentBool* k, **k2;
       GAsnBool result;
                                                                          
        k = (ComponentBool*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentBool**) v;
                *k2 = (ComponentBool*) CompAlloc( mem_op, sizeof( ComponentBool ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( GDecAsnBoolContent( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_BOOLEAN);
 
        return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int GDecComponentEnum ( void mem_op,
GenBuf *  a,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 541 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentEnum* k, **k2;
       GAsnEnum result;
                                                                          
        k = (ComponentEnum*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentEnum**) v;
                *k2 = (ComponentEnum*) CompAlloc( mem_op, sizeof( ComponentEnum ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( GDecAsnEnumContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }

       k->value_identifier.bv_val = result.value_identifier;
       k->value_identifier.bv_len = result.len;

       k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentEnum;
       k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentEnum;
       k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentEnum;
       k->comp_desc->cd_free = (comp_free_func*)NULL;
       k->comp_desc->cd_extract_i = NULL;
       k->comp_desc->cd_type = ASN_BASIC;
       k->comp_desc->cd_type_id = BASICTYPE_ENUMERATED;
       k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentEnum;

       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int GDecComponentInt ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 751 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentInt* k, **k2;
       GAsnInt result;
                                                                          
        k = (ComponentInt*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentInt**) v;
                *k2 = (ComponentInt*) CompAlloc( mem_op, sizeof( ComponentInt ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( GDecAsnIntContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_INTEGER );

        return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int GDecComponentNull ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 857 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentNull* k, **k2;
       GAsnNull result;
                                                                          
        k = (ComponentNull*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentNull**) v;
                *k2 = (ComponentNull*) CompAlloc( mem_op, sizeof( ComponentNull ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( GDecAsnNullContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result.value;

       k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentNull;
       k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentNull;
       k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentNull;
       k->comp_desc->cd_free = (comp_free_func*)FreeComponentNull;
       k->comp_desc->cd_extract_i = NULL;
       k->comp_desc->cd_type = ASN_BASIC;
       k->comp_desc->cd_type_id = BASICTYPE_NULL;
       k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentNull;

       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int GDecComponentOcts ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1062 of file componentlib.c.

{
        char *peek_head, *data;
        int i, j, strLen;
        void* component_values;
        ComponentOcts* k, **k2;
       GAsnOcts result;
                                                                          
        k = (ComponentOcts*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentOcts**) v;
                *k2 = (ComponentOcts*) CompAlloc( mem_op, sizeof( ComponentOcts ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( GDecAsnOctsContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result.value;

       k->comp_desc = CompAlloc( mem_op, sizeof( ComponentDesc ) );
       if ( !k->comp_desc )  {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->comp_desc->cd_gser_encoder = (encoder_func*)GEncComponentOcts;
       k->comp_desc->cd_gser_decoder = (gser_decoder_func*)GDecComponentOcts;
       k->comp_desc->cd_ber_decoder = (ber_decoder_func*)BDecComponentOcts;
       k->comp_desc->cd_free = (comp_free_func*)FreeComponentOcts;
       k->comp_desc->cd_extract_i = NULL;
       k->comp_desc->cd_type = ASN_BASIC;
       k->comp_desc->cd_type_id = BASICTYPE_OCTETSTRING;
       k->comp_desc->cd_all_match = (allcomponent_matching_func*)MatchingComponentOcts;

       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int GDecComponentOid ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1239 of file componentlib.c.

{
        char* peek_head;
        int i, strLen, rc;
        void* component_values;
        ComponentOid* k, **k2;
       GAsnOid result;
                                                                          
        k = (ComponentOid*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentOid**) v;
                *k2 = (ComponentOid*) CompAlloc( mem_op, sizeof( ComponentOid ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       strLen = LocateNextGSERToken ( mem_op, b, &peek_head, GSER_PEEK );
       if ( IsNumericOid ( peek_head , strLen ) >= 1 ) {
              /* numeric-oid */
              if ( GDecAsnOidContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
                     if ( k ) CompFree ( mem_op, k );
                     return LDAP_DECODING_ERROR;
              }
       }
       else {
              /*descr*/
              if ( GDecAsnDescOidContent ( mem_op, b, &result, bytesDecoded ) < 0 ){
                     if ( k ) CompFree ( mem_op, k );
                     return LDAP_DECODING_ERROR;
              }
       }
       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_OID);

       return LDAP_SUCCESS;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int GDecComponentReal ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1452 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentReal* k, **k2;
       GAsnReal result;
                                                                          
        k = (ComponentReal*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentReal**) v;
                *k2 = (ComponentReal*) CompAlloc( mem_op, sizeof( ComponentReal ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

       if ( GDecAsnRealContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_REAL);

        return LDAP_SUCCESS;
}
int GDecComponentRelativeOid ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1566 of file componentlib.c.

{
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentRelativeOid* k, **k2;
       GAsnRelativeOid result;
                                                                          
        k = (ComponentRelativeOid*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentRelativeOid**) v;
                *k2 = (ComponentRelativeOid*) CompAlloc( mem_op, sizeof( ComponentRelativeOid ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }
       
       if ( GDecAsnRelativeOidContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree ( mem_op, k );
              return LDAP_DECODING_ERROR;
       }
       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_OID);

       return LDAP_SUCCESS;
}
int GDecComponentTeletexString ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 359 of file componentlib.c.

                                                                   {
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentTeletexString* k, **k2;
       GTeletexString result;
                                                                          
        k = (ComponentTeletexString*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentTeletexString**) v;
                *k2 = (ComponentTeletexString*)CompAlloc( mem_op, sizeof( ComponentTeletexString ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

        *bytesDecoded = 0;

       if ( GDecTeletexStringContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree( mem_op,  k );
              return LDAP_DECODING_ERROR;
       }

       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_VIDEOTEX_STR);
 
       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int GDecComponentUniversalString ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 1658 of file componentlib.c.

{
       if ( GDecComponentUTF8String ( mem_op, b, v, bytesDecoded, mode) < 0 )
       UTF8toUniversalString( ((ComponentUniversalString*)v)->value.octs, ((ComponentUniversalString*)v)->value.octetLen );
              return LDAP_DECODING_ERROR;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int GDecComponentUTF8String ( void mem_op,
GenBuf *  b,
void result,
AsnLen *  bytesDecoded,
int  mode 
)

Definition at line 267 of file componentlib.c.

                                                            {
        char* peek_head;
        int i, strLen;
        void* component_values;
        ComponentUTF8String* k, **k2;
       GUTF8String result;
                                                                          
        k = (ComponentUTF8String*) v;
                                                                          
        if ( mode & DEC_ALLOC_MODE_0 ) {
                k2 = (ComponentUTF8String**) v;
                *k2 = (ComponentUTF8String*)CompAlloc( mem_op, sizeof( ComponentUTF8String ) );
              if ( !*k2 ) return LDAP_DECODING_ERROR;
                k = *k2;
        }

        *bytesDecoded = 0;

       if ( GDecUTF8StringContent ( mem_op, b, &result, bytesDecoded ) < 0 ) {
              if ( k ) CompFree( mem_op,  k );
              return LDAP_DECODING_ERROR;
       }
       
       k->value = result.value;
       k->comp_desc = get_component_description (BASICTYPE_UTF8_STR);
 
       return LDAP_SUCCESS;
}

Here is the caller graph for this function:

int GEncComponentAny ( GenBuf *  b,
ComponentAny comp_any 
)

Definition at line 1813 of file componentlib.c.

{
       if ( in->cai != NULL  && in->cai->Encode != NULL )
              return in->cai->Encode(b, &in->value );
       else
              return (-1);
}

Here is the caller graph for this function:

int GEncComponentBits ( GenBuf *  b,
ComponentBits bits 
)

Definition at line 68 of file componentlib.c.

{
       GAsnBits bits = {0};

       bits.value = in->value;
       if ( !in )
              return (-1);
       return GEncAsnBitsContent ( b, &bits);
}
int GEncComponentBMPString ( GenBuf *  b,
ComponentBMPString bmp 
)

Definition at line 159 of file componentlib.c.

{
       GBMPString t = {0};

       if ( !in || in->value.octetLen <= 0 )
              return (-1);
       t.value = in->value;
       return GEncBMPStringContent ( b, &t );
}
int GEncComponentBool ( GenBuf *  b,
ComponentBool bool 
)

Definition at line 416 of file componentlib.c.

{
       GAsnBool t = {0};

       if ( !in )
              return (-1);
       t.value = in->value;
       return GEncAsnBoolContent ( b, &t );
}
int GEncComponentEnum ( GenBuf *  b,
ComponentEnum comp_enum 
)

Definition at line 527 of file componentlib.c.

{
       GAsnEnum t = {0};

       if ( !in )
              return (-1);
       t.value = in->value;
       return GEncAsnEnumContent ( b, &t );
}

Here is the caller graph for this function:

int GEncComponentGeneralizedTime ( GenBuf *  b,
ComponentGeneralizedTime gen_time 
)
int GEncComponentInt ( GenBuf *  b,
ComponentInt comp_int 
)

Definition at line 737 of file componentlib.c.

{
       GAsnInt t = {0};

       if ( !in )
              return (-1);
       t.value = in->value;
       return GEncAsnIntContent ( b, &t );
}
int GEncComponentNull ( GenBuf *  b,
ComponentNull comp_null 
)

Definition at line 843 of file componentlib.c.

{
       GAsnNull t = {0};

       if ( !in )
              return (-1);
       t.value = in->value;
       return GEncAsnNullContent ( b, &t );
}

Here is the caller graph for this function:

int GEncComponentOcts ( GenBuf *  b,
ComponentOcts octs 
)

Definition at line 1048 of file componentlib.c.

{
       GAsnOcts t = {0};
       if ( !in || in->value.octetLen <= 0 )
              return (-1);

       t.value = in->value;
       return GEncAsnOctsContent ( b, &t );
}

Here is the caller graph for this function:

int GEncComponentOid ( GenBuf *  b,
ComponentOid oid 
)

Definition at line 1186 of file componentlib.c.

{
       GAsnOid t = {0};

       if ( !in || in->value.octetLen <= 0 )
              return (-1);
       t.value = in->value;
       return GEncAsnOidContent( b, (GAsnOcts*)&t );
}
int GEncComponentReal ( GenBuf *  b,
ComponentReal comp_real 
)

Definition at line 1439 of file componentlib.c.

{
       GAsnReal t = {0};
       if ( !in )
              return (-1);
       t.value = in->value;
       return GEncAsnRealContent ( b, &t );
}
int GEncComponentRelativeOid ( GenBuf *  b,
ComponentRelativeOid r_oid 
)

Definition at line 1552 of file componentlib.c.

{
       GAsnRelativeOid t = {0};

       if ( !in || in->value.octetLen <= 0 )
              return (-1);
       t.value = in->value;
       return GEncAsnRelativeOidContent ( b , (GAsnOcts*)&t );
}
int GEncComponentTeletexString ( GenBuf *  b,
ComponentTeletexString tel_str 
)

Definition at line 345 of file componentlib.c.

{
       GTeletexString t = {0};

       if ( !in || in->value.octetLen <= 0 )
              return (-1);
       t.value = in->value;
       return GEncTeletexStringContent ( b, &t );
}

Definition at line 1639 of file componentlib.c.

{
       GUniversalString t = {0};
       if ( !in || in->value.octetLen <= 0 )
              return (-1);
       t.value = in->value;
       return GEncUniversalStringContent( b, &t );
}
int GEncComponentUTF8String ( GenBuf *  b,
ComponentUTF8String utf_str 
)

Definition at line 254 of file componentlib.c.

{
       GUTF8String t = {0};
       if ( !in || in->value.octetLen <= 0 )
              return (-1);
       t.value = in->value;
       return GEncUTF8StringContent ( b, &t );
}
ComponentDesc* get_ComponentDesc ( int  id)
int increment_bv_mem ( struct berval in)
void InstallAnyByComponentInt ( int  anyId,
ComponentInt  intId,
unsigned int  size,
EncodeFcn  encode,
gser_decoder_func *  G_decode,
ber_tag_decoder_func  B_decode,
ExtractFcn  extract,
MatchFcn  match,
FreeFcn  free,
PrintFcn  print 
)
void InstallAnyByComponentOid ( int  anyId,
AsnOid *  oid,
unsigned int  size,
EncodeFcn  encode,
gser_decoder_func *  G_decode,
ber_tag_decoder_func *  B_decode,
ExtractFcn  extract,
MatchFcn  match,
FreeFcn  free,
PrintFcn  print 
)

Definition at line 2130 of file componentlib.c.

{
       ComponentAnyInfo *a;
       Hash h;

       a = (ComponentAnyInfo*) malloc (sizeof (ComponentAnyInfo));
       a->anyId = anyId;
       if ( oid ) {
              a->oid.octs = malloc( oid->octetLen );
              memcpy ( a->oid.octs, oid->octs, oid->octetLen );
              a->oid.octetLen = oid->octetLen;
       }
       a->size = size;
       a->Encode = encode;
       a->GSER_Decode = G_decode;
       a->BER_Decode = B_decode;
       a->Match = match;
       a->Extract = extract;
       a->Free = free;
       a->Print = print;

       h = MakeHash (oid->octs, oid->octetLen);

       if (anyOidHashTblG == NULL)
              anyOidHashTblG = InitHash();

       if(anyOidHashTblG != NULL)
              Insert(anyOidHashTblG, a, h);
}

Here is the caller graph for this function:

int intToAscii ( int  value,
char *  buf 
)

Definition at line 283 of file init.c.

                                       {
       int minus=0,i,temp;
       int total_num_digits;

       if ( value == 0 ){
              buf[0] = '0';
              return 1;
       }

       if ( value < 0 ){
              minus = 1;
              value = value*(-1);
              buf[0] = '-';
       }
       
       /* How many digits */
       for ( temp = value, total_num_digits=0 ; temp ; total_num_digits++ )
              temp = temp/10;

       total_num_digits += minus;

       for ( i = minus ; value ; i++ ) {
              buf[ total_num_digits - i - 1 ]= (char)(value%10 + '0');
              value = value/10;
       }
       return i;
}

Here is the caller graph for this function:

void m_convert_asn_to_ldap ( ComponentSyntaxInfo *  csi,
struct berval bv 
)
int m_convert_assert_to_comp ( gser_decoder_func *  decoder,
struct berval bv,
ComponentSyntaxInfo **  csi,
int  len,
int  mode 
)
void* m_convert_attr_to_comp ( Attribute a,
struct berval bv 
)
int MatchingComponentAny ( char *  oid,
ComponentAny a,
ComponentAny b 
)

Definition at line 1941 of file componentlib.c.

                                                                              {
       void *comp1, *comp2;

       if ( result->comp_desc->cd_type_id == BASICTYPE_ANY )
              comp1 = result->value;
       else
              comp1 = result;

       if ( result2->comp_desc->cd_type_id == BASICTYPE_ANY )
              comp2 = result2->value;
       else
              comp2 = result2;
              
       if ((result->cai != NULL) && (result->cai->Match != NULL)) {
              if ( result->comp_desc->cd_type_id == BASICTYPE_ANY )
                     return result->cai->Match(oid, comp1, comp2 );
              else if ( result2->comp_desc->cd_type_id == BASICTYPE_ANY )
                     return result2->cai->Match(oid, comp1, comp2);
              else 
                     return LDAP_INVALID_SYNTAX;
       }
       else {
              Asn1Error ("ERROR - ANY Matching routine is NULL\n");
              return LDAP_INVALID_SYNTAX;
       }
}

Here is the caller graph for this function:

int MatchingComponentBits ( char *  oid,
ComponentSyntaxInfo *  bits1,
ComponentSyntaxInfo *  bits2 
)

Definition at line 37 of file componentlib.c.

{
       int rc;
        MatchingRule* mr;
        ComponentBits *a, *b;
                                                                          
        if ( oid ) {
                mr = retrieve_matching_rule(oid, (AsnTypeId)csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }
        a = ((ComponentBits*)csi_attr);
        b = ((ComponentBits*)csi_assert);
       rc = ( a->value.bitLen == b->value.bitLen && 
              strncmp( a->value.bits,b->value.bits,a->value.bitLen ) == 0 );
        return rc ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int MatchingComponentBool ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 394 of file componentlib.c.

{
        MatchingRule* mr;
        ComponentBool *a, *b;
                                                                          
        if( oid ) {
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }

        a = ((ComponentBool*)csi_attr);
        b = ((ComponentBool*)csi_assert);

        return (a->value == b->value) ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int MatchingComponentEnum ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 504 of file componentlib.c.

{
        int rc;
        MatchingRule* mr;
        ComponentEnum *a, *b;
                                                                          
        if( oid ) {
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }
        a = ((ComponentEnum*)csi_attr);
        b = ((ComponentEnum*)csi_assert);
        rc = (a->value == b->value);
                                                                          
        return rc ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int MatchingComponentInt ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 713 of file componentlib.c.

{
        MatchingRule* mr;
        ComponentInt *a, *b;
                                                                          
        if( oid ) {
                /* check if this ASN type's matching rule is overrided */
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                /* if existing function is overrided, call the overriding
function*/
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }
        a = ((ComponentInt*)csi_attr);
        b = ((ComponentInt*)csi_assert);
                                                                          
        return ( a->value == b->value ) ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int MatchingComponentNull ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 822 of file componentlib.c.

{
        MatchingRule* mr;
        ComponentNull *a, *b;
                                                                          
        if( oid ) {
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }
        a = ((ComponentNull*)csi_attr);
        b = ((ComponentNull*)csi_assert);
                                                                          
        return (a->value == b->value) ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int MatchingComponentOcts ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 1022 of file componentlib.c.

{
        int rc;
        MatchingRule* mr;
        ComponentOcts *a, *b;
                                                                          
        if( oid ) {
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }
        a = (ComponentOcts*) csi_attr;
        b = (ComponentOcts*) csi_assert;
       /* Assume that both of OCTET string has end of string character */
       if ( (a->value.octetLen == b->value.octetLen) &&
              strncmp ( a->value.octs, b->value.octs, a->value.octetLen ) == 0 )
              return LDAP_COMPARE_TRUE;
       else
              return LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int MatchingComponentOid ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 1161 of file componentlib.c.

{
        int rc;
        MatchingRule* mr;
        ComponentOid *a, *b;
                                                                          
        if( oid ) {
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }

        a = (ComponentOid*)csi_attr;
        b = (ComponentOid*)csi_assert;
       if ( a->value.octetLen != b->value.octetLen )
              return LDAP_COMPARE_FALSE;
        rc = ( strncmp( a->value.octs, b->value.octs, a->value.octetLen ) == 0 );
                                                                          
        return rc ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

Here is the caller graph for this function:

int MatchingComponentReal ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 1416 of file componentlib.c.

{
        int rc;
        MatchingRule* mr;
        ComponentReal *a, *b;
                                                                          
        if( oid ) {
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }
        a = (ComponentReal*)csi_attr;
        b = (ComponentReal*)csi_assert;
        rc = (a->value == b->value);
                                                                          
        return rc ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

int MatchingComponentRelativeOid ( char *  oid,
ComponentSyntaxInfo *  a,
ComponentSyntaxInfo *  b 
)

Definition at line 1525 of file componentlib.c.

{
        int rc;
        MatchingRule* mr;
        ComponentRelativeOid *a, *b;
                                                                          
        if( oid ) {
                mr = retrieve_matching_rule(oid, csi_attr->csi_comp_desc->cd_type_id );
                if ( mr )
                        return component_value_match( mr, csi_attr , csi_assert );
        }

        a = (ComponentRelativeOid*)csi_attr;
        b = (ComponentRelativeOid*)csi_assert;

       if ( a->value.octetLen != b->value.octetLen )
              return LDAP_COMPARE_FALSE;
        rc = ( strncmp( a->value.octs, b->value.octs, a->value.octetLen ) == 0 );
                                                                          
        return rc ? LDAP_COMPARE_TRUE:LDAP_COMPARE_FALSE;
}

Here is the call graph for this function:

MatchingRule* retrieve_matching_rule ( char *  mr_oid,
AsnTypeId  type 
)

Definition at line 180 of file init.c.

                                                       {
       char* tmp;
       struct berval mr_name = BER_BVNULL;
       AsnTypetoMatchingRuleTable* atmr;

       for ( atmr = gATMR_table ; atmr ; atmr = atmr->atmr_table_next ) {
              if ( strcmp( atmr->atmr_oid, mr_oid ) == 0 ) {
                     tmp = atmr->atmr_table[type].atmr_mr_name;
                     if ( tmp ) {
                            mr_name.bv_val = tmp;
                            mr_name.bv_len = strlen( tmp );
                            return mr_bvfind ( &mr_name );
                     }
              }
       }
       return (MatchingRule*)NULL;
}

Here is the call graph for this function:

Here is the caller graph for this function:

OidDecoderMapping* RetrieveOidDecoderMappingbyBV ( struct berval in)

Definition at line 2054 of file componentlib.c.

                                                   {
       if ( IsNumericOid ( in->bv_val, in->bv_len ) )
              return RetrieveOidDecoderMappingbyOid( in->bv_val, in->bv_len );
       else
              return RetrieveOidDecoderMappingbyDesc( in->bv_val, in->bv_len );
}

Here is the call graph for this function:

Here is the caller graph for this function:

OidDecoderMapping* RetrieveOidDecoderMappingbyDesc ( char *  desc,
int  desc_len 
)

Definition at line 2094 of file componentlib.c.

                                                            {
       Hash hash;
       void *anyInfo;
       AsnOid oid;
       AttributeType* ad_type;
       struct berval bv;
       void* mem_op;

       bv.bv_val = desc;
       bv.bv_len = desc_len;
       ad_type = at_bvfind( &bv );

       oid.octs = ad_type->sat_atype.at_oid;
       oid.octetLen = strlen ( oid.octs );

       if ( !ad_type )
              return (OidDecoderMapping*) NULL;

       mem_op = comp_nibble_memory_allocator ( 128, 16 );

       oid.octs = EncodeComponentOid ( mem_op, oid.octs , (int*)&oid.octetLen );
       if( oid.octetLen <= 0 ) {
              comp_nibble_memory_free( mem_op );
              return (OidDecoderMapping*) NULL;
       }
       
       /* use encoded oid as hash string */
       hash = MakeHash ( oid.octs, oid.octetLen);
       comp_nibble_memory_free( mem_op );
       if (CheckForAndReturnValue (anyOidHashTblG, hash, &anyInfo))
              return (OidDecoderMapping*) anyInfo;
       else
              return (OidDecoderMapping*) NULL;

}

Here is the call graph for this function:

Here is the caller graph for this function:

OidDecoderMapping* RetrieveOidDecoderMappingbyOid ( char *  ch_oid,
int  oid_len 
)

Definition at line 2065 of file componentlib.c.

                                                            {
       Hash hash;
       void *anyInfo;
       AsnOid oid;
       int strLen;
       void* mem_op;

       mem_op = comp_nibble_memory_allocator ( 128, 16 );
       oid.octs = EncodeComponentOid ( mem_op, ch_oid, &oid_len);
       oid.octetLen = oid_len;
       if( oid_len <= 0 ) {
              comp_nibble_memory_free( mem_op );
              return NULL;
       }
       
       /* use encoded oid as hash string */
       hash = MakeHash ( oid.octs, oid.octetLen);
       comp_nibble_memory_free( mem_op );
       if (CheckForAndReturnValue (anyOidHashTblG, hash, &anyInfo))
              return (OidDecoderMapping*) anyInfo;
       else
              return (OidDecoderMapping*) NULL;

}

Here is the call graph for this function:

Here is the caller graph for this function:


Variable Documentation

Definition at line 45 of file asn_to_syn_mr.c.

Definition at line 166 of file asn_to_syn_mr.c.

Definition at line 88 of file asn_to_syn_mr.c.

Definition at line 129 of file asn_to_syn_mr.c.