0

i need to send all received syslog message as an json payload.

syslog entry it self contains double quotes and other special chars, that ruins my json payload, any idea how it can automatically escape those ?

That's the current configuration that i tried

destination httpendpoint {
  http(
    url("https://webhook-tester/somethinsomethin")
    method("POST")
    tls(
      peer-verify(yes)
      ca-dir("/etc/ssl/certs")
    )
    body("{ \"source\": \"TCPSyslog\", \"host\": \"${PROXIED_SRCIP}\", \"message\": \"${MESSAGE}\"}")
  );
};
porlock
  • 1
  • 1

0 Answers0