prob with head

From: Andres Kroonmaa <andre@dont-contact.us>
Date: Fri, 18 Oct 2002 21:06:21 +0300

 Tried head today, crashes on me, after some 1-5 minutes of good run.

 ./configure --enable-dlmalloc --enable-xmalloc-statistics --enable-storeio=ufs,diskd,coss
 --enable-delay-pools --enable-snmp --enable-cache-digests --enable-err-language=Estonian
 --enable-underscores --disable-wccp --with-aio --enable-forw-via-db --enable-gnuregex
 --enable-cpu-profiling

 Do I understand right that someone is trying to use some sort of proxy-auth?
 There's nothing in my setup about any of auth modules..

    proxy_auth_msg = authenticateAuthUserRequestMessage(
         (http->conn && http->conn->auth_user_request) ? http->conn-> auth_user_request :
            http->request->auth_user_request);

 both http->conn->auth_user_request and http->request are 0x0 below.

Program received signal SIGSEGV, Segmentation fault.
0x806b9b6 in clientAccessCheckDone (answer=1, data=0x85417e8) at client_side_request.c:226
226 proxy_auth_msg = authenticateAuthUserRequestMessage((http->conn
(gdb) bt
#0 0x806b9b6 in clientAccessCheckDone (answer=1, data=0x85417e8) at client_side_request.c:226
#1 0x80505ee in aclCheckCallback (checklist=0x8503270, answer=ACCESS_ALLOWED) at acl.c:1874
#2 0x80503eb in aclCheck (checklist=0x8503270) at acl.c:1831
#3 0x8050631 in aclLookupDstIPDone (ia=0x8326820, data=0x8503270) at acl.c:1906
#4 0x809a47d in ipcacheCallback (i=0x8326810) at ipcache.c:227
#5 0x809a96b in ipcacheHandleReply (data=0x8506cb0, answers=0x8666100, na=9) at ipcache.c:385
#6 0x80767f4 in idnsGrokReply (buf=0x8139c60 "\001\205\201\200", sz=310) at dns_internal.c:485
#7 0x8076ad5 in idnsRead (fd=6, data=0x0) at dns_internal.c:557
#8 0x8070063 in comm_check_incoming_poll_handlers (nfds=1, fds=0x80373f8) at comm_poll.c:245
#9 0x80710d9 in comm_poll_dns_incoming () at comm_poll.c:553
#10 0x8070ede in comm_select (msec=2) at comm_poll.c:513
#11 0x809d6e5 in main (argc=2, argv=0x80478e8) at main.c:717
(gdb) l 226
221 char *proxy_auth_msg = NULL;
222 debug(85, 2) ("The request %s %s is %s, because it matched '%s'\n",
223 RequestMethodStr[http->request->method], http->uri,
224 answer == ACCESS_ALLOWED ? "ALLOWED" : "DENIED",
225 AclMatchedName ? AclMatchedName : "NO ACL's");
226 proxy_auth_msg = authenticateAuthUserRequestMessage((http->conn
227 && http->conn->auth_user_request) ? http->conn->
228 auth_user_request : http->request->auth_user_request);
229 context->acl_checklist = NULL;
230 if (answer == ACCESS_ALLOWED) {
(gdb) p http
$1 = (clientHttpRequest *) 0x853838c
(gdb) p *http
$2 = {conn = 0x852e7c8, request = 0x0, uri = 0x0, log_uri = 0x0, out = {offset = 0, size = 0, headers_sz = 0}, range_iter = {
    pos = 0, spec = 0x0, debt_size = 0, prefix_size = 0, boundary = {size = 0, len = 0, buf = 0x0}}, req_sz = 93,
  entry = 0x0, old_entry = 0x0, logType = LOG_TAG_NONE, start = {tv_sec = 1034961202, tv_usec = 18847}, http_ver = {
    major = 1, minor = 0}, al = {url = 0x0, http = {method = METHOD_NONE, code = 0, content_type = 0x0, version = {
        major = 0, minor = 0}}, icp = {opcode = ICP_INVALID}, cache = {caddr = {S_un = {S_un_b = {s_b1 = 0 '\000',
            s_b2 = 0 '\000', s_b3 = 0 '\000', s_b4 = 0 '\000'}, S_un_w = {s_w1 = 0, s_w2 = 0}, S_addr = 0}}, size = 0,
      code = LOG_TAG_NONE, msec = 0, rfc931 = 0x0, authuser = 0x0}, headers = {request = 0x0, reply = 0x0}, _private = {
      method_str = 0x0}, hier = {code = HIER_NONE, host = '\000' <repeats 255 times>, ping = {start = {tv_sec = 0,
          tv_usec = 0}, stop = {tv_sec = 0, tv_usec = 0}, n_sent = 0, n_recv = 0, n_replies_expected = 0, timeout = 0,
        timedout = 0, w_rtt = 0, p_rtt = 0}, cd_host = '\000' <repeats 255 times>, alg = PEER_SA_NONE,
      cd_lookup = LOOKUP_NONE, n_choices = 0, n_ichoices = 0, peer_select_start = {tv_sec = 0, tv_usec = 0},
      store_complete_stop = {tv_sec = 0, tv_usec = 0}}}, flags = {accel = 0, internal = 0, done_copying = 0, purging = 0},
  redirect = {status = HTTP_STATUS_NONE, location = 0x0}, active = {data = 0x853838c, prev = 0x0, next = 0x0},
  client_stream = {head = 0x853dec8, tail = 0x853dec8}}

(gdb) p *http->conn
$3 = {fd = 43, in = {buf = 0xdf486008 "\bðHß", notYetUsed = 0, allocatedSize = 4096}, body = {size_left = 0, request = 0x0,
    buf = 0x0, bufsize = 0, callback = 0, cbdata = 0x0}, auth_type = AUTH_UNKNOWN, auth_user_request = 0x0,
  currentobject = 0x0, peer = {sin_family = 2, sin_port = 4614, sin_addr = {S_un = {S_un_b = {s_b1 = 213 'Õ',
          s_b2 = 180 '´', s_b3 = 18 '\022', s_b4 = 114 'r'}, S_un_w = {s_w1 = 46293, s_w2 = 29202}, S_addr = 1913828565}},
    sin_zero = "\000\000\000\000\000\000\000"}, me = {sin_family = 2, sin_port = 20480, sin_addr = {S_un = {S_un_b = {
          s_b1 = 194 'Â', s_b2 = 106 'j', s_b3 = 96 '`', s_b4 = 89 'Y'}, S_un_w = {s_w1 = 27330, s_w2 = 22880},
        S_addr = 1499491010}}, sin_zero = "\000\000\000\000\000\000\000"}, log_addr = {S_un = {S_un_b = {s_b1 = 213 'Õ',
        s_b2 = 180 '´', s_b3 = 18 '\022', s_b4 = 114 'r'}, S_un_w = {s_w1 = 46293, s_w2 = 29202}, S_addr = 1913828565}},
  rfc931 = '\000' <repeats 63 times>, nrequests = 1, defer = {n = 0, until = 0}}
(gdb) p *http->conn->auth_user_request
Cannot access memory at address 0x0

Program received signal SIGSEGV, Segmentation fault.
0x806b9b6 in clientAccessCheckDone (answer=1, data=0x85417e8) at client_side_request.c:226
226 proxy_auth_msg = authenticateAuthUserRequestMessage((http->conn
(gdb) bt
#0 0x806b9b6 in clientAccessCheckDone (answer=1, data=0x85417e8) at client_side_request.c:226
#1 0x80505ee in aclCheckCallback (checklist=0x8503270, answer=ACCESS_ALLOWED) at acl.c:1874
#2 0x80503eb in aclCheck (checklist=0x8503270) at acl.c:1831
#3 0x8050631 in aclLookupDstIPDone (ia=0x8326b50, data=0x8503270) at acl.c:1906
#4 0x809a47d in ipcacheCallback (i=0x8326b40) at ipcache.c:227
#5 0x809a96b in ipcacheHandleReply (data=0x8506da0, answers=0x85cba70, na=1) at ipcache.c:385
#6 0x80767f4 in idnsGrokReply (buf=0x8139c60 "\002+\201\200", sz=465) at dns_internal.c:485
#7 0x8076ad5 in idnsRead (fd=6, data=0x0) at dns_internal.c:557
#8 0x8070063 in comm_check_incoming_poll_handlers (nfds=1, fds=0x80373f8) at comm_poll.c:245
#9 0x80710d9 in comm_poll_dns_incoming () at comm_poll.c:553
#10 0x8070ede in comm_select (msec=10) at comm_poll.c:513
#11 0x809d6e5 in main (argc=2, argv=0x80478e8) at main.c:717
(gdb) l
221 char *proxy_auth_msg = NULL;
222 debug(85, 2) ("The request %s %s is %s, because it matched '%s'\n",
223 RequestMethodStr[http->request->method], http->uri,
224 answer == ACCESS_ALLOWED ? "ALLOWED" : "DENIED",
225 AclMatchedName ? AclMatchedName : "NO ACL's");
226 proxy_auth_msg = authenticateAuthUserRequestMessage((http->conn
227 && http->conn->auth_user_request) ? http->conn->
228 auth_user_request : http->request->auth_user_request);
229 context->acl_checklist = NULL;
230 if (answer == ACCESS_ALLOWED) {
(gdb) p *http
$9 = {conn = 0x852f0ec, request = 0x0, uri = 0x0, log_uri = 0x0, out = {offset = 0, size = 0, headers_sz = 0}, range_iter = {
    pos = 0, spec = 0x0, debt_size = 0, prefix_size = 0, boundary = {size = 0, len = 0, buf = 0x0}}, req_sz = 390,
  entry = 0x0, old_entry = 0x0, logType = LOG_TAG_NONE, start = {tv_sec = 1034961594, tv_usec = 865328}, http_ver = {
    major = 1, minor = 0}, al = {url = 0x0, http = {method = METHOD_NONE, code = 0, content_type = 0x0, version = {
        major = 0, minor = 0}}, icp = {opcode = ICP_INVALID}, cache = {caddr = {S_un = {S_un_b = {s_b1 = 0 '\000',
            s_b2 = 0 '\000', s_b3 = 0 '\000', s_b4 = 0 '\000'}, S_un_w = {s_w1 = 0, s_w2 = 0}, S_addr = 0}}, size = 0,
      code = LOG_TAG_NONE, msec = 0, rfc931 = 0x0, authuser = 0x0}, headers = {request = 0x0, reply = 0x0}, _private = {
      method_str = 0x0}, hier = {code = HIER_NONE, host = '\000' <repeats 255 times>, ping = {start = {tv_sec = 0,
          tv_usec = 0}, stop = {tv_sec = 0, tv_usec = 0}, n_sent = 0, n_recv = 0, n_replies_expected = 0, timeout = 0,
        timedout = 0, w_rtt = 0, p_rtt = 0}, cd_host = '\000' <repeats 255 times>, alg = PEER_SA_NONE,
      cd_lookup = LOOKUP_NONE, n_choices = 0, n_ichoices = 0, peer_select_start = {tv_sec = 0, tv_usec = 0},
      store_complete_stop = {tv_sec = 0, tv_usec = 0}}}, flags = {accel = 0, internal = 0, done_copying = 0, purging = 0},
  redirect = {status = HTTP_STATUS_NONE, location = 0x0}, active = {data = 0x8539c2c, prev = 0x0, next = 0x0},
  client_stream = {head = 0x853dd30, tail = 0x853dd30}}
(gdb) p *http->conn
$10 = {fd = 40, in = {buf = 0xdf48d008 "\bPHß", notYetUsed = 0, allocatedSize = 4096}, body = {size_left = 0, request = 0x0,
    buf = 0x0, bufsize = 0, callback = 0, cbdata = 0x0}, auth_type = AUTH_UNKNOWN, auth_user_request = 0x0,
  currentobject = 0x0, peer = {sin_family = 2, sin_port = 260, sin_addr = {S_un = {S_un_b = {s_b1 = 62 '>', s_b2 = 65 'A',
          s_b3 = 33 '!', s_b4 = 50 '2'}, S_un_w = {s_w1 = 16702, s_w2 = 12833}, S_addr = 841040190}},
    sin_zero = "\000\000\000\000\000\000\000"}, me = {sin_family = 2, sin_port = 20480, sin_addr = {S_un = {S_un_b = {
          s_b1 = 194 'Â', s_b2 = 106 'j', s_b3 = 96 '`', s_b4 = 89 'Y'}, S_un_w = {s_w1 = 27330, s_w2 = 22880},
        S_addr = 1499491010}}, sin_zero = "\000\000\000\000\000\000\000"}, log_addr = {S_un = {S_un_b = {s_b1 = 62 '>',
        s_b2 = 65 'A', s_b3 = 33 '!', s_b4 = 50 '2'}, S_un_w = {s_w1 = 16702, s_w2 = 12833}, S_addr = 841040190}},
  rfc931 = '\000' <repeats 63 times>, nrequests = 1, defer = {n = 0, until = 0}}

Program received signal SIGSEGV, Segmentation fault.
0xdfb7d4a1 in strlen () from /usr/lib/libc.so.1
(gdb) bt
#0 0xdfb7d4a1 in strlen () from /usr/lib/libc.so.1
#1 0xdfbad686 in _doprnt () from /usr/lib/libc.so.1
#2 0xdfbaf0bb in vsnprintf () from /usr/lib/libc.so.1
#3 0x809fbdd in memBufVPrintf (mb=0x8037160, fmt=0x80fa677 "FTP Reply: %s\r\n", vargs=0x8037128) at MemBuf.c:239
#4 0x809fb0d in memBufPrintf (mb=0x8037160, fmt=0x80fa677 "FTP Reply: %s\r\n") at MemBuf.c:222
#5 0x8078375 in errorDump (err=0x8572a58, mb=0x8117d94) at errorpage.c:467
#6 0x8078ad6 in errorConvert (token=87 'W', err=0x8572a58) at errorpage.c:646
#7 0x8078e20 in errorBuildContent (err=0x8572a58) at errorpage.c:718
#8 0x8078caf in errorBuildReply (err=0x8572a58) at errorpage.c:686
#9 0x8077c49 in errorAppendEntry (entry=0xdf01e598, err=0x8572a58) at errorpage.c:313
#10 0x807c4fb in fwdStateFree (fwdState=0x86baa44) at forward.c:96
#11 0x807c90b in fwdServerClosed (fd=84, data=0x86baa44) at forward.c:175
#12 0x806e6df in commCallCloseHandlers (fd=84) at comm.c:581
#13 0x806e916 in comm_close (fd=84) at comm.c:665
#14 0x8086639 in ftpFailed (ftpState=0xdeb36240, error=ERR_FTP_FAILURE) at ftp.c:2401
#15 0x8083348 in ftpReadControlReply (fd=84, data=0xdeb36240) at ftp.c:1274
#16 0x8070afd in comm_select (msec=10) at comm_poll.c:457
#17 0x809d6e5 in main (argc=2, argv=0x80478e8) at main.c:717
(gdb) up

#3 0x809fbdd in memBufVPrintf (mb=0x8037160, fmt=0x80fa677 "FTP Reply: %s\r\n", vargs=0x8037128) at MemBuf.c:239
239 sz = vsnprintf(mb->buf + mb->size, free_space, fmt, vargs);
(gdb) l
234 assert(!mb->stolen); /* not frozen */
235 /* assert in Grow should quit first, but we do not want to have a scary infinite loop */
236 while (mb->capacity <= mb->max_capacity) {
237 mb_size_t free_space = mb->capacity - mb->size;
238 /* put as much as we can */
239 sz = vsnprintf(mb->buf + mb->size, free_space, fmt, vargs);
240 /* check for possible overflow */
241 /* snprintf on Linuz returns -1 on overflows */
242 /* snprintf on FreeBSD returns at least free_space on overflows */
243 if (sz < 0 || sz >= free_space)
(gdb) p mb
$4 = (MemBuf *) 0x8037160
(gdb) p *mb
$5 = {
  buf = 0x84cab40 "CacheHost: cache1.online.ee\r\nErrPage: ERR_FTP_FAILURE\r\nErr: [none]\r\nTimeStamp: Fri, 18 Oct 2002 17:17:00 GMT\r\n\r\nClientIP:
0.0.0.0\r\n\r\nHTTP Request:\r\nGET /%2f/%2f/video/Shakira-Whenever_Wherever.mpeg HT"...,
  size = 361, max_capacity = 2097152000, capacity = 2048, stolen = 0}
(gdb) p free_space
$6 = 1687
(gdb) p fmt
$7 = 0x80fa677 "FTP Reply: %s\r\n"
(gdb) p vargs
$8 = 0x8037128

------------------------------------
 Andres Kroonmaa <andre@online.ee>
 CTO, Microlink Online
 Tel: 6501 731, Fax: 6501 725
 Pärnu mnt. 158, Tallinn,
 11317 Estonia
Received on Fri Oct 18 2002 - 12:16:06 MDT

This archive was generated by hypermail pre-2.1.9 : Tue Dec 09 2003 - 16:16:57 MST