Operating System - HP-UX
1833467 Members
3817 Online
110052 Solutions
New Discussion

Auto - Password in system start-up script

 
Michael Tully
Honored Contributor

Auto - Password in system start-up script

I have a script that needs to run at system start-up time that requires a password entered automatically at the very end. I was wondering what you think would be the best method to accomplish this feat and how. I know of expect/perl etc but I was wondering what the preferences would be.

All suggestions will be handsomely rewarded.
(please no auditors!)

Anyone for a Mutiny ?
4 REPLIES 4
Stefan Farrelly
Honored Contributor

Re: Auto - Password in system start-up script

We have lots of strange applications that require a password when connecting to them to startup and we normally simply echo the necessary into the startup script, eg;
echo "login\npassword\nstartup" |
Im from Palmerston North, New Zealand, but somehow ended up in London...
Deepak Extross
Honored Contributor

Re: Auto - Password in system start-up script

Well, the "correct" way would be to use Expect, but for the sake of simplicity, why not just do the following:
# myscript < input_file

where input_file is a simple file containing the password.

You can protect the input_file as appropriate (permissions, making it a hidden file, etc).
Michael Tully
Honored Contributor

Re: Auto - Password in system start-up script

Back to the top.... no one is going to see it on page 4....
Anyone for a Mutiny ?
Tom Geudens
Honored Contributor

Re: Auto - Password in system start-up script

Hi Michael,
We used to work as follows :
All those "once set, easily forgotten" passwords got put in files in a /security directory. Typically you would find files of the following form there :
._
._
Each containing the necessary logonstrings ...
Needless to say /security was guarded pretty well :-). Our C-guru's wrote an "ASS" (Application Security Server) that could pick up user/password combinations from that directory (we had some good laughs about the "ASS" ... but that's another story :-).

This got shot down because somebody forgot to tell our auditors that /security is also included in the backups. Anyone with a bit of backupknowledge could find the last 20 passwordchanges ... not good.

We still use the "ASS", but nowadays it does no longer pick up the passwords from the Unixsystem itself, but from a sort of LDAPdatabase that uses encryption worthy of th e NSA :-).
Drawback of this new system : if the "ASS" or the LDAPdatabase goes down ... there is no way to find those passwords. Needless to say that our auditors do not think that's a drawback.

Regards,
Tom
A life ? Cool ! Where can I download one of those from ?