James Server
  1. James Server
  2. JAMES-271

can't resolve when MX record direct an ip

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.2.0
    • Fix Version/s: 2.2.0
    • Component/s: DNSServer
    • Labels:
      None
    • Environment:
      redhat 7.3
      java version "1.4.1_01"

      Description

      if MX record direct an ip, like this
      "joyes.com. 655 IN MX 10 219.153.1.149."

      james will resolve the ip as an domain(off cause fail),
      and report "ERROR dnsserver: Couldn't resolve IP address for discovered host 219.153.1.149.." in dnsserver*.log.

        Activity

        Liteos created issue -
        Hide
        Liteos added a comment -

        problem code
        ----------------------------------------------
        class: "org.apache.james.dnsserver.DNSServer"
        method: "getSMTPHostAddresses(final String domainName)"
        line: 389
        code: "addrs = org.xbill.DNS.Address.getAllByName(nextHostname);"
        -------------------------------------------------------------------

        if the "nextHostname" is an ip string like "202.105.122.202", the "UnknownHostException" will be throw.

        Show
        Liteos added a comment - problem code ---------------------------------------------- class: "org.apache.james.dnsserver.DNSServer" method: "getSMTPHostAddresses(final String domainName)" line: 389 code: "addrs = org.xbill.DNS.Address.getAllByName(nextHostname);" ------------------------------------------------------------------- if the "nextHostname" is an ip string like "202.105.122.202", the "UnknownHostException" will be throw.
        Hide
        Liteos added a comment -

        the MX record string is "219.153.1.149." , end with ".".
        the java code:
        InetAddress.getAllByName("219.153.1.149.");

        will trow exception on linux.

        Show
        Liteos added a comment - the MX record string is "219.153.1.149." , end with ".". the java code: InetAddress.getAllByName("219.153.1.149."); will trow exception on linux.
        Hide
        Noel J. Bergman added a comment -

        This is a known issue, which has been discussed on the developer list. Apparently, MX records with IP addresses are not in accord with the RFCs. We're discussing how lenient to be, and what problems might arise from more lenient handling of improper MX records.

        Show
        Noel J. Bergman added a comment - This is a known issue, which has been discussed on the developer list. Apparently, MX records with IP addresses are not in accord with the RFCs. We're discussing how lenient to be, and what problems might arise from more lenient handling of improper MX records.
        Noel J. Bergman made changes -
        Field Original Value New Value
        Component/s DNSServer [ 11061 ]
        Noel J. Bergman made changes -
        Fix Version/s 2.2.0RC3 [ 10704 ]
        Noel J. Bergman made changes -
        Affects Version/s 2.2.0RC1 [ 10689 ]
        Hide
        Noel J. Bergman added a comment -

        Fixed in CVS for 2.2.0RC3.

        Show
        Noel J. Bergman added a comment - Fixed in CVS for 2.2.0RC3.
        Noel J. Bergman made changes -
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Closed [ 6 ]
        Mark Thomas made changes -
        Workflow jira [ 31214 ] Default workflow, editable Closed status [ 12565805 ]
        Mark Thomas made changes -
        Workflow Default workflow, editable Closed status [ 12565805 ] jira [ 12581215 ]
        Transition Time In Source Status Execution Times Last Executer Last Execution Date
        Open Open Closed Closed
        10d 11h 6m 1 Noel J. Bergman 07/May/04 20:23

          People

          • Assignee:
            Unassigned
            Reporter:
            Liteos
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development