diff options
Diffstat (limited to 'app-admin/pwgen/files')
-rw-r--r-- | app-admin/pwgen/files/2.06-special-char.patch | 11 | ||||
-rw-r--r-- | app-admin/pwgen/files/pwgen.rc | 18 |
2 files changed, 29 insertions, 0 deletions
diff --git a/app-admin/pwgen/files/2.06-special-char.patch b/app-admin/pwgen/files/2.06-special-char.patch new file mode 100644 index 000000000000..3d014fa4bf11 --- /dev/null +++ b/app-admin/pwgen/files/2.06-special-char.patch @@ -0,0 +1,11 @@ +--- a/pwgen.c ++++ b/pwgen.c +@@ -138,7 +138,7 @@ int main(int argc, char **argv) + break; + case 's': + pwgen = pw_rand; +- pwgen_flags = PW_DIGITS | PW_UPPERS; ++ pwgen_flags |= PW_DIGITS | PW_UPPERS; + break; + case 'C': + do_columns = 1; diff --git a/app-admin/pwgen/files/pwgen.rc b/app-admin/pwgen/files/pwgen.rc new file mode 100644 index 000000000000..94c4067e2faf --- /dev/null +++ b/app-admin/pwgen/files/pwgen.rc @@ -0,0 +1,18 @@ +#!/sbin/openrc-run +# Copyright 1999-2004 Gentoo Foundation +# Distributed under the terms of the GNU General Public License v2 + +depend() { + before local +} + +start() { + ebegin "Auto-scrambling root password for security" + echo root:`pwgen -s 16` | chpasswd > /dev/null 2>&1 + eend $? "Failed to scramble root password." +} + +stop() { + ebegin "Stopping pwgen" + eend $? "Failed to stop pwgen." +} |