{ LDAP_CONTROL_SYNC,
SLAP_CTRL_HIDE|SLAP_CTRL_SEARCH, NULL,
parseLDAPsync, LDAP_SLIST_ENTRY_INITIALIZER(next) },
+#ifdef LDAP_CONTROL_MODIFY_INCREMENT
{ LDAP_CONTROL_MODIFY_INCREMENT,
SLAP_CTRL_HIDE|SLAP_CTRL_MODIFY, NULL,
parseModifyIncrement, LDAP_SLIST_ENTRY_INITIALIZER(next) },
+#endif
{ LDAP_CONTROL_MANAGEDSAIT,
SLAP_CTRL_ACCESS, NULL,
parseManageDSAit, LDAP_SLIST_ENTRY_INITIALIZER(next) },
{
int rc;
char buf[ SLAP_LDAPDN_MAXLEN ];
- struct berval id = { ctrl->ldctl_value.bv_len, (char *)buf },
+ struct berval id,
user = { 0, NULL },
realm = { 0, NULL },
mech = { 0, NULL };
+ if ( sizeof( buf ) <= ctrl->ldctl_value.bv_len ) {
+ return LDAP_INVALID_SYNTAX;
+ }
+
+ id.bv_len = ctrl->ldctl_value.bv_len;
+ id.bv_val = buf;
strncpy( buf, ctrl->ldctl_value.bv_val, sizeof( buf ) );
rc = slap_parse_user( &id, &user, &realm, &mech );
#endif
static struct berval supportedFeatures[] = {
- BER_BVC(LDAP_FEATURE_ALL_OPERATIONAL_ATTRS), /* All Op Attrs (+) */
- BER_BVC(LDAP_FEATURE_OBJECTCLASS_ATTRS), /* OCs in Attrs List (+person) */
- BER_BVC(LDAP_FEATURE_ABSOLUTE_FILTERS), /* (&) and (|) search filters */
+ BER_BVC(LDAP_FEATURE_ALL_OP_ATTRS), /* All Op Attrs (+) */
+ BER_BVC(LDAP_FEATURE_OBJECTCLASS_ATTRS), /* OCs in Attrs List (@class) */
+ BER_BVC(LDAP_FEATURE_ABSOLUTE_FILTERS), /* (&) and (|) search filters */
BER_BVC(LDAP_FEATURE_LANGUAGE_TAG_OPTIONS), /* Language Tag Options */
- BER_BVC(LDAP_FEATURE_LANGUAGE_RANGE_OPTIONS), /* Language Range Options */
+ BER_BVC(LDAP_FEATURE_LANGUAGE_RANGE_OPTIONS),/* Language Range Options */
+
#ifdef LDAP_DEVEL
- BER_BVC(LDAP_FEATURE_MODIFY_INCREMENT), /* Modify/increment */
+ BER_BVC(LDAP_FEATURE_SUBORDINATE_SCOPE), /* "children" search scope */
+ BER_BVC(LDAP_FEATURE_MODIFY_INCREMENT), /* Modify/increment */
#endif
{0,NULL}
};