Uploaded image for project: 'OpenNMS'
  1. OpenNMS
  2. NMS-7529

Event replacement items that contain '%' characters in result in broken notification text sometimes

    XMLWordPrintable

    Details

      Description

      In AbstractEventUtil, there's a bit of code that checks for whitespace in a potential replacement parameter. Unfortunately, the regex used does not enable the DOTALL flag, so if you've got something like a Cisco syslog message that often contains '%' signs in them it'll find something like

      'SSH-4-SSH2_UNEXPECTED_MSG: Unexpected message type has arrived. Terminating the connection <br>
                              Process: 304806 <br>
                              PID: 
                              </p>
      #/description#
      41
      Unknown
      172.17.12.251
      Warning
      Thursday, March 5, 2015 2:48:47 PM CST
      .
      uei.opennms.org/syslogd/local7/Warning
      syslogmessage="172.17.12.251: Mar  5 20:48:35.644: '
      

      as a potential param. Clearly this isn't meant to be a parameter. Changing the regex to DOTALL mode seems to fix this.

        Attachments

          Activity

            People

            • Assignee:
              ranger Benjamin Reed
              Reporter:
              schlend David Schlenk
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: