root/floppyfw/files/login.ini

Revision 1, 0.5 KB (checked in by root, 6 years ago)

First post

Line 
1#!/bin/sh -e
2
3# $Id: login.ini,v 1.2 2005/08/13 10:02:16 thomasez Exp $
4
5#
6# The "How to set up login" - file.
7#
8. /etc/config
9
10#
11# First, make the password file.
12#
13PW_F=/etc/passwd
14
15if [ "$PASSWORD" != "" ]
16 then
17  DES_PASSWORD=`cryptpw -a des $PASSWORD`
18fi
19
20# Right now, all we do it handle the DES_PASSWORD correctly:
21cp $PW_F $PW_F.org
22if [ "$DES_PASSWORD" != "" ]
23 then
24   sed -e "s:ROOTPW:$DES_PASSWORD:" $PW_F.org > $PW_F
25 else
26   sed -e "s:ROOTPW:$PASSWORD:" $PW_F.org > $PW_F
27fi
28
29rm $PW_F.org
30
31sed -i -e "s:^PASSWORD.*::" /etc/config
Note: See TracBrowser for help on using the browser.