Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Tero Saarni
OpenLDAP
Commits
796ea09d
Commit
796ea09d
authored
Jun 10, 2010
by
Quanah Gibson-Mount
Browse files
ITS#6570
parent
826bd1a4
Changes
4
Hide whitespace changes
Inline
Side-by-side
CHANGES
View file @
796ea09d
...
...
@@ -5,6 +5,7 @@ OpenLDAP 2.4.23 Engineering
Fixed libldap memleaks (ITS#6568)
Fixed liblutil off-by-one with delta (ITS#6541)
Fixed slapd syncrepl rid logging (ITS#6533)
Fixed slapd modrdn handling of invalid values (ITS#6570)
Fixed slapd-bdb hasSubordinates computation (ITS#6549)
Fixed slapo-ppolicy to use Debug (ITS#6566)
Fixed slapo-rwm to use Debug (ITS#6566)
...
...
servers/slapd/dn.c
View file @
796ea09d
...
...
@@ -302,16 +302,13 @@ LDAPRDN_rewrite( LDAPRDN rdn, unsigned flags, void *ctx )
ava
->
la_attr
=
ad
->
ad_cname
;
if
(
ava
->
la_flags
&
LDAP_AVA_BINARY
)
{
if
(
ava
->
la_value
.
bv_len
==
0
)
{
/* BER encoding is empty */
return
LDAP_INVALID_SYNTAX
;
}
/* AVA is binary encoded, not supported */
return
LDAP_INVALID_SYNTAX
;
/* Do not allow X-ORDERED 'VALUES' naming attributes */
}
else
if
(
ad
->
ad_type
->
sat_flags
&
SLAP_AT_ORDERED_VAL
)
{
return
LDAP_INVALID_SYNTAX
;
/* AVA is binary encoded, don't muck with it */
}
else
if
(
flags
&
SLAP_LDAPDN_PRETTY
)
{
transf
=
ad
->
ad_type
->
sat_syntax
->
ssyn_pretty
;
if
(
!
transf
)
{
...
...
@@ -379,6 +376,10 @@ LDAPRDN_rewrite( LDAPRDN rdn, unsigned flags, void *ctx )
ava
->
la_value
=
bv
;
ava
->
la_flags
|=
LDAP_AVA_FREE_VALUE
;
}
/* reject empty values */
if
(
!
ava
->
la_value
.
bv_len
)
{
return
LDAP_INVALID_SYNTAX
;
}
}
rc
=
LDAP_SUCCESS
;
...
...
servers/slapd/modrdn.c
View file @
796ea09d
...
...
@@ -445,12 +445,19 @@ slap_modrdn2mods(
mod_tmp
->
sml_values
[
1
].
bv_val
=
NULL
;
if
(
desc
->
ad_type
->
sat_equality
->
smr_normalize
)
{
mod_tmp
->
sml_nvalues
=
(
BerVarray
)
ch_malloc
(
2
*
sizeof
(
struct
berval
)
);
(
void
)
(
*
desc
->
ad_type
->
sat_equality
->
smr_normalize
)
(
rs
->
sr_err
=
desc
->
ad_type
->
sat_equality
->
smr_normalize
(
SLAP_MR_EQUALITY
|
SLAP_MR_VALUE_OF_ASSERTION_SYNTAX
,
desc
->
ad_type
->
sat_syntax
,
desc
->
ad_type
->
sat_equality
,
&
mod_tmp
->
sml_values
[
0
],
&
mod_tmp
->
sml_nvalues
[
0
],
NULL
);
if
(
rs
->
sr_err
!=
LDAP_SUCCESS
)
{
ch_free
(
mod_tmp
->
sml_nvalues
);
ch_free
(
mod_tmp
->
sml_values
[
0
].
bv_val
);
ch_free
(
mod_tmp
->
sml_values
);
ch_free
(
mod_tmp
);
goto
done
;
}
mod_tmp
->
sml_nvalues
[
1
].
bv_val
=
NULL
;
}
else
{
mod_tmp
->
sml_nvalues
=
NULL
;
...
...
servers/slapd/schema_init.c
View file @
796ea09d
...
...
@@ -1735,8 +1735,9 @@ UTF8StringNormalize(
?
LDAP_UTF8_APPROX
:
0
;
val
=
UTF8bvnormalize
(
val
,
&
tmp
,
flags
,
ctx
);
/* out of memory or syntax error, the former is unlikely */
if
(
val
==
NULL
)
{
return
LDAP_
OTHER
;
return
LDAP_
INVALID_SYNTAX
;
}
/* collapse spaces (in place) */
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment