Page MenuHomeFreeBSD

D41768.id127033.diff
No OneTemporary

D41768.id127033.diff

diff --git a/libexec/save-entropy/Makefile b/libexec/save-entropy/Makefile
--- a/libexec/save-entropy/Makefile
+++ b/libexec/save-entropy/Makefile
@@ -1,4 +1,5 @@
SCRIPTS= save-entropy.sh
+MAN= save-entropy.sh.1
.include <bsd.prog.mk>
diff --git a/libexec/save-entropy/save-entropy.sh.1 b/libexec/save-entropy/save-entropy.sh.1
new file mode 100644
--- /dev/null
+++ b/libexec/save-entropy/save-entropy.sh.1
@@ -0,0 +1,94 @@
+.\"
+.\" SPDX-License-Identifier: BSD-2-Clause-FreeBSD
+.\"
+.\" Copyright (c) 2023 Fernando Apesteguia <fernando.apesteguia@gmail.com>
+.\"
+.\" 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.
+.\"
+.\" THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``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 OR CONTRIBUTORS 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.
+.\"
+.Dd September 7, 2023
+.Dt SAVE-ENTROPY.SH 1
+.Os
+.Sh NAME
+.Nm save-entropy.sh
+.Nd Save bits of entropy to feed /dev/random on boot
+.Sh SYNOPSIS
+.Nm save-entropy.sh
+.Sh DESCRIPTION
+The
+.Nm
+command is used to save entropy data from
+.Pa /dev/random
+to a specified output file.
+The files saved are used at boot to seed
+.Pa /dev/random
+.Pp
+This script is typically invoked via
+.Xr cron 8
+every eleven minutes approximately.
+Three variables in
+.Pa /etc/rc.conf
+regulate the behavior of the script:
+.Bl -tag -width Ds
+.It Va entropy_dir
+Specify the directory where the entropy files will be stored.
+Defaults to
+.Pa /var/db/entropy
+If set to "NO" it disables caching entropy via
+.Xr cron 8
+.It Va entropy_save_sz
+Size of the entropy cache files.
+Defaults to 4096.
+.It Va entropy_save_num
+Number of entropy cache files to save.
+Defaults to 8.
+.El
+.Sh FILES
+.Bl -tag -width Ds
+.It Pa /etc/rc.conf
+.El
+.Sh EXIT STATUS
+The
+.Nm
+command exits with the following status codes:
+.Bl -tag -width Ds
+.It 0
+No error occurred.
+.It 1
+An error occurred while saving entropy data.
+The error will be recorded in the system log.
+.El
+.Sh SEE ALSO
+.Xr syslog 3 ,
+.Xr random 4 ,
+.Xr cron 8
+.Sh HISTORY
+The
+.Nm
+command first appeared in
+.Fx 5.0 .
+.Sh AUTHORS
+The
+.Nm
+command was originally written by
+.An Doug Barton <dougb@FreeBSD.org> .
+This manual page was written by
+.An Fernando Apesteguia <fernape@FreeBSD.org> .

File Metadata

Mime Type
text/plain
Expires
Sun, Jun 14, 4:30 PM (13 h, 30 m)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
33956224
Default Alt Text
D41768.id127033.diff (3 KB)

Event Timeline