summaryrefslogtreecommitdiffstats
path: root/sys/geom/eli/g_eli.c
diff options
context:
space:
mode:
authored <ed@FreeBSD.org>2010-11-14 14:12:43 +0000
committered <ed@FreeBSD.org>2010-11-14 14:12:43 +0000
commit4ee939c936810cdbeb5d64f9b2b28890e4af0814 (patch)
tree8cfc4a89bf07768ed21b9e6d521da70520fb8e36 /sys/geom/eli/g_eli.c
parentdd93d3c0fda933782c0813b9cf0b13c8c5f80054 (diff)
downloadFreeBSD-src-4ee939c936810cdbeb5d64f9b2b28890e4af0814.zip
FreeBSD-src-4ee939c936810cdbeb5d64f9b2b28890e4af0814.tar.gz
Add support for asterisk characters when filling in the GELI password
during boot. Change the last argument of gets() to indicate a visibility flag and add definitions for the numerical constants. Except for the value 2, gets() will behave exactly the same, so existing consumers shouldn't break. We only use it in two places, though. Submitted by: lme (older version)
Diffstat (limited to 'sys/geom/eli/g_eli.c')
-rw-r--r--sys/geom/eli/g_eli.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sys/geom/eli/g_eli.c b/sys/geom/eli/g_eli.c
index deffeb7..8834b86 100644
--- a/sys/geom/eli/g_eli.c
+++ b/sys/geom/eli/g_eli.c
@@ -64,11 +64,11 @@ static u_int g_eli_tries = 3;
TUNABLE_INT("kern.geom.eli.tries", &g_eli_tries);
SYSCTL_UINT(_kern_geom_eli, OID_AUTO, tries, CTLFLAG_RW, &g_eli_tries, 0,
"Number of tries for entering the passphrase");
-static u_int g_eli_visible_passphrase = 0;
+static u_int g_eli_visible_passphrase = GETS_NOECHO;
TUNABLE_INT("kern.geom.eli.visible_passphrase", &g_eli_visible_passphrase);
SYSCTL_UINT(_kern_geom_eli, OID_AUTO, visible_passphrase, CTLFLAG_RW,
&g_eli_visible_passphrase, 0,
- "Turn on echo when entering the passphrase (for debug purposes only!!)");
+ "Visibility of passphrase prompt (0 = invisible, 1 = visible, 2 = asterisk)");
u_int g_eli_overwrites = G_ELI_OVERWRITES;
TUNABLE_INT("kern.geom.eli.overwrites", &g_eli_overwrites);
SYSCTL_UINT(_kern_geom_eli, OID_AUTO, overwrites, CTLFLAG_RW, &g_eli_overwrites,
OpenPOWER on IntegriCloud