tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
Subject [Bug 56352] New: tomcat-connectors-1.2.39-windows-x86_64-iis does not resolve worked DNS names
Date Sat, 05 Apr 2014 14:21:57 GMT

            Bug ID: 56352
           Summary: tomcat-connectors-1.2.39-windows-x86_64-iis does not
                    resolve worked DNS names
           Product: Tomcat Connectors
           Version: 1.2.39
          Hardware: PC
            Status: NEW
          Severity: normal
          Priority: P2
         Component: isapi

Following the "tomcat-connectors-1.2.39-windows-x86_64-iis does not work"
thread on users list, from April 2rd

It boils down to the following:
The following works:


The following does not work:


and connector tries to connect to
jk_open_socket::jk_connect.c (735): connect to failed (errno=49)

Looking at svn history, I see that implementation of method jk_resolve() was
changed in r1529803 for the case when APR library is not available.

Reviewing the code of jk_resolve() in jk_connect.c, I see the following issue:
line 484
 memcpy(&(saddr->sa), ai->ai_addr, ai->ai_addrlen);

The "ai" variable is a pointer to the chosen item in "ai_list" linked list of
addresses returned by getaddrinfo(). The bug is that freeaddrinfo(ai_list) is
called too early, before the information is copied away.

Also, the following on lines 436-441:
        if (prefer_ipv6)
            hints.ai_family = JK_INET6;
            hints.ai_family = JK_INET;
As "hints" is a structure that is passed to getaddrinfo() method, I would
expect those assignments to use AF_INET, AF_INET6. I suspect that this is
non-issue, as those defines should be defined as equal to AF_xx constants
anyway, but other code later uses AF_xx constants, so I expect the AF_xx ones
to be used here as well.
("if (ai->ai_family == AF_INET6)")

You are receiving this mail because:
You are the assignee for the bug.

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message