journal-remote: set a limit on the number of fields in a message
authorZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>
Fri, 7 Dec 2018 09:48:10 +0000 (10:48 +0100)
committerLukáš Nykrýn <lnykryn@redhat.com>
Mon, 11 Feb 2019 09:51:14 +0000 (10:51 +0100)
commitfde3fa3e9c0330c7de645ce2140f9dd39640a693
tree05bb86ec3ee1d874abfb7f98737b9b98c16d407d
parentad18012c46724aa097f37015a8036a4343206efe
journal-remote: set a limit on the number of fields in a message

Existing use of E2BIG is replaced with ENOBUFS (entry too long), and E2BIG is
reused for the new error condition (too many fields).

This matches the change done for systemd-journald, hence forming the second
part of the fix for CVE-2018-16865
(https://bugzilla.redhat.com/show_bug.cgi?id=1653861).

(cherry-picked from commit ef4d6abe7c7fab6cbff975b32e76b09feee56074)

Resolves: #1664977
src/journal-remote/journal-remote-main.c
src/journal-remote/journal-remote.c