afsocket: Require libsystemd-daemon for socket activation

Instead of carrying a convenience copy of sd-daemon.c and sd-daemon.h,
require libsystemd-daemon for socket activation. If the library is not
found, systemd support will be disabled.

This is so other parts of syslog-ng can easily use systemd things
aswell, without having to move sd-daemon.* to lib/ or some similar
place.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
system-source: Use libsystemd-daemon functions

Instead of reimplementing various checks, use the functionality
provided by libsystemd-daemon to do the same things better.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
mainloop: Add support for systemd notifications

When compiling with systemd support, notify systemd about our status
and readiness via sd_notify().

Also set the service type to Type=notify in the systemd unit file.

Signed-off-by: Gergely Nagy <algernon@madhouse-project.org>
scl: Two reusable blocks to mask or hash credit card numbers

Contributed by Marton Illes <marci@balabit.com>, the two rewrite
blocks -credit-card-mask and credit-card-hash - can be used to mask or
hash credit card numbers that may appear in log messages.

For more information about the topic, see his blog post at:
 http://marci.blogs.balabit.com/2013/02/masking-credit-card-numbers-in-log-messages-with-syslog-ng/

The block names were changed to be less cryptic, and the regexp was
lifted out into a shared define.

Signed-off-by: Gergely Nagy <algernon@balabit.hu>
value-pairs: Rename replace() to replace-prefix()

This renames the replace() value-pairs rekey option to
replace-prefix(), because that is what it does. This is done for both
the value-pairs() grammar, and for the command-line-like parser used
for template functions too.

For compatibility's sake, replace() remains as an alias for now, but
it is marked as obsolete, and will emit a warning.

Signed-off-by: Gergely Nagy <algernon@balabit.hu>
afmongodb: Remove the username() and password() options

These were never documented, and they never worked either, and there
appears no demand for it, either. Best remove them, until such time
that they can be implemented sanely.

Signed-off-by: Gergely Nagy <algernon@balabit.hu>
versioning: Change the current version to 3.5

This adds the VERSION_3_5 macro, and updates VERSION_VALUE and
VERSION_CURRENT_* to 3.5 aswell.

Signed-off-by: Gergely Nagy <algernon@balabit.hu>
configure.ac: There is no lib/libproto/Makefile

The Makefile.am (libproto.am) snippet from lib/libproto is directly
included into lib/Makefile.am, there is no
lib/libproto/Makefile.am. The configure.ac script should reflect this
too.

Signed-off-by: Gergely Nagy <algernon@balabit.hu>