James Server
  1. James Server
  2. JAMES-286

Exceeding maximum value with MAIL SIZE causes NullPointerException

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: 2.2.0
    • Fix Version/s: 2.3.0
    • Component/s: SMTPServer
    • Labels:
      None

      Description

      There is a fairly simple problem with the doMailSize() method in SMTPHandler. When a MAIL FROM command is received with a SIZE value that exceeds the maxmessagesize value, the server sends a 552 response. It then attempts to log a message about the incident, and calls state.get(SENDER).toString() to form part of the log message.

      Unfortuntely, state.put(SENDER, senderAddress) is only called later when the MAIL command is processed. Creating the log statement thus causes an NPE and the connection aborts.

      The easy solution is to take this information out of the log message. I apologize for not including a patch, but I have lost track of which branch to patch against. However, I believe this problem is present in RC3.

        Activity

        Mark Thomas made changes -
        Workflow Default workflow, editable Closed status [ 12566744 ] jira [ 12582249 ]
        Mark Thomas made changes -
        Workflow jira [ 31487 ] Default workflow, editable Closed status [ 12566744 ]
        Danny Angus made changes -
        Status Resolved [ 5 ] Closed [ 6 ]
        Hide
        Danny Angus added a comment -

        Closing issue fixed in released version.

        Show
        Danny Angus added a comment - Closing issue fixed in released version.
        Stefano Bagnara made changes -
        Field Original Value New Value
        Assignee Stefano Bagnara [ bago ]
        Resolution Fixed [ 1 ]
        Status Open [ 1 ] Resolved [ 5 ]
        Fix Version/s 2.3.0 [ 10690 ]
        Hide
        Stefano Bagnara added a comment -

        Fixed.

        Show
        Stefano Bagnara added a comment - Fixed.
        Craig Raw created issue -

          People

          • Assignee:
            Stefano Bagnara
            Reporter:
            Craig Raw
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development