| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221 |
- Index: util/util.h
- --- util/util.h.orig 2004-05-31 23:31:06 +0200
- +++ util/util.h 2004-09-22 21:26:44 +0200
- @@ -30,6 +30,8 @@
- #include <time.h>
- #include <errno.h>
- #include <assert.h>
- +#include <sys/types.h>
- +#include <sys/socket.h>
-
- #ifdef HAVE_NETINET_IN_H
- # include <netinet/in.h>
- Index: etc/c2s.xml.dist.in
- --- etc/c2s.xml.dist.in.orig 2004-04-26 07:42:53 +0200
- +++ etc/c2s.xml.dist.in 2004-09-22 21:48:33 +0200
- @@ -46,18 +46,16 @@
- </router>
-
- <!-- Log configuration - type is "syslog", "file" or "stdout" -->
- - <log type='syslog'>
- + <log type='file'>
- <!-- If logging to syslog, this is the log ident -->
- - <ident>jabberd/c2s</ident>
- + <!-- <ident>jabberd/c2s</ident> -->
-
- <!-- If logging to syslog, this is the log facility
- (local0 - local7) [default: local3] -->
- - <facility>local3</facility>
- + <!-- <facility>local3</facility> -->
-
- <!-- If logging to file, this is the filename of the logfile -->
- - <!--
- <file>@localstatedir@/jabberd/log/c2s.log</file>
- - -->
- </log>
-
- <!-- Local network configuration -->
- @@ -78,7 +76,7 @@
- <!-- <id realm='company'>localhost</id> -->
-
- <!-- IP address to bind to (default: 0.0.0.0) -->
- - <ip>0.0.0.0</ip>
- + <ip>127.0.0.1</ip>
-
- <!-- Port to bind to, or 0 to disable unencrypted access to the
- server (default: 5222) -->
- @@ -206,7 +204,7 @@
- <!-- Authentication/registration database configuration -->
- <authreg>
- <!-- Backend module to use -->
- - <module>mysql</module>
- + <module>db</module>
-
- <!-- Registration configuration -->
- <register>
- Index: etc/resolver.xml.dist.in
- --- etc/resolver.xml.dist.in.orig 2004-04-01 06:56:55 +0200
- +++ etc/resolver.xml.dist.in 2004-09-22 21:48:58 +0200
- @@ -46,18 +46,16 @@
- </router>
-
- <!-- Log configuration - type is "syslog", "file" or "stdout" -->
- - <log type='syslog'>
- + <log type='file'>
- <!-- If logging to syslog, this is the log ident -->
- - <ident>jabberd/resolver</ident>
- + <!-- <ident>jabberd/resolver</ident> -->
-
- <!-- If logging to syslog, this is the log facility
- (local0 - local7) [default: local3] -->
- - <facility>local3</facility>
- + <!-- <facility>local3</facility> -->
-
- <!-- If logging to file, this is the filename of the logfile -->
- - <!--
- <file>@localstatedir@/jabberd/log/resolver.log</file>
- - -->
- </log>
-
- <!-- SRV records will be resolved in the following order. The first
- Index: etc/router.xml.dist.in
- --- etc/router.xml.dist.in.orig 2004-04-01 06:56:55 +0200
- +++ etc/router.xml.dist.in 2004-09-22 21:49:28 +0200
- @@ -9,24 +9,22 @@
- <pidfile>@localstatedir@/jabberd/pid/router.pid</pidfile>
-
- <!-- Log configuration - type is "syslog", "file" or "stdout" -->
- - <log type='syslog'>
- + <log type='file'>
- <!-- If logging to syslog, this is the log ident -->
- - <ident>jabberd/router</ident>
- + <!-- <ident>jabberd/router</ident> -->
-
- <!-- If logging to syslog, this is the log facility
- (local0 - local7) [default: local3] -->
- - <facility>local3</facility>
- + <!-- <facility>local3</facility> -->
-
- <!-- If logging to file, this is the filename of the logfile -->
- - <!--
- <file>@localstatedir@/jabberd/log/router.log</file>
- - -->
- </log>
-
- <!-- Local network configuration -->
- <local>
- <!-- IP address to bind to (default: 0.0.0.0) -->
- - <ip>0.0.0.0</ip>
- + <ip>127.0.0.1</ip>
-
- <!-- Port to bind to (default: 5347) -->
- <port>5347</port>
- Index: etc/s2s.xml.dist.in
- --- etc/s2s.xml.dist.in.orig 2004-04-21 15:29:27 +0200
- +++ etc/s2s.xml.dist.in 2004-09-22 21:50:02 +0200
- @@ -56,25 +56,23 @@
- </router>
-
- <!-- Log configuration - type is "syslog", "file" or "stdout" -->
- - <log type='syslog'>
- + <log type='file'>
- <!-- If logging to syslog, this is the log ident -->
- - <ident>jabberd/s2s</ident>
- + <!-- <ident>jabberd/s2s</ident> -->
-
- <!-- If logging to syslog, this is the log facility
- (local0 - local7) [default: local3] -->
- - <facility>local3</facility>
- + <!-- <facility>local3</facility> -->
-
- <!-- if logging to file, this is the filename of the logfile -->
- - <!--
- <file>@localstatedir@/jabberd/log/s2s.log</file>
- - -->
- </log>
-
- <!-- Local network configuration -->
- <local>
- <!-- IP and port to listen for incoming s2s connections on
- (default: 0.0.0.0, 5269) -->
- - <ip>0.0.0.0</ip>
- + <ip>127.0.0.1</ip>
- <port>5269</port>
-
- <!-- Helper DNS resolver component - if this component is not
- Index: etc/sm.xml.dist.in
- --- etc/sm.xml.dist.in.orig 2004-04-02 06:32:31 +0200
- +++ etc/sm.xml.dist.in 2004-09-22 21:50:56 +0200
- @@ -49,24 +49,22 @@
- </router>
-
- <!-- Log configuration - type is "syslog", "file" or "stdout" -->
- - <log type='syslog'>
- + <log type='file'>
- <!-- If logging to syslog, this is the log ident -->
- - <ident>jabberd/sm</ident>
- + <!-- <ident>jabberd/sm</ident> -->
-
- <!-- If logging to syslog, this is the log facility
- (local0 - local7) [default: local3] -->
- - <facility>local3</facility>
- + <!-- <facility>local3</facility> -->
-
- <!-- If logging to file, this is the filename of the logfile -->
- - <!--
- <file>@localstatedir@/jabberd/log/sm.log</file>
- - -->
- </log>
-
- <!-- Storage database configuration -->
- <storage>
- <!-- By default, we use the MySQL driver for all storage -->
- - <driver>mysql</driver>
- + <driver>db</driver>
-
- <!-- Its also possible to explicitly list alternate drivers for
- specific data types. -->
- Index: c2s/authreg_ldap.c
- --- c2s/authreg_ldap.c.orig 2004-05-31 23:31:05 +0200
- +++ c2s/authreg_ldap.c 2004-10-03 18:56:15 +0200
- @@ -70,6 +70,24 @@
- return ld_errno;
- }
-
- +/** entry-point function to be called when following referrals.
- + this forces a re-bind, since Active Directory required you to
- + re-bind this makes it work with M$ Windows AD.
- + -- Juan F Arjona (jfarjona at jfarjona.com). */
- +static int rebindProc(LDAP *ld, LDAP_CONST char *url, ber_tag_t request, ber_int_t msgid, void *mdata)
- +{
- + moddata_t data = mdata;
- + data->ld = ld;
- + if (ldap_simple_bind_s(data->ld, data->binddn, data->bindpw)) {
- + log_write(data->ar->c2s->log, LOG_ERR, "ldap: bind failed(to %s): %s",
- + url, ldap_err2string(_ldap_get_lderrno(data->ld)));
- + ldap_unbind_s(data->ld);
- + data->ld = NULL;
- + return NULL;
- + }
- + return LDAP_SUCCESS;
- +}
- +
- /** connect to the ldap host */
- static int _ldap_connect(moddata_t data)
- {
- @@ -151,6 +169,14 @@
-
- snprintf(filter, 1024, "(%s=%s)", data->uidattr, username);
-
- + if (ldap_set_rebind_proc(data->ld, &rebindProc,data) ) {
- + log_write(data->ar->c2s->log, LOG_ERR, "ldap: set_rebind_proc failed: %s",
- + ldap_err2string(_ldap_get_lderrno(data->ld)));
- + ldap_unbind_s(data->ld);
- + data->ld = NULL;
- + return NULL;
- + }
- +
- if(ldap_search_s(data->ld, basedn, LDAP_SCOPE_SUBTREE, filter, no_attrs, 0, &result))
- {
- log_write(data->ar->c2s->log, LOG_ERR, "ldap: search %s failed: %s", filter, ldap_err2string(_ldap_get_lderrno(data->ld)));
|