Skip to content

Syslog rfc5424 parsing does not accept NILVALUE timestamp #1471

@jinnatar

Description

@jinnatar

A note for the community

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Problem

Syslog parsing for rfc5424 rejects a message that does not hold a timestamp and instead uses a NILVALUE, i.e. - for that field with the error:

unable to parse input as valid syslog message

As per the RFC:

TIMESTAMP = NILVALUE / FULL-DATE "T" FULL-TIME
NILVALUE = "-"

The TIMESTAMP field guidance 6.2.3 says:

A syslog application MUST use the NILVALUE as TIMESTAMP if the syslog
application is incapable of obtaining system time.

My case is exactly this, an embedded device incapable of determining time.

Configuration

N/A

Version

vector 0.48.0 (x86_64-unknown-linux-gnu a67e4e2 2025-06-30 18:25:45.272082383)

Debug Output

%> vector vrl --input test-timestamp.json "parse_syslog!(.message)"
2025-08-10T13:53:11.676549Z DEBUG vector::app: Internal log rate limit configured.
2025-08-10T13:53:11.676604Z  INFO vector::app: Log level is enabled. level="trace"
2025-08-10T13:53:11.676717Z DEBUG vector::app: messaged="Building runtime." worker_threads=48
2025-08-10T13:53:11.676828Z TRACE mio::poll: registering event source with poller: token=Token(1), interests=READABLE
{ "appname": "Serial-Debugger", "facility": "user", "hostname": "10.0.4.87", "message": "Serializer started!", "severity": "info", "timestamp": t'2003-08-24T12:14:15.000003Z', "version": 1 }
function call error for "parse_syslog" at (0:23): unable to parse input as valid syslog message

Example Data

{"message":"<14>1 2003-08-24T05:14:15.000003-07:00 10.0.4.87 Serial-Debugger - - - Serializer started!" }
{"message":"<14>1 - 10.0.4.87 Serial-Debugger - - - Serializer started!" }

Additional Context

No response

References

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    type: bugA code related bug

    Type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions