diff -Naur busybox.orig/include/applets.h busybox/include/applets.h
--- busybox.orig/include/applets.h	2008-06-28 12:58:39 +0000
+++ busybox/include/applets.h	2008-07-01 20:52:36 +0000
@@ -324,6 +324,7 @@
 USE_SHA1SUM(APPLET_ODDNAME(sha1sum, md5_sha1_sum, _BB_DIR_USR_BIN, _BB_SUID_NEVER, sha1sum))
 USE_SLATTACH(APPLET(slattach, _BB_DIR_SBIN, _BB_SUID_NEVER))
 USE_SLEEP(APPLET_NOFORK(sleep, sleep, _BB_DIR_BIN, _BB_SUID_NEVER, sleep))
+USE_SOCKLOG(APPLET(socklog, _BB_DIR_SBIN, _BB_SUID_NEVER))
 USE_SOFTLIMIT(APPLET_ODDNAME(softlimit, chpst, _BB_DIR_USR_BIN, _BB_SUID_NEVER, softlimit))
 USE_SORT(APPLET_NOEXEC(sort, sort, _BB_DIR_USR_BIN, _BB_SUID_NEVER, sort))
 USE_SPLIT(APPLET(split, _BB_DIR_USR_BIN, _BB_SUID_NEVER))
diff -Naur busybox.orig/include/usage.h busybox/include/usage.h
--- busybox.orig/include/usage.h	2008-07-01 18:37:40 +0000
+++ busybox/include/usage.h	2008-07-01 23:32:28 +0000
@@ -3577,6 +3577,13 @@
        "$ sleep 1d 3h 22m 8s\n" \
        "[98528 second delay results]\n")
 
+#define socklog_trivial_usage \
+	"[-rRU] [unix|inet|ucspi] [args]"
+#define socklog_full_usage "\n\n" \
+	"-rRU [unix] [path]\n" \
+	"-rR inet [ip [port]]\n" \
+	"-rR ucspi [ENVVAR] [ENVVAR] ...\n" \
+
 #define sort_trivial_usage \
        "[-nru" \
 	USE_FEATURE_SORT_BIG("gMcszbdfimSTokt] [-o FILE] [-k start[.offset][opts][,end[.offset][opts]] [-t CHAR") \
diff -Naur busybox.orig/runit/Config.in busybox/runit/Config.in
--- busybox.orig/runit/Config.in	2008-02-17 06:50:59 +0000
+++ busybox/runit/Config.in	2008-07-01 23:30:10 +0000
@@ -20,6 +20,20 @@
 	  a directory, in the services directory dir, up to a limit of 1000
 	  subdirectories, and restarts a runsv process if it terminates.
 
+config SOCKLOG
+	bool "socklog"
+	default n
+	help
+	  socklog reads lines from /dev/log, UDP socket or stdin, optionally
+	  prepends the lines and dumps the result to stdout.
+
+config FEATURE_SOCKLOG_HUMAN_FRIENDLY
+	bool "human readable facilities and priorities"
+	default n
+	depends on SOCKLOG
+	help
+	  Enable translation of raw messages. Bloaty.
+
 config SV
 	bool "sv"
 	default n
diff -Naur busybox.orig/runit/Kbuild busybox/runit/Kbuild
--- busybox.orig/runit/Kbuild	2008-02-17 06:50:59 +0000
+++ busybox/runit/Kbuild	2008-07-01 20:52:36 +0000
@@ -15,3 +15,5 @@
 lib-$(CONFIG_ENVUIDGID) += chpst.o
 lib-$(CONFIG_SETUIDGID) += chpst.o
 lib-$(CONFIG_SOFTLIMIT) += chpst.o
+
+lib-$(CONFIG_SOCKLOG) += socklog.o
diff -Naur busybox.orig/runit/socklog.c busybox/runit/socklog.c
--- busybox.orig/runit/socklog.c	1970-01-01 00:00:00 +0000
+++ busybox/runit/socklog.c	2008-07-01 23:35:08 +0000
@@ -0,0 +1,127 @@
+/*
+Copyright (c) 2001-2005, Gerrit Pape
+All rights reserved.
+
+Redistribution and use in source and binary forms, with or without
+modification, are permitted provided that the following conditions are met:
+
+   1. Redistributions of source code must retain the above copyright notice,
+      this list of conditions and the following disclaimer.
+   2. Redistributions in binary form must reproduce the above copyright
+      notice, this list of conditions and the following disclaimer in the
+      documentation and/or other materials provided with the distribution.
+   3. The name of the author may not be used to endorse or promote products
+      derived from this software without specific prior written permission.
+
+THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR IMPLIED
+WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
+MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO
+EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
+PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
+OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
+WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
+OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
+ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+*/
+
+/*
+ * Busybox version of Gerrit Pape's http://smarden.org/socklog/
+ *
+ * Busyboxed by Vladimir Dronnikov <dronnikov@gmail.com>
+*/
+
+/*
+socklog -rRU [unix] [path]
+socklog -rR inet [ip [port]]
+socklog -rR ucspi [ENVVAR] [ENVVAR] ...
+*/
+
+#include "libbb.h"
+
+#if ENABLE_FEATURE_SOCKLOG_HUMAN_FRIENDLY
+#define SYSLOG_NAMES
+#include <sys/syslog.h>
+
+static const char *name(CODE *codes, int val)
+{
+	const char *s = "unknown";
+	for (CODE *c = codes; c->c_name; c++)
+		if (val == c->c_val) {
+			s = c->c_name;
+			break;
+		}
+	return s;
+}
+#else
+#define _PATH_LOG "/dev/log"
+#endif
+
+int socklog_main(int argc, char **argv) MAIN_EXTERNALLY_VISIBLE;
+int socklog_main(int argc UNUSED_PARAM, char **argv)
+{
+#define buf bb_common_bufsiz1
+
+	getopt32(argv, "rRU"); // FIXME: they all are ignored
+	argv += optind;
+
+	// unix
+	if (!*argv || 'u' != *argv[0]) {
+		const char *input = (*argv) ? *argv : _PATH_LOG; // /dev/log
+		if (!freopen(input, "r", stdin))
+			bb_perror_msg_and_die("open %s", input);
+		*argv = NULL; // no further arguments
+	// inet
+	} else if ('i' == *argv[0]) {
+		const char *host = (*++argv) ? *argv : "127.0.0.1";
+		unsigned port = (*++argv) ? xatou_range(*argv, 1, 65535) : 514;
+		xmove_fd(create_and_bind_dgram_or_die(host, port), STDIN_FILENO);
+		*argv = NULL; // no further arguments
+	// ucspi
+	} else {
+		// point to prefix
+		argv++;
+	}
+
+	// dump lines read from stdin optionally prefixing them
+	// N.B. we want line buffering
+	setvbuf(stdout, NULL, _IOLBF, 0);
+
+	// N.B. COMMON_BUFSIZE is long enough
+	while (fgets(buf, COMMON_BUFSIZE, stdin) != 0) {
+		for (char **var = argv; *var; var++) {
+			char *val = getenv(*var);
+			if (val && *val)
+				printf("%s: ", val);
+		}
+#if ENABLE_FEATURE_SOCKLOG_HUMAN_FRIENDLY
+		{
+			unsigned f = 0, p = 0;
+			char *s = buf;
+			// messages are optionally prefixed with <raw_decimal_number>
+			// if so that number is (facility << 3 | priority)
+			// fetch facility and priority ...
+			if ('<' == *s) {
+				f = strtoul(s+1, &s, 10);
+				p = f & 7;
+				f >>= 3;
+				// and skip <raw_decimal_number> prefix
+				s++;
+			}
+			// dump line
+			printf("%s:%s: %s",
+				name(facilitynames, f),
+				name(prioritynames, p),
+				s); // \n included
+		}
+#else
+		{
+			// dump line
+			printf(buf); // \n included
+		}
+		//fflush(stdout);
+	}
+#endif
+
+	return EXIT_SUCCESS;
+}
