All of lore.kernel.org
 help / color / mirror / Atom feed
* [Buildroot] [PATCHv2] haveged: new package
@ 2013-11-19 12:10 Gustavo Zacarias
  2013-11-19 12:27 ` Peter Korsgaard
  2013-11-22 22:35 ` Yann E. MORIN
  0 siblings, 2 replies; 3+ messages in thread
From: Gustavo Zacarias @ 2013-11-19 12:10 UTC (permalink / raw)
  To: buildroot

Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
---
 package/Config.in          |  1 +
 package/haveged/Config.in  |  9 +++++++++
 package/haveged/S21haveged | 25 +++++++++++++++++++++++++
 package/haveged/haveged.mk | 17 +++++++++++++++++
 4 files changed, 52 insertions(+)
 create mode 100644 package/haveged/Config.in
 create mode 100755 package/haveged/S21haveged
 create mode 100644 package/haveged/haveged.mk

diff --git a/package/Config.in b/package/Config.in
index e7b29b0..de4e966 100644
--- a/package/Config.in
+++ b/package/Config.in
@@ -751,6 +751,7 @@ source "package/bc/Config.in"
 source "package/collectd/Config.in"
 source "package/empty/Config.in"
 source "package/googlefontdirectory/Config.in"
+source "package/haveged/Config.in"
 source "package/mcrypt/Config.in"
 source "package/mobile-broadband-provider-info/Config.in"
 source "package/shared-mime-info/Config.in"
diff --git a/package/haveged/Config.in b/package/haveged/Config.in
new file mode 100644
index 0000000..0e49a2d
--- /dev/null
+++ b/package/haveged/Config.in
@@ -0,0 +1,9 @@
+config BR2_PACKAGE_HAVEGED
+	bool "haveged"
+	depends on BR2_USE_MMU # fork()
+	help
+	  The haveged project is an attempt to provide an easy-to-use,
+	  unpredictable random number generator based upon an adaptation
+	  of the HAVEGE algorithm.
+
+	  http://www.issihosts.com/haveged/
diff --git a/package/haveged/S21haveged b/package/haveged/S21haveged
new file mode 100755
index 0000000..f17cd29
--- /dev/null
+++ b/package/haveged/S21haveged
@@ -0,0 +1,25 @@
+#!/bin/sh
+
+[ -x /usr/sbin/haveged ] || exit 0
+
+case "$1" in
+	start)
+		echo -n "Starting haveged: "
+		start-stop-daemon -S -x /usr/sbin/haveged -- -w 1024 -r 0
+		[ $? == 0 ] && echo "OK" || echo "FAIL"
+		;;
+	stop)
+		echo -n "Stopping haveged: "
+		start-stop-daemon -K -x /usr/sbin/haveged
+		[ $? == 0 ] && echo "OK" || echo "FAIL"
+		;;
+	restart|reload)
+		$0 stop
+		$0 start
+		;;
+	*)
+		echo "Usage: $0 {start|stop|restart}"
+		exit 1
+esac
+
+exit 0
diff --git a/package/haveged/haveged.mk b/package/haveged/haveged.mk
new file mode 100644
index 0000000..99dbe41
--- /dev/null
+++ b/package/haveged/haveged.mk
@@ -0,0 +1,17 @@
+################################################################################
+#
+# haveged
+#
+################################################################################
+
+HAVEGED_VERSION = 1.7c
+HAVEGED_SITE = http://www.issihosts.com/haveged
+HAVEGED_LICENSE = GPLv3+
+HAVEGED_LICENSE_FILES = COPYING
+
+define HAVEGED_INSTALL_INIT_SYSV
+	$(INSTALL) -m 755 -D package/haveged/S21haveged \
+		$(TARGET_DIR)/etc/init.d/S21haveged
+endef
+
+$(eval $(autotools-package))
-- 
1.8.3.2

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* [Buildroot] [PATCHv2] haveged: new package
  2013-11-19 12:10 [Buildroot] [PATCHv2] haveged: new package Gustavo Zacarias
@ 2013-11-19 12:27 ` Peter Korsgaard
  2013-11-22 22:35 ` Yann E. MORIN
  1 sibling, 0 replies; 3+ messages in thread
From: Peter Korsgaard @ 2013-11-19 12:27 UTC (permalink / raw)
  To: buildroot

>>>>> "Gustavo" == Gustavo Zacarias <gustavo@zacarias.com.ar> writes:

 > Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>

Committed to next, thanks.

-- 
Bye, Peter Korsgaard

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [Buildroot] [PATCHv2] haveged: new package
  2013-11-19 12:10 [Buildroot] [PATCHv2] haveged: new package Gustavo Zacarias
  2013-11-19 12:27 ` Peter Korsgaard
@ 2013-11-22 22:35 ` Yann E. MORIN
  1 sibling, 0 replies; 3+ messages in thread
From: Yann E. MORIN @ 2013-11-22 22:35 UTC (permalink / raw)
  To: buildroot

Gustavo, All,

On 2013-11-19 09:10 -0300, Gustavo Zacarias spake thusly:
> Signed-off-by: Gustavo Zacarias <gustavo@zacarias.com.ar>
> +	help
> +	  The haveged project is an attempt to provide an easy-to-use,
> +	  unpredictable random number generator based upon an adaptation
> +	  of the HAVEGE algorithm.

There was a talk at LinuxCon 2012 (last year) in Barcelonna, by H Peter
Anvin, titled "Don't play dice with random numbers", where he said he
was very skeptic about HAVEGE:
    https://lwn.net/Articles/525459/

Quote:
    Most of the papers that he has read run along the lines, "we took the
    output from HAVEGE, and ran some tests on it and all of the tests passed".

    One of Peter's colleagues replaced the random input source employed
    by HAVEGE with a constant stream of ones. All of the same tests passed.

    So, while I can't really recommend it, I can't not recommend it either.

Thought I would mention it.

Regards,
Yann E. MORIN.

-- 
.-----------------.--------------------.------------------.--------------------.
|  Yann E. MORIN  | Real-Time Embedded | /"\ ASCII RIBBON | Erics' conspiracy: |
| +33 662 376 056 | Software  Designer | \ / CAMPAIGN     |  ___               |
| +33 223 225 172 `------------.-------:  X  AGAINST      |  \e/  There is no  |
| http://ymorin.is-a-geek.org/ | _/*\_ | / \ HTML MAIL    |   v   conspiracy.  |
'------------------------------^-------^------------------^--------------------'

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2013-11-22 22:35 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-11-19 12:10 [Buildroot] [PATCHv2] haveged: new package Gustavo Zacarias
2013-11-19 12:27 ` Peter Korsgaard
2013-11-22 22:35 ` Yann E. MORIN

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.