OpenPKG CVS Repository
http://cvs.openpkg.org/
____________________________________________________________________________
Server: cvs.openpkg.org Name: Ralf S. Engelschall
Root: /e/openpkg/cvs Email: [EMAIL PROTECTED]
Module: openpkg-src Date: 18-Oct-2004 20:01:33
Branch: HEAD Handle: 2004101819013200
Modified files:
openpkg-src/jabberd jabberd.patch jabberd.spec
Log:
upgrading package: jabberd 2.0s3 -> 2.0s4
Summary:
Revision Changes Path
1.5 +67 -291 openpkg-src/jabberd/jabberd.patch
1.25 +2 -2 openpkg-src/jabberd/jabberd.spec
____________________________________________________________________________
patch -p0 <<'@@ .'
Index: openpkg-src/jabberd/jabberd.patch
============================================================================
$ cvs diff -u -r1.4 -r1.5 jabberd.patch
--- openpkg-src/jabberd/jabberd.patch 13 Oct 2004 19:14:09 -0000 1.4
+++ openpkg-src/jabberd/jabberd.patch 18 Oct 2004 18:01:32 -0000 1.5
@@ -1,26 +1,49 @@
-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>
+Index: c2s/authreg_ldap.c
+--- c2s/authreg_ldap.c.orig 2004-04-26 07:47:19 +0200
++++ c2s/authreg_ldap.c 2004-10-18 19:57:24 +0200
+@@ -70,6 +70,24 @@
+ return ld_errno;
+ }
- #ifdef HAVE_NETINET_IN_H
- # include <netinet/in.h>
-@@ -107,6 +108,7 @@
++/** 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)
{
- int size;
- struct pfree *cleanup;
-+ struct pfree *cleanup_tail;
- struct pheap *heap;
- #ifdef POOL_DEBUG
- char name[8], zone[32];
+@@ -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)));
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
+--- etc/c2s.xml.dist.in.orig 2004-04-26 07:47:21 +0200
++++ etc/c2s.xml.dist.in 2004-10-18 19:57:24 +0200
@@ -46,18 +46,16 @@
</router>
@@ -62,8 +85,8 @@
<!-- 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
+--- etc/resolver.xml.dist.in.orig 2003-10-30 00:30:06 +0100
++++ etc/resolver.xml.dist.in 2004-10-18 19:57:24 +0200
@@ -46,18 +46,16 @@
</router>
@@ -87,8 +110,8 @@
<!-- 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
+--- etc/router.xml.dist.in.orig 2003-10-23 02:43:56 +0200
++++ etc/router.xml.dist.in 2004-10-18 19:57:24 +0200
@@ -9,24 +9,22 @@
<pidfile>@localstatedir@/jabberd/pid/router.pid</pidfile>
@@ -119,8 +142,8 @@
<!-- 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
+--- etc/s2s.xml.dist.in.orig 2004-04-25 12:28:29 +0200
++++ etc/s2s.xml.dist.in 2004-10-18 19:57:24 +0200
@@ -56,25 +56,23 @@
</router>
@@ -152,8 +175,8 @@
<!-- 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
+--- etc/sm.xml.dist.in.orig 2004-04-02 06:34:17 +0200
++++ etc/sm.xml.dist.in 2004-10-18 19:57:24 +0200
@@ -49,24 +49,22 @@
</router>
@@ -183,127 +206,12 @@
<!-- 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)));
-Index: s2s/main.c
---- s2s/main.c.orig 2004-05-31 23:31:05 +0200
-+++ s2s/main.c 2004-10-13 19:44:00 +0200
-@@ -62,7 +62,7 @@
-
- /** pull values out of the config file */
- static void _s2s_config_expand(s2s_t s2s) {
-- char *str, secret[40];
-+ char *str, secret[41];
- int i, r;
-
- s2s->id = config_get_one(s2s->config, "id", 0);
-Index: scod/mech_plain.c
---- scod/mech_plain.c.orig 2004-05-31 23:31:06 +0200
-+++ scod/mech_plain.c 2004-10-13 19:44:03 +0200
-@@ -63,7 +63,7 @@
- }
- c++;
-
-- pass = (char *) malloc(sizeof(char) * (resplen - ((int) (c - resp))));
-+ pass = (char *) malloc(sizeof(char) * (resplen - ((int) (c - resp)) + 1));
- strncpy(pass, c, (resplen - ((int) (c - resp))));
- pass[resplen - ((int) (c - resp))] = '\0';
-
-Index: sm/mod_announce.c
---- sm/mod_announce.c.orig 2004-05-31 23:31:05 +0200
-+++ sm/mod_announce.c 2004-10-13 19:44:20 +0200
-@@ -45,9 +45,13 @@
- os_t os;
- os_object_t o;
- os_type_t ot;
-+ nad_t nad;
- int ns, elem, attr;
- char timestamp[18], telem[5];
-- struct tm tm = { 0, 0, 0, 0, 0, 0, 0, 0, 0 };
-+ struct tm tm;
-+
-+ /* struct tm can vary in size depending on platform */
-+ memset(&tm, 0, sizeof(struct tm));
-
- data->loaded = 1;
-
-@@ -55,7 +59,9 @@
- if((ret = storage_get(mod->mm->sm->st, "motd-message", mod->mm->sm->id, NULL,
&os)) == st_SUCCESS) {
- os_iter_first(os);
- o = os_iter_object(os);
-- if(os_object_get(o, "xml", (void **) &data->nad, &ot)) {
-+ if(os_object_get(o, "xml", (void **) &nad, &ot)) {
-+ /* Copy the nad, as the original is freed when the os is freed below */
-+ data->nad = nad_copy(nad);
- if((ns = nad_find_scoped_namespace(data->nad, uri_DELAY, NULL)) >= 0 &&
- (elem = nad_find_elem(data->nad, 1, ns, "x", 1)) >= 0 &&
- (attr = nad_find_attr(data->nad, elem, -1, "stamp", NULL)) >= 0) {
-@@ -197,6 +203,9 @@
- os_object_t o;
- st_ret_t ret;
-
-+ /* time of this packet */
-+ t = time(NULL);
-+
- /* we want messages addressed to /announce */
- if(pkt->type != pkt_MESSAGE || strlen(pkt->to->resource) < 8 ||
strncmp(pkt->to->resource, "announce", 8) != 0)
- return mod_PASS;
-@@ -212,7 +221,7 @@
-
- store = pkt_dup(pkt, NULL, NULL);
-
-- pkt_delay(store, time(NULL), mod->mm->sm->id);
-+ pkt_delay(store, t, mod->mm->sm->id);
-
- /* prepare for storage */
- os = os_new();
Index: sm/mod_roster.c
---- sm/mod_roster.c.orig 2004-05-31 23:31:05 +0200
-+++ sm/mod_roster.c 2004-10-13 19:44:09 +0200
-@@ -567,6 +567,9 @@
- if(user->sessions == NULL)
- return mod_PASS;
+--- sm/mod_roster.c.orig 2004-10-05 06:34:10 +0200
++++ sm/mod_roster.c 2004-10-18 19:57:35 +0200
+@@ -570,6 +570,9 @@
+ /* We have to free old packet - Lemming's memory leak fix */
+ pkt_free(pkt);
+ /* We have to free old packet - Lemming's memory leak fix */
+ pkt_free(pkt);
@@ -311,147 +219,15 @@
/* build a new packet to push out to everyone */
pkt = pkt_create(user->sm, "iq", "set", NULL, NULL);
ns = nad_add_namespace(pkt->nad, uri_ROSTER, NULL);
-Index: sm/pkt.c
---- sm/pkt.c.orig 2004-05-31 23:31:05 +0200
-+++ sm/pkt.c 2004-10-13 19:44:27 +0200
-@@ -352,12 +352,24 @@
- jid_free(pkt->rto);
- pkt->rto = jid_new(pkt->sm->pc, pkt->to->domain, 0);
-
-+ if(pkt->rto == NULL) {
-+ log_debug(ZONE, "invalid to address on packet, unable to route");
-+ pkt_free(pkt);
-+ return;
-+ }
-+
- nad_set_attr(pkt->nad, 0, -1, "to", pkt->rto->domain, 0);
-
- if(pkt->rfrom != NULL)
- jid_free(pkt->rfrom);
- pkt->rfrom = jid_new(pkt->sm->pc, pkt->sm->id, 0);
-
-+ if(pkt->rfrom == NULL) {
-+ log_debug(ZONE, "invalid from address on packet, unable to route");
-+ pkt_free(pkt);
-+ return;
-+ }
-+
- nad_set_attr(pkt->nad, 0, -1, "from", pkt->rfrom->domain, 0);
-
- ret = mm_out_router(pkt->sm->mm, pkt);
-Index: sx/io.c
---- sx/io.c.orig 2004-05-31 23:31:05 +0200
-+++ sx/io.c 2004-10-13 19:43:49 +0200
-@@ -106,7 +106,7 @@
- }
-
- /* hand it to the app */
-- if(plugin_error == 0)
-+ if ((plugin_error == 0) && (s->state < state_CLOSING))
- _sx_event(s, event_PACKET, (void *) nad);
- }
-
-Index: sx/ssl.c
---- sx/ssl.c.orig 2004-05-31 23:31:06 +0200
-+++ sx/ssl.c 2004-10-13 19:44:30 +0200
-@@ -347,7 +347,42 @@
- _sx_buffer_alloc_margin(buf, 0, pending);
-
- ret = SSL_read(sc->ssl, &(buf->data[buf->len]), pending);
-- if(ret <= 0) {
-+
-+ if (ret == 0)
-+ {
-+ /* ret will equal zero if the SSL stream was closed.
-+ (See the SSL_read manpage.) */
-+
-+ /* If the SSL Shutdown happened properly,
-+ (i.e. we got an SSL "close notify")
-+ then proccess the last packet recieved. */
-+ if (SSL_get_shutdown(sc->ssl) == SSL_RECEIVED_SHUTDOWN)
-+ {
-+ _sx_close(s);
-+ break;
-+ }
-+
-+ /* If the SSL stream was just closed and not shutdown,
-+ drop the last packet recieved.
-+ WARNING: This may cause clients that use SSLv2 and
-+ earlier to not log out properly. */
-+
-+ err = SSL_get_error(sc->ssl, ret);
-+
-+ _sx_buffer_clear(buf);
-+
-+
-+ if(err == SSL_ERROR_ZERO_RETURN) {
-+ /* ssl channel closed, we're done */
-+ _sx_close(s);
-+ }
-+
-+ return -1;
-+ }
-+ else if(ret < 0) {
-+ /* ret will be negative if the SSL stream needs
-+ more data, or if there was a SSL error.
-+ (See the SSL_read manpage.) */
- err = SSL_get_error(sc->ssl, ret);
-
- /* ssl block incomplete, need more */
-@@ -360,11 +395,6 @@
- /* something's wrong */
- _sx_buffer_clear(buf);
-
-- if(err == SSL_ERROR_ZERO_RETURN) {
-- /* ssl channel closed, we're done */
-- _sx_close(s);
-- return -1;
-- }
-
- /* !!! need checks for renegotiation */
-
-Index: util/nad.c
---- util/nad.c.orig 2004-10-13 19:43:53 +0200
-+++ util/nad.c 2004-10-13 19:44:35 +0200
-@@ -734,7 +734,7 @@
- for(ns = nad->elems[elem].ns; ns >= 0; ns = nad->nss[ns].next)
- {
- /* never explicitly declare the implicit xml namespace */
-- if(nad->nss[ns].lprefix == strlen(uri_XML) && strncmp(uri_XML, nad->cdata
+ nad->nss[ns].iprefix, nad->nss[ns].lprefix) == 0)
-+ if(nad->nss[ns].luri == strlen(uri_XML) && strncmp(uri_XML, nad->cdata +
nad->nss[ns].iuri, nad->nss[ns].luri) == 0)
- continue;
-
- /* make space */
-Index: util/xhash.c
---- util/xhash.c.orig 2004-05-31 23:31:06 +0200
-+++ util/xhash.c 2004-10-13 19:44:38 +0200
-@@ -71,7 +71,7 @@
- xhn n;
- int i = index % h->prime;
- for(n = &h->zen[i]; n != NULL; n = n->next)
-- if(n->key != NULL && strncmp(key, n->key, len) == 0)
-+ if(n->key != NULL && (strlen(n->key)==len) && (strncmp(key, n->key, len)
== 0))
- return n;
- return NULL;
- }
-Index: util/pool.c
---- util/pool.c.orig 2004-05-31 23:31:06 +0200
-+++ util/pool.c 2004-10-13 19:43:56 +0200
-@@ -85,13 +85,14 @@
- if(p->cleanup == NULL)
- {
- p->cleanup = pf;
-+ p->cleanup_tail = pf;
- return;
- }
-
-- /* fast forward to end of list */
-- for(cur = p->cleanup; cur->next != NULL; cur = cur->next);
--
-+ /* append at end of list */
-+ cur = p->cleanup_tail;
- cur->next = pf;
-+ p->cleanup_tail = pf;
- }
+Index: util/util.h
+--- util/util.h.orig 2004-10-05 06:27:50 +0200
++++ util/util.h 2004-10-18 19:57:24 +0200
+@@ -30,6 +30,8 @@
+ #include <time.h>
+ #include <errno.h>
+ #include <assert.h>
++#include <sys/types.h>
++#include <sys/socket.h>
- /** create a cleanup tracker */
+ #ifdef HAVE_NETINET_IN_H
+ # include <netinet/in.h>
@@ .
patch -p0 <<'@@ .'
Index: openpkg-src/jabberd/jabberd.spec
============================================================================
$ cvs diff -u -r1.24 -r1.25 jabberd.spec
--- openpkg-src/jabberd/jabberd.spec 13 Oct 2004 19:14:09 -0000 1.24
+++ openpkg-src/jabberd/jabberd.spec 18 Oct 2004 18:01:32 -0000 1.25
@@ -25,7 +25,7 @@
# package version
%define V_major 2.0
-%define V_minor s3
+%define V_minor s4
# package information
Name: jabberd
@@ -38,7 +38,7 @@
Group: Network
License: JOSL/GPL
Version: %{V_major}%{V_minor}
-Release: 20041013
+Release: 20041018
# package options
%option with_mysql no
@@ .
______________________________________________________________________
The OpenPKG Project www.openpkg.org
CVS Repository Commit List [EMAIL PROTECTED]