Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
openldap
OpenLDAP
Commits
7a4e70f3
Commit
7a4e70f3
authored
Mar 21, 2021
by
Howard Chu
Browse files
ITS#8577 don't allow setting logDB to current DB
parent
696d5656
Pipeline
#2155
passed with stage
in 51 minutes and 6 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
servers/slapd/overlays/accesslog.c
View file @
7a4e70f3
...
...
@@ -941,6 +941,14 @@ log_cf_gen(ConfigArgs *c)
c
->
log
,
c
->
cr_msg
,
c
->
value_dn
.
bv_val
);
rc
=
1
;
}
if
(
!
rc
&&
(
li
->
li_db
->
bd_self
==
c
->
be
->
bd_self
))
{
snprintf
(
c
->
cr_msg
,
sizeof
(
c
->
cr_msg
),
"<%s> invalid suffix, points to itself"
,
c
->
argv
[
0
]
);
Debug
(
LDAP_DEBUG_ANY
,
"%s: %s
\"
%s
\"\n
"
,
c
->
log
,
c
->
cr_msg
,
c
->
value_dn
.
bv_val
);
rc
=
1
;
}
ch_free
(
c
->
value_ndn
.
bv_val
);
}
else
{
li
->
li_db_suffix
=
c
->
value_ndn
;
...
...
@@ -2413,6 +2421,11 @@ accesslog_db_open(
"accesslog:
\"
logdb <suffix>
\"
missing or invalid.
\n
"
);
return
1
;
}
if
(
li
->
li_db
->
bd_self
==
be
->
bd_self
)
{
Debug
(
LDAP_DEBUG_ANY
,
"accesslog:
\"
logdb <suffix>
\"
is this database, cannot log to itself.
\n
"
);
return
1
;
}
if
(
slapMode
&
SLAP_TOOL_MODE
)
return
0
;
...
...
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