summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Sterrett <mr_bones_@gentoo.org>2013-04-28 04:50:46 +0000
committerMichael Sterrett <mr_bones_@gentoo.org>2013-04-28 04:50:46 +0000
commit257c8776562c98aa749169002470e8e39e8229b2 (patch)
tree892e4efb8efb44bcce7de3f5b613330d66a4bd3e /app-admin/syslog-ng
parenttesting mask for new syslog-ng (diff)
downloadhistorical-257c8776562c98aa749169002470e8e39e8229b2.tar.gz
historical-257c8776562c98aa749169002470e8e39e8229b2.tar.bz2
historical-257c8776562c98aa749169002470e8e39e8229b2.zip
masked bump to next version series
Package-Manager: portage-2.1.11.55/cvs/Linux x86_64
Diffstat (limited to 'app-admin/syslog-ng')
-rw-r--r--app-admin/syslog-ng/ChangeLog14
-rw-r--r--app-admin/syslog-ng/Manifest14
-rw-r--r--app-admin/syslog-ng/files/3.4/syslog-ng-3.4.1-rollup.patch303
-rw-r--r--app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo42
-rw-r--r--app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.fbsd29
-rw-r--r--app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.hardened115
-rw-r--r--app-admin/syslog-ng/files/3.4/syslog-ng.confd42
-rw-r--r--app-admin/syslog-ng/files/3.4/syslog-ng.rc664
-rw-r--r--app-admin/syslog-ng/files/syslog-ng.rc6.3.35
-rw-r--r--app-admin/syslog-ng/metadata.xml1
-rw-r--r--app-admin/syslog-ng/syslog-ng-3.4.1.ebuild115
11 files changed, 737 insertions, 7 deletions
diff --git a/app-admin/syslog-ng/ChangeLog b/app-admin/syslog-ng/ChangeLog
index d4916ac1a1b2..c6188c6d31cc 100644
--- a/app-admin/syslog-ng/ChangeLog
+++ b/app-admin/syslog-ng/ChangeLog
@@ -1,6 +1,16 @@
# ChangeLog for app-admin/syslog-ng
-# Copyright 1999-2012 Gentoo Foundation; Distributed under the GPL v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/ChangeLog,v 1.329 2012/10/01 18:26:02 mr_bones_ Exp $
+# Copyright 1999-2013 Gentoo Foundation; Distributed under the GPL v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/ChangeLog,v 1.330 2013/04/28 04:50:35 mr_bones_ Exp $
+
+*syslog-ng-3.4.1 (28 Apr 2013)
+
+ 28 Apr 2013; Michael Sterrett <mr_bones_@gentoo.org>
+ +files/3.4/syslog-ng-3.4.1-rollup.patch, +files/3.4/syslog-ng.conf.gentoo,
+ +files/3.4/syslog-ng.conf.gentoo.fbsd,
+ +files/3.4/syslog-ng.conf.gentoo.hardened, +files/3.4/syslog-ng.confd,
+ +files/3.4/syslog-ng.rc6, +syslog-ng-3.4.1.ebuild, files/syslog-ng.rc6.3.3,
+ metadata.xml:
+ masked bump to next version series
01 Oct 2012; Michael Sterrett <mr_bones_@gentoo.org> -syslog-ng-3.3.5.ebuild:
old
diff --git a/app-admin/syslog-ng/Manifest b/app-admin/syslog-ng/Manifest
index babd9abee557..524eef337183 100644
--- a/app-admin/syslog-ng/Manifest
+++ b/app-admin/syslog-ng/Manifest
@@ -1,3 +1,9 @@
+AUX 3.4/syslog-ng-3.4.1-rollup.patch 11181 SHA256 db146f40389f3d2beda9578317a82791628a9b350ee6cee22cc24ac42cf27f79 SHA512 0003333a0881ed722957ee3b906741e4a1a82be76ec0ca0665920143ad49f897d1dca31b4634e84a17fbff20428f655ef2e465a6f47948b7488b11be408321b9 WHIRLPOOL a71d71709d6ac96493c7a3f01c3fd9b97ec0f177b1ccfe2870b48a4964c7779f0bfd1fdf8879c92060cbde08189be8ee66fdf35f8c087cc7001ad1918759a268
+AUX 3.4/syslog-ng.conf.gentoo 1431 SHA256 7894f4ad578002678586c22a0d67122b2609310c4db4f6a5b105e465a99c7330 SHA512 459426990d79973f9947b18f147f38fc15fe2df44e3c0b36ff2081eae11a6f275120d06e75ba5adb689830d9161ed18c22ae1e576dcef0a778d33d7d10cc1412 WHIRLPOOL fc5d5f51dad321e2539d2b9c0e64145bb23b1a7c894648ef1c292edc609396f2a20dffef58a8326be5fc591ce129511d4eaeaebef7f60291b53a4e8e9820314f
+AUX 3.4/syslog-ng.conf.gentoo.fbsd 776 SHA256 362fcf26001c70d9b7c80e57abbd01de34d8a38832f7288f266139e9944ceda2 SHA512 0f0bc5bb661507d8e9c04a03eb0d817a163ef361296954762832ff5bae096f8651c5082e7383e10bdfd0c0f01c9a2f5cd9c8e5d6a49326096e14e8a90a4eb1d1 WHIRLPOOL bea1d6f39eb8c9cab59b51e040f77b06d546b21de15fde2af3e44e739cac1246003528ab2c82d3a8b1cdb800d977980c8fcff5f949bb0b26b179f8a433161a31
+AUX 3.4/syslog-ng.conf.gentoo.hardened 4658 SHA256 5efb3976249fd44d01af2c287f35e9c3a61e74909b4f7d9f63dabc32eb4e3f74 SHA512 d326832592b016b3fec1119ff90c4898fc4351bbeccff32295712229e955b72ea80a282cbcb527862371c5899446ee4747f95fe898e36338c47683121598140e WHIRLPOOL e1eb845712cbff8a3a3f656689b1c8a1573882cc9850211bba22eb5cf46adc2337799fa4992d17e5e32a67ea7ae4f7ff65034dcb1606a6ccb82f565d1ef80098
+AUX 3.4/syslog-ng.confd 1496 SHA256 d28c269c8aa2876a389aefdc76b18bcd30eb6653ea1e54a0eb6fb596568643b6 SHA512 792258acfb78caabc2078f0c7c1fb6c61fe0ad91ca45d4901a0257d687e51edbf81ca67a304ead345579855ae2ba0a7fd8b82f1e80e798d4b6c339c31b687afb WHIRLPOOL 3552c19038489743740acf5e77df83d54bb750547055a6c0711a2d6ec9b97fb1389e33142e2fdbc42a9dc84c69b67329657bf1c519492e2c0a2a71a7a8c78444
+AUX 3.4/syslog-ng.rc6 2175 SHA256 ce3abded20b3ecdcddf11ef93bf54b6a0898407d37dee370a7a20cb3664976bb SHA512 f0766bb8bb0d864a7eaec0b3c8dfd9377d75db606f5812640f90411d3f6c06d7e31cf88c95357acad14f1f4e08ad7adf68ecf005b2a8f92d58e7fb8c5c6f6174 WHIRLPOOL f4fa34fa41a457ad4063dd6bdd03dc5a3b5c3168cf1be4a1ccf6fcde3aaceafd95c2af6aa24f467042edf13a008dac766d8b5f3e375cd847e09c7308bfdc72fa
AUX syslog-ng-3.3.5-afsocket.patch 1384 SHA256 d363ad6ee2d994ff7f3e32b6ea2ad3889033023332ffd76d963313716dc0dc59 SHA512 8704cf813778e72ce70f8e8b88c53ebf570880ff591c5b3d9c4239e72fa97223f9e492473096b82b89b61edeb2cadcd8bb9794fb0a83b4755ad691637b193929 WHIRLPOOL d7c5aeaec98eeeda80713033c891fa916b52f9591e46031b0b032a1a8340c29fb41ebb3d96203f0d5e3670a07502061f0e1c08e14d766870fdc4d30e40dab41e
AUX syslog-ng-3.3.5-compile.patch 250 SHA256 831476d524a2fb32fe944a960f5adb4f97fde6ded8d84eb1ad9ef00b5f1a9354 SHA512 ad865b18cb8ea8509abeced4f42b9fd303e2a3f41ff9c58fd23ee5331b6248409a54963ee15dc5803c9f69532809048fd996e9197e9d459b03ccbd3ba2b5c9fd WHIRLPOOL 3f36605448b10eeddf6aeaeede64815edc5b48371c65270d6b83758477cdfcc79e7361521ff00f5922da5b1aff5c17c6e1ed4b36ef649f4c3a95020ccec2d422
AUX syslog-ng-3.3.5-gprocess.patch 1583 SHA256 da5267e191690a38d63304f5943e79a3384bbb797f38e10604af85595e925402 SHA512 6a08ebaa96a54cdbb441d95632f98e74bf410f9c2db74238c60b0eca02094eab6c237d38d000cb63995586914b2414f8e8aa7d0c1e9f031befeaf03b04bf3056 WHIRLPOOL d9bf12718783fb66727381eed0040d2b3f4c61be9498ac1dd87a57a14eff418ad9dea854c6edbc11c8bf82c902016c8742a8cb09973189b2991c6db322a1ce9f
@@ -14,10 +20,12 @@ AUX syslog-ng.confd 150 SHA256 8319ca8e39a5dab5ddc82eede088e1f58ff25deef33080464
AUX syslog-ng.logrotate 354 SHA256 e8e1b6d87f8217c77c0bfbe3095cac0c4edcb72473cbd1423bf2ae7bffee8ca3 SHA512 c3dc48bd0525947d728c51ac79faa05b481d5ad7dc4f52ed69d2f5a4344fe71c3e06591fe058ef5dcb8ea6cf089954e9a312d510e129727b35a6e32d8e9ec5e8 WHIRLPOOL 34e5efedceed29fadfc99165a70407a2bd64e4df05818f8da831840bf16e287c2e54c47cdb81393f581e14c84407137dc18b5a17b840eb0587877803e8b8be41
AUX syslog-ng.logrotate.hardened 1742 SHA256 f2c9f99c7dd73e709e5edb7be99de5a13058baab29d3c922ab9366ddd50eda8f SHA512 2f751bc34e2de833b764f4fc1ccb2fc0337c1d3f84bd30194897972270ef6fc502ff3822912921a15479bea273bc0aa4eeec8c68d672ce1edcdcb5cfed70926a WHIRLPOOL b80fe444f140f842677dc59cef7d19e777429e2983a808c264bed1436f505052bc239f8238ad5d739d50eb21e1f36b5f52d45010d6b3b3ae8fd296a7c4939608
AUX syslog-ng.rc6.3 1871 SHA256 72ff545c9196eee9782ec490f6585d9f0f4367d226234f50ddfb222d2fbc32aa SHA512 193b20cd067158e9a5c094e6abd2a5dce8a473828e1b6ab86f258452cfa7ab32c3bca6bc471fea601366cc98987b5a8d090f10eff835043228fbef13e0a3b4e0 WHIRLPOOL adf6e6854e1c3854b6d29729268bf8c5c557ad9b8869e1d4bfdf9f462f2b2d2c681e1375386e0ec4a31d9971229a6919a27e929709b1abbe7851d29b0632d9bc
-AUX syslog-ng.rc6.3.3 2365 SHA256 fef807344eb4ce4867e9b155be1ed1ccc66e29174746a8948a74c517257f8b33 SHA512 ff9fa40c4865d00e474a968bc0e1b98ab18fa8b08931925edda69a21125c7f9f19bbc2308da71535b35f8706a8eb25a4dde026f6f1e04bb035a349f8f423ec0d WHIRLPOOL e693de3fd4674ac741a8246ff38b7d2a394dd55f3418cd6b9fea441dae3685528829d412d951e2d880187749b80f80935f6d1011411893213f7e43385a950ce9
+AUX syslog-ng.rc6.3.3 2381 SHA256 19bbd35abc9f54ce368e1ccf46b6e4af6eec304906e432bb9968d50a01d18284 SHA512 a95d03aa4caeafc0250c036b05fddc715607a7b720af19651a644ed168337b38b33be0316671ea77ebaaedfb021bf0fb352d42c9e25bdc281debfae913290e54 WHIRLPOOL ab28a6eece135f0f0a2ec6577aee8bdb17aa1abbf7b65aaf04ff179e1271e63a2de22909f4ab5bbed67d8a869aa3c2a88e02bd247e7a2b32d117e1089cbf9bc0
DIST syslog-ng_3.2.5.tar.gz 1448844 SHA256 ffc9f3a0ebea836c1c737b1ff49efe731d885af1d8aacf9eca79d9144eeefa89 SHA512 f155a56b77c2a8e0e7809a98644394c9d4132e356c3190cda8b8d23a4cf28814bee02c53a1f2e8991c97302a8f1fe7410f8b2fa80f52bc1b7db2f09e26fa9dc8 WHIRLPOOL 0157a1f7611a0637acc54802b2ddb0e796e441dc304c702fece85e39e4ef31f5c5a95198ed264317fbebd805368955df63c6fe38580b74eaaa6e614a4b2e83ef
DIST syslog-ng_3.3.5.tar.gz 2495235 SHA256 dcca69869ab3cf2afda6db0dad549b6be717f6cf6aa6d7f27ca10f9c4c6aaa75 SHA512 eaac6376c527bbf6730943670a2dfac1c8765837335ca509cbebf120279a31d13f7b813fe1dde72761bcf185320619b84b650b1e037ccf0fe94966e93c3415c3 WHIRLPOOL a2d32798219897c86b43f3dbf6e2be5bf6c704d896a664afe3a0f13f8b98c6e9839fcfc3bf2fb89f1e4764ad13878329e1c33ea2c85f17921505030f8eda9b1a
+DIST syslog-ng_3.4.1.tar.gz 3347306 SHA256 ca5613a808ea92cb72669d8e1c141bf86405e0d94f913c4db3ab9e2c37612986 SHA512 5f9830f269cd612f3ee62a044a0dab4a38b33395a6b60669e84433410ad63f74b1711536b49fad13589f82986f55c9581433141f7a77eeae34056ec6344c9399 WHIRLPOOL f5985236c0a4cb9044e60a9ef3beeffe9c3c03cebea98da853d256d60e853e5da235fc5d33faf871dcea018d931965156c8d8a29e941083513bccd8723b94155
EBUILD syslog-ng-3.2.5.ebuild 2852 SHA256 2f0de5b0f8296b0d4e4d00c206bea5b1b28f31ff1c51879ec72dd3aa8f306375 SHA512 c751b8975e62c884d1c5f034b53e10d27d08f0b9e745f63e5e150e3e2b77dfedb43223443172b9150cac5737ed541f22205173d4bcd9816b3878a3e4a89c42eb WHIRLPOOL c4bda63c10d006f7cc7dbeb78a9f272a10d70ca33bb060953c92f5b7b33c618d4f94f4b0b3022c010cd0c5d389fe261dcd638ec9e8813f3c1ae1ee88e100350d
EBUILD syslog-ng-3.3.5-r1.ebuild 3892 SHA256 d06a5677c44a132c0c1e62b12ad9abcb65fe4cd15d0de7f4ff9f61b24a34a9f9 SHA512 aaa0973f261ab6a82c9d0e41fb5c8cb3c3aef488da63aff955bb2bffb092a86adb8ec49be6508ed5e264e3363528b6427b75f39bafffc2b8c849361ce71f2a46 WHIRLPOOL ed81d17b1db01e696267cce2e2d6fd94dd1eca46bba9a3bedba0c130991e69bf80828f6dd16f93c06c34d9ae137073dec7bd710e67ed9efb700e64e83f373d42
-MISC ChangeLog 45474 SHA256 5aa1a13b41cdc2c884d550b4339421bf709a0eac9dc8bf390e244c1b73bfe182 SHA512 3c97294efab4747fe21238607d7565ac87b8ae0282965e85e0224abe4283885fcdc3c0e5ac62e9e2772fefad530fd626c97d65622632ca80425c93768b563268 WHIRLPOOL 1382a662991873c35546223aac915ed4dd5a1e5e2f479be5e7fb46c7afc0fa326545880918969ae657ff98c448f1f2bdba047c184ba22466ff28983ba4ee91c9
-MISC metadata.xml 559 SHA256 b0a3c093ff517898bb36172559a8778e0290a5a95255df64e1fe223232837cd7 SHA512 b45b823c5d0059c9ba4472fad1a16a4cca76405833740518dc9b62ea3ce1f79c4d424dc492921d7e399cfdc947e3f011f721a85baa6accb28059c2c2470da573 WHIRLPOOL 240ed2590f7462169cb87e3bcdcb337fd4156a540dac9bd2f4eef0cf5fe77bdd554d3e49743b23de5340c263fe4c57f3523ab26718974ed4e5881c6340cd0fdd
+EBUILD syslog-ng-3.4.1.ebuild 3549 SHA256 148291bc3b6c8df46e88af22c9f0bd22442babf1aa5296db7ce7e9a3db662de0 SHA512 39c20c62c0d6fff6dc889133a36de8a431342148c242365d3ffbd2ee6b2e499c75f4671859b7e5f879ac529d443cd15f57824f227d667dc35b84a99857f23c1e WHIRLPOOL a09e144c8561803f635f01bb855be1841f4ea740c6dc4d378a3d2e64e71cb4b99f45f96be434f7f527e85fe7c5963bca49dca554c5a5d465bea841e3ff429b15
+MISC ChangeLog 45884 SHA256 a81ca45ce79d20617ef66dcfacfd1e7d2f079f9d6b83edbb3149a5cd2379d3cd SHA512 16ce0ae94631e1d42bbcbc8b8e9153efb8c327c7ae7cf8e4caaa2fc0e624cab2898753ff8c9967877147e76cb549b136308182448c7e1c7e8c4d94e3f6a67ceb WHIRLPOOL 389997cc2fd6821431ccad252d75d35112cf57ff2fc530d8320eae7c79ada25969fdb39a54515f68639db6bc61393ae058a3006794e2103d6a9ad60805d591b5
+MISC metadata.xml 622 SHA256 080a769b5f0dd360ac36a746667a70a85a8e857553da07dc5272005c097125ba SHA512 afc895b14a063c88fac179d3a588e0d77e507a7bd8a9bd93091989f5df959e002696d281364ef28d293546b191e2ab8a67eba59d2e1006f97640b57a302c4e1c WHIRLPOOL c634c831dc48c370a21f37abf5c4a96a0c11463fa69dd26c632f0b294af5f1372416d4bfb941eaa842cdc247587684aff14498e65e490cc4e16db6ae2aaff1b2
diff --git a/app-admin/syslog-ng/files/3.4/syslog-ng-3.4.1-rollup.patch b/app-admin/syslog-ng/files/3.4/syslog-ng-3.4.1-rollup.patch
new file mode 100644
index 000000000000..0b487f6c719a
--- /dev/null
+++ b/app-admin/syslog-ng/files/3.4/syslog-ng-3.4.1-rollup.patch
@@ -0,0 +1,303 @@
+diff -ru syslog-ng-3.4.1/contrib/systemd/syslog-ng.service syslog-ng-3.4-master/contrib/systemd/syslog-ng.service
+--- syslog-ng-3.4.1/contrib/systemd/syslog-ng.service 2013-01-06 15:38:58.000000000 -0500
++++ syslog-ng-3.4-master/contrib/systemd/syslog-ng.service 2013-04-16 10:11:23.000000000 -0400
+@@ -7,6 +7,7 @@
+ ExecStart=/usr/sbin/syslog-ng -F
+ ExecReload=/bin/kill -HUP $MAINPID
+ StandardOutput=null
++Restart=on-failure
+
+ [Install]
+ WantedBy=multi-user.target
+diff -ru syslog-ng-3.4.1/lib/cfg-tree.c syslog-ng-3.4-master/lib/cfg-tree.c
+--- syslog-ng-3.4.1/lib/cfg-tree.c 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/cfg-tree.c 2013-04-16 10:11:23.000000000 -0400
+@@ -588,6 +588,22 @@
+ return FALSE;
+ }
+
++static void
++cfg_tree_propagate_expr_node_properties_to_pipe(LogExprNode *node, LogPipe *pipe)
++{
++ if (node->flags & LC_FALLBACK)
++ pipe->flags |= PIF_BRANCH_FALLBACK;
++
++ if (node->flags & LC_FINAL)
++ pipe->flags |= PIF_BRANCH_FINAL;
++
++ if (node->flags & LC_FLOW_CONTROL)
++ pipe->flags |= PIF_HARD_FLOW_CONTROL;
++
++ if (!pipe->expr_node)
++ pipe->expr_node = node;
++}
++
+ /**
+ * cfg_tree_compile_sequence:
+ *
+@@ -713,10 +729,6 @@
+ {
+ source_join_pipe = last_pipe = log_pipe_new();
+ g_ptr_array_add(self->initialized_pipes, source_join_pipe);
+-
+- source_join_pipe->expr_node = node;
+- if (node->flags & LC_FLOW_CONTROL)
+- source_join_pipe->flags |= PIF_HARD_FLOW_CONTROL;
+ }
+ log_pipe_append(sub_pipe_tail, source_join_pipe);
+ }
+@@ -724,16 +736,13 @@
+
+ if (first_pipe)
+ {
+- if (node->flags & LC_FALLBACK)
+- first_pipe->flags |= PIF_BRANCH_FALLBACK;
+-
+- if (node->flags & LC_FINAL)
+- first_pipe->flags |= PIF_BRANCH_FINAL;
+-
+- if (node->flags & LC_FLOW_CONTROL)
+- first_pipe->flags |= PIF_HARD_FLOW_CONTROL;
+- if (!first_pipe->expr_node)
+- first_pipe->expr_node = node;
++ /* we actually return something as sub_pipe_head, which means that we
++ * have to propagate flags upwards */
++ cfg_tree_propagate_expr_node_properties_to_pipe(node, first_pipe);
++ }
++ else if (last_pipe)
++ {
++ cfg_tree_propagate_expr_node_properties_to_pipe(node, last_pipe);
+ }
+
+
+diff -ru syslog-ng-3.4.1/lib/control.c syslog-ng-3.4-master/lib/control.c
+--- syslog-ng-3.4.1/lib/control.c 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/control.c 2013-04-16 10:11:23.000000000 -0400
+@@ -1,5 +1,5 @@
+ /*
+- * Copyright (c) 2002-2012 BalaBit IT Ltd, Budapest, Hungary
++ * Copyright (c) 2002-2013 BalaBit IT Ltd, Budapest, Hungary
+ * Copyright (c) 1998-2012 Balázs Scheidler
+ *
+ * This library is free software; you can redistribute it and/or
+@@ -208,8 +208,8 @@
+ }
+ else if (rc == 0)
+ {
+- msg_error("EOF on control channel, closing connection",
+- NULL);
++ msg_notice("EOF on control channel, closing connection",
++ NULL);
+ goto destroy_connection;
+ }
+ else
+diff -ru syslog-ng-3.4.1/lib/filter.c syslog-ng-3.4-master/lib/filter.c
+--- syslog-ng-3.4.1/lib/filter.c 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/filter.c 2013-04-16 10:11:23.000000000 -0400
+@@ -46,6 +46,12 @@
+ self->ref_cnt = 1;
+ }
+
++/*
++ * In case the filter would modify the message the caller has to make sure
++ * that the message is writable. You can always archieve that with
++ * filter_expr_eval_root() below, but you have to be on a processing path to
++ * do that.
++ */
+ gboolean
+ filter_expr_eval_with_context(FilterExprNode *self, LogMessage **msg, gint num_msg)
+ {
+@@ -65,6 +71,21 @@
+ return filter_expr_eval_with_context(self, &msg, 1);
+ }
+
++gboolean
++filter_expr_eval_root_with_context(FilterExprNode *self, LogMessage **msg, gint num_msg, const LogPathOptions *path_options)
++{
++ if (self->modify)
++ log_msg_make_writable(&msg[0], path_options);
++
++ return filter_expr_eval_with_context(self, msg, num_msg);
++}
++
++gboolean
++filter_expr_eval_root(FilterExprNode *self, LogMessage **msg, const LogPathOptions *path_options)
++{
++ return filter_expr_eval_root_with_context(self, msg, 1, path_options);
++}
++
+ FilterExprNode *
+ filter_expr_ref(FilterExprNode *self)
+ {
+@@ -98,6 +119,7 @@
+ self->left->init(self->left, cfg);
+ if (self->right && self->right->init)
+ self->right->init(self->right, cfg);
++ self->super.modify = self->left->modify || self->right->modify;
+ }
+
+ static void
+@@ -132,7 +154,6 @@
+
+ fop_init_instance(self);
+ self->super.eval = fop_or_eval;
+- self->super.modify = e1->modify || e2->modify;
+ self->left = e1;
+ self->right = e2;
+ self->super.type = "OR";
+@@ -154,7 +175,6 @@
+
+ fop_init_instance(self);
+ self->super.eval = fop_and_eval;
+- self->super.modify = e1->modify || e2->modify;
+ self->left = e1;
+ self->right = e2;
+ self->super.type = "AND";
+@@ -509,6 +529,7 @@
+
+
+ self->filter_expr = ((LogFilterPipe *) rule->children->object)->expr;
++ self->super.modify = self->filter_expr->modify;
+ }
+ else
+ {
+@@ -699,10 +720,8 @@
+ evt_tag_str("rule", self->name),
+ evt_tag_str("location", log_expr_node_format_location(s->expr_node, buf, sizeof(buf))),
+ NULL);
+- if (self->expr->modify)
+- log_msg_make_writable(&msg, path_options);
+
+- res = filter_expr_eval(self->expr, msg);
++ res = filter_expr_eval_root(self->expr, &msg, path_options);
+ msg_debug("Filter rule evaluation result",
+ evt_tag_str("result", res ? "match" : "not-match"),
+ evt_tag_str("rule", self->name),
+diff -ru syslog-ng-3.4.1/lib/filter.h syslog-ng-3.4-master/lib/filter.h
+--- syslog-ng-3.4.1/lib/filter.h 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/filter.h 2013-04-16 10:11:23.000000000 -0400
+@@ -48,6 +48,8 @@
+
+ gboolean filter_expr_eval(FilterExprNode *self, LogMessage *msg);
+ gboolean filter_expr_eval_with_context(FilterExprNode *self, LogMessage **msgs, gint num_msg);
++gboolean filter_expr_eval_root(FilterExprNode *self, LogMessage **msg, const LogPathOptions *path_options);
++gboolean filter_expr_eval_root_with_context(FilterExprNode *self, LogMessage **msgs, gint num_msg, const LogPathOptions *path_options);
+ void filter_expr_unref(FilterExprNode *self);
+
+ typedef struct _FilterRE
+diff -ru syslog-ng-3.4.1/lib/logmpx.c syslog-ng-3.4-master/lib/logmpx.c
+--- syslog-ng-3.4.1/lib/logmpx.c 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/logmpx.c 2013-04-16 10:11:23.000000000 -0400
+@@ -39,9 +39,15 @@
+
+ for (i = 0; i < self->next_hops->len; i++)
+ {
+- LogPipe *next_hop = g_ptr_array_index(self->next_hops, i);
++ LogPipe *branch_head = g_ptr_array_index(self->next_hops, i);
++ LogPipe *p;
++
++ for (p = branch_head; p; p = p->pipe_next)
++ {
++ branch_head->flags |= (p->flags & PIF_BRANCH_PROPERTIES);
++ }
+
+- if ((next_hop->flags & PIF_BRANCH_FALLBACK) != 0)
++ if (branch_head->flags & PIF_BRANCH_FALLBACK)
+ {
+ self->fallback_exists = TRUE;
+ }
+diff -ru syslog-ng-3.4.1/lib/logmsg.h syslog-ng-3.4-master/lib/logmsg.h
+--- syslog-ng-3.4.1/lib/logmsg.h 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/logmsg.h 2013-04-16 10:11:23.000000000 -0400
+@@ -1,6 +1,6 @@
+ /*
+- * Copyright (c) 2002-2012 BalaBit IT Ltd, Budapest, Hungary
+- * Copyright (c) 1998-2012 Balázs Scheidler
++ * Copyright (c) 2002-2013 BalaBit IT Ltd, Budapest, Hungary
++ * Copyright (c) 1998-2013 Balázs Scheidler
+ *
+ * This library is free software; you can redistribute it and/or
+ * modify it under the terms of the GNU Lesser General Public
+@@ -203,6 +203,12 @@
+ gboolean log_msg_is_handle_sdata(NVHandle handle);
+ gboolean log_msg_is_handle_match(NVHandle handle);
+
++static inline gboolean
++log_msg_is_handle_settable_with_an_indirect_value(NVHandle handle)
++{
++ return (handle >= LM_V_MAX);
++}
++
+ const gchar *log_msg_get_macro_value(LogMessage *self, gint id, gssize *value_len);
+
+ static inline const gchar *
+diff -ru syslog-ng-3.4.1/lib/logpipe.h syslog-ng-3.4-master/lib/logpipe.h
+--- syslog-ng-3.4.1/lib/logpipe.h 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/logpipe.h 2013-04-16 10:11:23.000000000 -0400
+@@ -47,6 +47,7 @@
+ /* log statement flags that are copied to the head of a branch */
+ #define PIF_BRANCH_FINAL 0x0004
+ #define PIF_BRANCH_FALLBACK 0x0008
++#define PIF_BRANCH_PROPERTIES (PIF_BRANCH_FINAL + PIF_BRANCH_FALLBACK)
+
+ /* branch starting with this pipe wants hard flow control */
+ #define PIF_HARD_FLOW_CONTROL 0x0010
+diff -ru syslog-ng-3.4.1/lib/logrewrite.c syslog-ng-3.4-master/lib/logrewrite.c
+--- syslog-ng-3.4.1/lib/logrewrite.c 2013-01-31 01:58:05.000000000 -0500
++++ syslog-ng-3.4-master/lib/logrewrite.c 2013-04-16 10:11:23.000000000 -0400
+@@ -45,7 +45,7 @@
+ gssize length;
+ const gchar *value;
+
+- if (self->condition && !filter_expr_eval(self->condition, msg))
++ if (self->condition && !filter_expr_eval_root(self->condition, &msg, path_options))
+ {
+ msg_debug("Rewrite condition unmatched, skipping rewrite",
+ evt_tag_str("value", log_msg_get_value_name(self->value_handle, NULL)),
+diff -ru syslog-ng-3.4.1/lib/persist-state.c syslog-ng-3.4-master/lib/persist-state.c
+--- syslog-ng-3.4.1/lib/persist-state.c 2013-01-06 15:40:30.000000000 -0500
++++ syslog-ng-3.4-master/lib/persist-state.c 2013-04-28 00:43:29.703864600 -0400
+@@ -26,6 +26,7 @@
+ #include "serialize.h"
+ #include "messages.h"
+ #include "mainloop.h"
++#include "misc.h"
+
+ #include <sys/types.h>
+ #include <unistd.h>
+@@ -218,6 +219,7 @@
+ NULL);
+ return FALSE;
+ }
++ g_fd_set_cloexec(self->fd, TRUE);
+ self->current_key_block = offsetof(PersistFileHeader, initial_key_store);
+ self->current_key_ofs = 0;
+ self->current_key_size = sizeof((((PersistFileHeader *) NULL))->initial_key_store);
+diff -ru syslog-ng-3.4.1/modules/dbparser/patterndb.c syslog-ng-3.4-master/modules/dbparser/patterndb.c
+--- syslog-ng-3.4.1/modules/dbparser/patterndb.c 2013-01-17 06:43:50.000000000 -0500
++++ syslog-ng-3.4-master/modules/dbparser/patterndb.c 2013-04-16 10:11:23.000000000 -0400
+@@ -1302,7 +1302,7 @@
+ log_msg_set_value(msg, match->handle, match->match, match->len);
+ g_free(match->match);
+ }
+- else if (ref_handle != LM_V_NONE)
++ else if (ref_handle != LM_V_NONE && log_msg_is_handle_settable_with_an_indirect_value(match->handle))
+ {
+ log_msg_set_value_indirect(msg, match->handle, ref_handle, match->type, match->ofs, match->len);
+ }
+diff -ru syslog-ng-3.4.1/tests/loggen/loggen.c syslog-ng-3.4-master/tests/loggen/loggen.c
+--- syslog-ng-3.4.1/tests/loggen/loggen.c 2013-01-06 15:38:59.000000000 -0500
++++ syslog-ng-3.4-master/tests/loggen/loggen.c 2013-04-16 10:11:23.000000000 -0400
+@@ -847,6 +847,12 @@
+ {
+ static struct sockaddr_un saun;
+
++ if (argc < 1)
++ {
++ fprintf(stderr, "No target path specified\n");
++ return 1;
++ }
++
+ saun.sun_family = AF_UNIX;
+ strncpy(saun.sun_path, argv[0], sizeof(saun.sun_path));
+
diff --git a/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo b/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo
new file mode 100644
index 000000000000..241856071670
--- /dev/null
+++ b/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo
@@ -0,0 +1,42 @@
+@version: 3.4
+# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo,v 1.1 2013/04/28 04:50:34 mr_bones_ Exp $
+#
+# Syslog-ng default configuration file for Gentoo Linux
+
+# https://bugs.gentoo.org/show_bug.cgi?id=426814
+@include "scl.conf"
+
+options {
+ threaded(yes);
+ chain_hostnames(no);
+
+ # The default action of syslog-ng is to log a STATS line
+ # to the file every 10 minutes. That's pretty ugly after a while.
+ # Change it to every 12 hours so you get a nice daily update of
+ # how many messages syslog-ng missed (0).
+ stats_freq(43200);
+ # The default action of syslog-ng is to log a MARK line
+ # to the file every 20 minutes. That's seems high for most
+ # people so turn it down to once an hour. Set it to zero
+ # if you don't want the functionality at all.
+ mark_freq(3600);
+};
+
+source src {
+ # https://bugs.gentoo.org/show_bug.cgi?id=449260
+ unix-dgram("/dev/log");
+ internal();
+ file("/proc/kmsg");
+};
+
+destination messages { file("/var/log/messages"); };
+
+# By default messages are logged to tty12...
+destination console_all { file("/dev/tty12"); };
+# ...if you intend to use /dev/console for programs like xconsole
+# you can comment out the destination line above that references /dev/tty12
+# and uncomment the line below.
+#destination console_all { file("/dev/console"); };
+
+log { source(src); destination(messages); };
+log { source(src); destination(console_all); };
diff --git a/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.fbsd b/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.fbsd
new file mode 100644
index 000000000000..e255b8b91eff
--- /dev/null
+++ b/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.fbsd
@@ -0,0 +1,29 @@
+@version: 3.4
+# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.fbsd,v 1.1 2013/04/28 04:50:34 mr_bones_ Exp $
+#
+# Syslog-ng default configuration file for Gentoo FreeBSD
+#
+
+# https://bugs.gentoo.org/show_bug.cgi?id=426814
+@include "scl.conf"
+
+options {
+ threaded(yes);
+ chain_hostnames(no);
+
+ # The default action of syslog-ng is to log a STATS line
+ # to the file every 10 minutes. That's pretty ugly after a while.
+ # Change it to every 12 hours so you get a nice daily update of
+ # how many messages syslog-ng missed (0).
+ stats_freq(43200);
+};
+
+source src {
+ unix-dgram("/var/run/log");
+ internal();
+ file("/dev/klog");
+};
+
+destination messages { file("/var/log/messages"); };
+
+log { source(src); destination(messages); };
diff --git a/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.hardened b/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.hardened
new file mode 100644
index 000000000000..3df080800126
--- /dev/null
+++ b/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.hardened
@@ -0,0 +1,115 @@
+@version: 3.4
+# Copyright 1999-2011 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/files/3.4/syslog-ng.conf.gentoo.hardened,v 1.1 2013/04/28 04:50:34 mr_bones_ Exp $
+
+# https://bugs.gentoo.org/show_bug.cgi?id=426814
+@include "scl.conf"
+
+#
+# Syslog-ng configuration file, compatible with default hardened installations.
+#
+
+options {
+ threaded(yes);
+ chain_hostnames(no);
+ stats_freq(43200);
+};
+
+source src {
+ unix-dgram("/dev/log");
+ internal();
+};
+source kernsrc {
+ file("/proc/kmsg");
+};
+
+#source net { udp(); };
+#log { source(net); destination(net_logs); };
+#destination net_logs { file("/var/log/HOSTS/$HOST/$YEAR$MONTH$DAY.log"); };
+
+destination authlog { file("/var/log/auth.log"); };
+destination _syslog { file("/var/log/syslog"); };
+destination cron { file("/var/log/cron.log"); };
+destination daemon { file("/var/log/daemon.log"); };
+destination kern { file("/var/log/kern.log"); file("/dev/tty12"); };
+destination lpr { file("/var/log/lpr.log"); };
+destination user { file("/var/log/user.log"); };
+destination uucp { file("/var/log/uucp.log"); };
+#destination ppp { file("/var/log/ppp.log"); };
+destination mail { file("/var/log/mail.log"); };
+
+destination avc { file("/var/log/avc.log"); };
+destination audit { file("/var/log/audit.log"); };
+destination pax { file("/var/log/pax.log"); };
+destination grsec { file("/var/log/grsec.log"); };
+
+destination mailinfo { file("/var/log/mail.info"); };
+destination mailwarn { file("/var/log/mail.warn"); };
+destination mailerr { file("/var/log/mail.err"); };
+
+destination newscrit { file("/var/log/news/news.crit"); };
+destination newserr { file("/var/log/news/news.err"); };
+destination newsnotice { file("/var/log/news/news.notice"); };
+
+destination debug { file("/var/log/debug"); };
+destination messages { file("/var/log/messages"); };
+destination console { usertty("root"); };
+destination console_all { file("/dev/tty12"); };
+#destination loghost { udp("loghost" port(999)); };
+
+destination xconsole { pipe("/dev/xconsole"); };
+
+filter f_auth { facility(auth); };
+filter f_authpriv { facility(auth, authpriv); };
+filter f_syslog { not facility(authpriv, mail); };
+filter f_cron { facility(cron); };
+filter f_daemon { facility(daemon); };
+filter f_kern { facility(kern); };
+filter f_lpr { facility(lpr); };
+filter f_mail { facility(mail); };
+filter f_user { facility(user); };
+filter f_uucp { facility(uucp); };
+#filter f_ppp { facility(ppp); };
+filter f_news { facility(news); };
+filter f_debug { not facility(auth, authpriv, news, mail); };
+filter f_messages { level(info..warn)
+ and not facility(auth, authpriv, mail, news); };
+filter f_emergency { level(emerg); };
+
+filter f_info { level(info); };
+
+filter f_notice { level(notice); };
+filter f_warn { level(warn); };
+filter f_crit { level(crit); };
+filter f_err { level(err); };
+
+filter f_avc { message(".*avc: .*"); };
+filter f_audit { message("^(\\[.*\..*\] |)audit.*") and not message(".*avc: .*"); };
+filter f_pax { message("^(\\[.*\..*\] |)PAX:.*"); };
+filter f_grsec { message("^(\\[.*\..*\] |)grsec:.*"); };
+
+log { source(src); filter(f_authpriv); destination(authlog); };
+log { source(src); filter(f_syslog); destination(_syslog); };
+log { source(src); filter(f_cron); destination(cron); };
+log { source(src); filter(f_daemon); destination(daemon); };
+log { source(kernsrc); filter(f_kern); destination(kern); };
+log { source(src); filter(f_lpr); destination(lpr); };
+log { source(src); filter(f_mail); destination(mail); };
+log { source(src); filter(f_user); destination(user); };
+log { source(src); filter(f_uucp); destination(uucp); };
+log { source(kernsrc); filter(f_pax); destination(pax); };
+log { source(kernsrc); filter(f_grsec); destination(grsec); };
+log { source(kernsrc); filter(f_audit); destination(audit); };
+log { source(kernsrc); filter(f_avc); destination(avc); };
+log { source(src); filter(f_mail); filter(f_info); destination(mailinfo); };
+log { source(src); filter(f_mail); filter(f_warn); destination(mailwarn); };
+log { source(src); filter(f_mail); filter(f_err); destination(mailerr); };
+log { source(src); filter(f_news); filter(f_crit); destination(newscrit); };
+log { source(src); filter(f_news); filter(f_err); destination(newserr); };
+log { source(src); filter(f_news); filter(f_notice); destination(newsnotice); };
+log { source(src); filter(f_debug); destination(debug); };
+log { source(src); filter(f_messages); destination(messages); };
+log { source(src); filter(f_emergency); destination(console); };
+#log { source(src); filter(f_ppp); destination(ppp); };
+log { source(src); destination(console_all); };
diff --git a/app-admin/syslog-ng/files/3.4/syslog-ng.confd b/app-admin/syslog-ng/files/3.4/syslog-ng.confd
new file mode 100644
index 000000000000..6a437d1bf36f
--- /dev/null
+++ b/app-admin/syslog-ng/files/3.4/syslog-ng.confd
@@ -0,0 +1,42 @@
+# Config file for /etc/init.d/syslog-ng
+
+# If you are not using network logging, this entire section should be
+# commented out. Otherwise, choose one of the settings below based on
+# how you are configuring your network.
+#
+# If you are using the net.* scripts to configure your network, you should
+# set rc_need to match the interface through which your logging server
+# can be reached.
+#rc_need="net.eth0"
+#
+# If you are using an interface manager like wicd, dhcpcd in standalone
+# mode, networkmanager, etc to control your interfaces, set rc_need to
+# the name of that service.
+# rc_need="dhcpcd"
+#rc_need="networkmanager"
+#
+# If you are using newnet and configuring your interface statically with
+# the network script, you should use this setting.
+#rc_need="network"
+#
+# You can use this setting, but I do not recommend relying on it.
+#rc_need="net"
+#
+# You may also want to uncomment the following if you are using network
+# logging.
+#rc_use="stunnel"
+
+# For very customized setups these variables can be adjusted as needed
+# but for most situations they should remain commented:
+# SYSLOG_NG_CONFIGFILE=/etc/syslog-ng/syslog-ng.conf
+# SYSLOG_NG_STATEFILE_DIR=/var/lib/syslog-ng
+# SYSLOG_NG_STATEFILE=${SYSLOG_NG_STATEFILE_DIR}/syslog-ng.persist
+# SYSLOG_NG_PIDFILE_DIR=/var/run
+# SYSLOG_NG_PIDFILE=${SYSLOG_NG_PIDFILE_DIR}/syslog-ng.pid
+# SYSLOG_NG_GROUP=root
+# SYSLOG_NG_USER=root
+
+# Put any additional options for syslog-ng here.
+# See syslog-ng(8) for more information.
+
+SYSLOG_NG_OPTS=""
diff --git a/app-admin/syslog-ng/files/3.4/syslog-ng.rc6 b/app-admin/syslog-ng/files/3.4/syslog-ng.rc6
new file mode 100644
index 000000000000..152bdd30ad36
--- /dev/null
+++ b/app-admin/syslog-ng/files/3.4/syslog-ng.rc6
@@ -0,0 +1,64 @@
+#!/sbin/runscript
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/files/3.4/syslog-ng.rc6,v 1.1 2013/04/28 04:50:34 mr_bones_ Exp $
+
+SYSLOG_NG_CONFIGFILE=${SYSLOG_NG_CONFIGFILE:-/etc/syslog-ng/${RC_SVCNAME}.conf}
+SYSLOG_NG_STATEFILE_DIR=${SYSLOG_NG_PIDFILE_DIR:-/var/lib/syslog-ng}
+SYSLOG_NG_STATEFILE=${SYSLOG_NG_STATEFILE:-${SYSLOG_NG_STATEFILE_DIR}/syslog-ng.persist}
+SYSLOG_NG_PIDFILE_DIR=${SYSLOG_NG_PIDFILE_DIR:-/var/run}
+SYSLOG_NG_PIDFILE=${SYSLOG_NG_PIDFILE:-${SYSLOG_NG_PIDFILE_DIR}/${RC_SVCNAME}.pid}
+
+SYSLOG_NG_GROUP=${SYSLOG_NG_GROUP:-root}
+SYSLOG_NG_USER=${SYSLOG_NG_USER:-root}
+
+command="syslog-ng"
+command_args="--persist-file \"${SYSLOG_NG_STATEFILE}\" --cfgfile \"${SYSLOG_NG_CONFIGFILE}\" --pidfile \"${SYSLOG_NG_PIDFILE}\" ${SYSLOG_NG_OPTS}"
+extra_commands="checkconfig"
+extra_started_commands="reload"
+pidfile="${SYSLOG_NG_PIDFILE}"
+start_stop_daemon_args="--user \"${SYSLOG_NG_USER}\":\"${SYSLOG_NG_GROUP}\""
+description="Syslog-ng is a syslog replacement with advanced filtering features."
+description_checkconfig="Check the configuration file that will be used by \"start\""
+description_reload="Reload the configuration without exiting"
+
+depend() {
+ if [ ! -e "${SYSLOG_NG_CONFIGFILE}" ] ; then
+ eerror "You need to create ${SYSLOG_NG_CONFIGFILE} first."
+ eerror "An example can be found in /usr/share/doc/syslog"
+
+ return 1
+ fi
+ config "${SYSLOG_NG_CONFIGFILE}"
+ use clock
+ need hostname localmount
+ after bootmisc
+ provide logger
+}
+
+checkconfig() {
+ ebegin "Checking your configfile (${SYSLOG_NG_CONFIGFILE})"
+ syslog-ng -s -f "${SYSLOG_NG_CONFIGFILE}"
+ eend $? "Configuration error. Please fix your configfile (${SYSLOG_NG_CONFIGFILE})"
+}
+
+start_pre() {
+ checkconfig || return 1
+ checkpath \
+ -d \
+ --mode 0600 \
+ --owner "${SYSLOG_NG_OWNER}:${SYSLOG_NG_GROUP}" \
+ "${SYSLOG_NG_STATEFILE_DIR}"
+}
+
+stop_pre() {
+ [ "$RC_CMD" = restart ] && sleep 1
+ return 0
+}
+
+reload() {
+ checkconfig || return 1
+ ebegin "Reloading configuration and re-opening log files"
+ start-stop-daemon --signal HUP --pidfile "${pidfile}"
+ eend $?
+}
diff --git a/app-admin/syslog-ng/files/syslog-ng.rc6.3.3 b/app-admin/syslog-ng/files/syslog-ng.rc6.3.3
index c77984ef92bc..5b966cb27e4e 100644
--- a/app-admin/syslog-ng/files/syslog-ng.rc6.3.3
+++ b/app-admin/syslog-ng/files/syslog-ng.rc6.3.3
@@ -1,7 +1,7 @@
#!/sbin/runscript
-# Copyright 1999-2011 Gentoo Foundation
+# Copyright 1999-2013 Gentoo Foundation
# Distributed under the terms of the GNU General Public License v2
-# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/files/syslog-ng.rc6.3.3,v 1.2 2011/10/19 06:19:38 mr_bones_ Exp $
+# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/files/syslog-ng.rc6.3.3,v 1.3 2013/04/28 04:50:34 mr_bones_ Exp $
extra_commands="checkconfig"
extra_started_commands="reload"
@@ -29,6 +29,7 @@ depend() {
config "${SYSLOG_NG_CONFIGFILE}"
use clock
need hostname localmount
+ after bootmisc
provide logger
}
diff --git a/app-admin/syslog-ng/metadata.xml b/app-admin/syslog-ng/metadata.xml
index 5c33283f372b..928de283cb0c 100644
--- a/app-admin/syslog-ng/metadata.xml
+++ b/app-admin/syslog-ng/metadata.xml
@@ -6,6 +6,7 @@
<name>Michael Sterrett</name>
</maintainer>
<use>
+ <flag name='smtp'>Enable support for SMTP destinations</flag>
<flag name='spoof-source'>Enable support for spoofed source addresses</flag>
<flag name='sql'>Enable support for SQL destinations</flag>
<flag name='json'>Enable support for JSON template formatting via <pkg>dev-libs/json-glib</pkg></flag>
diff --git a/app-admin/syslog-ng/syslog-ng-3.4.1.ebuild b/app-admin/syslog-ng/syslog-ng-3.4.1.ebuild
new file mode 100644
index 000000000000..4af08cce81b5
--- /dev/null
+++ b/app-admin/syslog-ng/syslog-ng-3.4.1.ebuild
@@ -0,0 +1,115 @@
+# Copyright 1999-2013 Gentoo Foundation
+# Distributed under the terms of the GNU General Public License v2
+# $Header: /var/cvsroot/gentoo-x86/app-admin/syslog-ng/syslog-ng-3.4.1.ebuild,v 1.1 2013/04/28 04:50:35 mr_bones_ Exp $
+
+EAPI=5
+inherit autotools eutils multilib systemd
+
+MY_PV=${PV/_/}
+DESCRIPTION="syslog replacement with advanced filtering features"
+HOMEPAGE="http://www.balabit.com/network-security/syslog-ng"
+SRC_URI="http://www.balabit.com/downloads/files/syslog-ng/sources/${MY_PV}/source/syslog-ng_${MY_PV}.tar.gz"
+
+LICENSE="GPL-2+ LGPL-2.1+"
+SLOT="0"
+KEYWORDS="~alpha ~amd64 ~hppa ~ia64 ~mips ~ppc ~ppc64 ~sh ~sparc ~x86 ~x86-fbsd"
+IUSE="caps hardened ipv6 json mongodb +pcre selinux smtp spoof-source sql ssl tcpd"
+
+RDEPEND="
+ pcre? ( dev-libs/libpcre )
+ spoof-source? ( net-libs/libnet:1.1 )
+ ssl? ( dev-libs/openssl:= )
+ tcpd? ( >=sys-apps/tcp-wrappers-7.6 )
+ >=dev-libs/eventlog-0.2.12
+ >=dev-libs/glib-2.10.1:2
+ json? ( >=dev-libs/json-c-0.9 )
+ caps? ( sys-libs/libcap )
+ sql? ( >=dev-db/libdbi-0.8.3 )"
+DEPEND="${RDEPEND}
+ virtual/pkgconfig
+ sys-devel/flex"
+
+S=${WORKDIR}/${PN}-${MY_PV}
+
+src_prepare() {
+ epatch "${FILESDIR}"/${PV%.*}/${P}-rollup.patch
+ sed -i \
+ -e 's/AM_CONFIG_HEADER/AC_CONFIG_HEADERS/' \
+ configure.in || die
+ mv configure.in configure.ac || die
+ eautoreconf
+}
+
+src_configure() {
+ econf \
+ --with-ivykis=internal \
+ --with-libmongo-client=internal \
+ --sysconfdir=/etc/syslog-ng \
+ --localstatedir=/var/lib/syslog-ng \
+ --with-pidfile-dir=/var/run \
+ --with-module-dir=/usr/$(get_libdir)/syslog-ng \
+ $(systemd_with_unitdir) \
+ $(use_enable caps linux-caps) \
+ $(use_enable ipv6) \
+ $(use_enable json) \
+ $(use_enable mongodb) \
+ $(use_enable pcre) \
+ $(use_enable smtp) \
+ $(use_enable spoof-source) \
+ $(use_enable sql) \
+ $(use_enable ssl) \
+ $(use_enable tcpd tcp-wrapper)
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+
+ dodoc AUTHORS ChangeLog NEWS contrib/syslog-ng.conf* contrib/syslog2ng
+
+ # Install default configuration
+ insinto /etc/syslog-ng
+ if use hardened || use selinux ; then
+ newins "${FILESDIR}/${PV%.*}/syslog-ng.conf.gentoo.hardened" syslog-ng.conf
+ elif use userland_BSD ; then
+ newins "${FILESDIR}/${PV%.*}/syslog-ng.conf.gentoo.fbsd" syslog-ng.conf
+ else
+ newins "${FILESDIR}/${PV%.*}/syslog-ng.conf.gentoo" syslog-ng.conf
+ fi
+
+ insinto /etc/logrotate.d
+ if use hardened || use selinux ; then
+ newins "${FILESDIR}/syslog-ng.logrotate.hardened" syslog-ng
+ else
+ newins "${FILESDIR}/syslog-ng.logrotate" syslog-ng
+ fi
+
+ newinitd "${FILESDIR}/${PV%.*}/syslog-ng.rc6" syslog-ng
+ newconfd "${FILESDIR}/${PV%.*}/syslog-ng.confd" syslog-ng
+ keepdir /etc/syslog-ng/patterndb.d
+ prune_libtool_files --modules
+ rm -rf "${D}"/var
+}
+
+pkg_postinst() {
+ elog "For detailed documentation please see the upstream website:"
+ elog "http://www.balabit.com/sites/default/files/documents/syslog-ng-ose-3.4-guides/en/syslog-ng-ose-v3.4-guide-admin/html/index.html"
+
+ # bug #355257
+ if ! has_version app-admin/logrotate ; then
+ echo
+ elog "It is highly recommended that app-admin/logrotate be emerged to"
+ elog "manage the log files. ${PN} installs a file in /etc/logrotate.d"
+ elog "for logrotate to use."
+ echo
+ fi
+ if has_version sys-apps/systemd ; then
+ echo
+ elog "If you intend to use syslog-ng together with the systemd journal,"
+ elog "please be sure to configure it to listen accordingly, e.g. replace"
+ elog "unix-dgram(\"/dev/log\");"
+ elog "with"
+ elog "unix-dgram(\"/run/systemd/journal/syslog\");"
+ elog "in /etc/syslog-ng/syslog-ng.conf"
+ echo
+ fi
+}