From 6b35840508287cc979202dc10e9ba41fe9f162b3 Mon Sep 17 00:00:00 2001 From: Dirk von Suchodoletz Date: Tue, 7 Mar 2006 23:53:39 +0000 Subject: generate passwd/shadow from initrd ... git-svn-id: http://svn.openslx.org/svn/openslx/dxs/ld4@94 95ad53e4-c205-0410-b2fa-d234c58c8868 --- initrd/initrd-stuff/etc/functions | 9 +++++++++ initrd/initrd-stuff/etc/machine-setup | 4 +++- 2 files changed, 12 insertions(+), 1 deletion(-) (limited to 'initrd/initrd-stuff/etc') diff --git a/initrd/initrd-stuff/etc/functions b/initrd/initrd-stuff/etc/functions index e80fdc67..90ded7fd 100644 --- a/initrd/initrd-stuff/etc/functions +++ b/initrd/initrd-stuff/etc/functions @@ -361,6 +361,15 @@ error " The configuration via ldap is not implemented yet." echo "not implemented" > /tmp/ldap-done } +####################################################################### +# base passwd/shadow, the standard user present in every system. All +# other system users should be generated within the service function +basepasswd () { +echo -e "root:x:0:0:System Administrator:/root:/bin/bash" \ + > /mnt/etc/passwd +echo -e "root:"$root_pw":12958:0:10000::::" > /mnt/etc/shadow +} + ####################################################################### # localization simply derived from $language variable set in # machine-setup or other sources - mostly taken from knoppix diff --git a/initrd/initrd-stuff/etc/machine-setup b/initrd/initrd-stuff/etc/machine-setup index d9205997..35dc5a9c 100644 --- a/initrd/initrd-stuff/etc/machine-setup +++ b/initrd/initrd-stuff/etc/machine-setup @@ -6,7 +6,7 @@ # New settings are simply appended, so that they might # overwrite previously defined variables # -# Author(s): Dirk von Suchodoletz , 30-01-2006 +# Author(s): Dirk von Suchodoletz , 08-03-2006 # Blabla # Blub # @@ -14,6 +14,8 @@ # # format variable="value" # +# password of system administrator (root) as crypt -> 'dxs-root' +root_pw='$2a$10$MoEYhIPZGCtR62R8UvBl3emNn2qMOuQpLQpfmNnhya4bGLhyF0pbu' ## name service configuration defaults # -- cgit v1.2.3-55-g7522