Skip to content
GitLab
Menu
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Sign in / Register
Toggle navigation
Menu
Open sidebar
Robert Dubner
OpenLDAP
Commits
89d11904
Commit
89d11904
authored
Jan 18, 1999
by
Kurt Zeilenga
Browse files
Import ITS#44 tcp_wrapper connections bug fix from devel.
parent
62cfa792
Changes
1
Show whitespace changes
Inline
Side-by-side
servers/slapd/daemon.c
View file @
89d11904
...
@@ -237,14 +237,9 @@ slapd_daemon(
...
@@ -237,14 +237,9 @@ slapd_daemon(
"FIONBIO ioctl on %d failed
\n
"
,
ns
,
0
,
0
);
"FIONBIO ioctl on %d failed
\n
"
,
ns
,
0
,
0
);
}
}
c
[
ns
].
c_sb
.
sb_sd
=
ns
;
Debug
(
LDAP_DEBUG_CONNS
,
"new connection on %d
\n
"
,
ns
,
Debug
(
LDAP_DEBUG_CONNS
,
"new connection on %d
\n
"
,
ns
,
0
,
0
);
0
,
0
);
pthread_mutex_lock
(
&
ops_mutex
);
c
[
ns
].
c_connid
=
num_conns
++
;
pthread_mutex_unlock
(
&
ops_mutex
);
len
=
sizeof
(
from
);
len
=
sizeof
(
from
);
if
(
getpeername
(
ns
,
(
struct
sockaddr
*
)
&
from
,
&
len
)
if
(
getpeername
(
ns
,
(
struct
sockaddr
*
)
&
from
,
&
len
)
...
@@ -284,9 +279,9 @@ slapd_daemon(
...
@@ -284,9 +279,9 @@ slapd_daemon(
STRING_UNKNOWN
))
STRING_UNKNOWN
))
{
{
/* DENY ACCESS */
/* DENY ACCESS */
Statslog
(
LDAP_DEBUG_
STATS
,
Statslog
(
LDAP_DEBUG_
ANY
,
"
conn=%d
fd=%d connection from %s (%s) denied.
\n
"
,
"fd=%d connection from %s (%s) denied.
\n
"
,
c
[
ns
].
c_connid
,
ns
,
ns
,
client_name
==
NULL
?
"unknown"
:
client_name
,
client_name
==
NULL
?
"unknown"
:
client_name
,
client_addr
==
NULL
?
"unknown"
:
client_addr
,
client_addr
==
NULL
?
"unknown"
:
client_addr
,
0
);
0
);
...
@@ -297,6 +292,11 @@ slapd_daemon(
...
@@ -297,6 +292,11 @@ slapd_daemon(
}
}
#endif
/* HAVE_TCPD */
#endif
/* HAVE_TCPD */
c
[
ns
].
c_sb
.
sb_sd
=
ns
;
pthread_mutex_lock
(
&
ops_mutex
);
c
[
ns
].
c_connid
=
num_conns
++
;
pthread_mutex_unlock
(
&
ops_mutex
);
Statslog
(
LDAP_DEBUG_STATS
,
Statslog
(
LDAP_DEBUG_STATS
,
"conn=%d fd=%d connection from %s (%s) accepted.
\n
"
,
"conn=%d fd=%d connection from %s (%s) accepted.
\n
"
,
c
[
ns
].
c_connid
,
ns
,
c
[
ns
].
c_connid
,
ns
,
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a 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