#579739 hobbit: Broken parsing of PROC ... TEXT="..."

Package:
xymon
Source:
xymon
Description:
monitoring system for systems, networks and applications
Submitter:
Axel Beckert
Date:
2026-10-11 09:29:03 UTC
Severity:
minor
Tags:
#579739#5
Date:
2010-04-30 10:48:17 UTC
From:
To:
Adding the following two lines to a host in hobbit-clients.cfg...

        PROC test 0 1 yellow TEXT="This is a test text with double quotes"
        PROC test 0 2 yellow TEXT=This is a test text without double quotes

results in the following strings on the procs page for that host:

 "This is a test text with double quotes (found 0, req. at most 1)
 This (found 0, req. at most 2)

In the first case the leading double quote is not stripped from the
text, but without double quotes, only the first word is taken (which
would be fine if it would work with double quotes).

#579739#12
Date:
2010-05-17 19:23:57 UTC
From:
To:
tags 579739 confirmed upstream
thanks

Re: Axel Beckert 2010-04-30 <20100430104817.81A592E4D1A@snitch.localdomain>

Confirmed, easy to check with hobbitd_client --dump-config. CLASS="foo
bar" is equally affected, so this is a bug in the parser and/or the
"rule walk" mechanism. The latter is a pretty arcane stack of C
functions that I'd rather leave to upstream to debug. Bug forwarded to
the developers list.

Christoph

#579739#23
Date:
2026-10-11 09:27:54 UTC
From:
To:
I'll try to update the status of this bug report a little...

Axel Beckert schrieb am Freitag, den 30. April 2010:

The upstream tracker at sourceforge seems to no longer exist, so I
cannot see, what was tracked there :-(
But I found some discussion in the mailman archive at sourceforge:
https://sourceforge.net/p/xymon/mailman/message/25279576/
https://sourceforge.net/p/xymon/mailman/message/25280639/
https://sourceforge.net/p/xymon/mailman/message/25318288/

Especially the one in the middle is quite interesting, I'll cite it
here (before it's also lost on SF):
hmm.. I thought the syntax is

PROC test 0 2 yellow "TEXT=This is a test text without double quotes"


man hobbit-clients.cfg
[..]
PORT LOCAL=%[.:]22$ STATE=LISTEN "TEXT=SSH listener"
[..]
-------------- snipp ----------------

This is still in analysis.cfg(5):

       The  TEXT=displaytext option affects how the port appears on the "ports"
       status page. By default, the port is listed with the  local/remote/state
       rules  as  identification,  but this may be somewhat difficult to under-
       stand. You can then use e.g. "TEXT=Secure Shell" to make these ports ap-
       pear with the name "Secure Shell" instead.

       Defaults: mincount=1, maxcount=-1 (unlimited),  color="red".   Note:  No
       ports are checked by default.

       Example:  Check  that  the SSH daemon is listening on port 22. Track the
       number of active SSH connections, and warn if there are more than 5.
               PORT LOCAL=%[.:]22$ STATE=LISTEN "TEXT=SSH listener"
               PORT LOCAL=%[.:]22$ STATE=ESTABLISHED MAX=5 TRACK=ssh TEXT=SSH

I just tried this out myself:

        PROC test 0 1 yellow TEXT="This is a test text with double quotes"
        PROC test 0 2 yellow TEXT=This is a test text without double quotes
        PROC test 0 3 yellow "TEXT=This is a test text with double quotes"

which results in:

"This is a test text with double quotes (found 0, req. at most 1)
This (found 0, req. at most 2)
This is a test text with double quotes (found 0, req. at most 3)

So this works as described in the man page ("TEXT=..."), but I also
think that the first variant (TEXT="...") should also work as an
alternative (meaning that the parser should remove the leading
quotes).

I just opened an issue in the new github project:
https://github.com/xymon-monitoring/xymon/issues/624

Greetings
Roland