mirror of
https://git.openldap.org/openldap/openldap.git
synced 2024-11-27 02:22:00 +08:00
chdir before chroot
This commit is contained in:
parent
84d92d6bb3
commit
b84b838015
1
CHANGES
1
CHANGES
@ -6,6 +6,7 @@ OpenLDAP 2.0.X Engineering
|
|||||||
Updated -lldap SASL error reporting
|
Updated -lldap SASL error reporting
|
||||||
Updated -lldap TLS error reporting
|
Updated -lldap TLS error reporting
|
||||||
Updated slapadd error reporting
|
Updated slapadd error reporting
|
||||||
|
Updated slapd chroot handling (ITS#810)
|
||||||
Added slapd numericString indexing
|
Added slapd numericString indexing
|
||||||
Build Environment
|
Build Environment
|
||||||
Fixed make comment bug (ITS#811)
|
Fixed make comment bug (ITS#811)
|
||||||
|
@ -301,10 +301,17 @@ int main( int argc, char **argv )
|
|||||||
}
|
}
|
||||||
|
|
||||||
#if defined(HAVE_CHROOT)
|
#if defined(HAVE_CHROOT)
|
||||||
if ( sandbox && chroot( sandbox ) ) {
|
if ( sandbox ) {
|
||||||
perror("chroot");
|
if ( chdir( sandbox ) ) {
|
||||||
rc = 1;
|
perror("chdir");
|
||||||
goto stop;
|
rc = 1;
|
||||||
|
goto stop;
|
||||||
|
}
|
||||||
|
if ( chroot( sandbox ) ) {
|
||||||
|
perror("chroot");
|
||||||
|
rc = 1;
|
||||||
|
goto stop;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user