Automating interactive sessions

From: FET (bilaribilari_at_yahoo.com)
Date: 02/14/05


Date: 13 Feb 2005 23:20:36 -0800

Hi,
I am trying to execute a certain command using a shell script. The
command prompts for a password. The command does not have any switches
for accepting the password on the command line. I am passing the
password to the shell script as an argument.

Is there any way to pass the password to the command without getting
the prompt? or perhaps trapping the prompt in the shell somehow and
supplying the password.

Thanks in advance.
Best regards.



Relevant Pages

  • Re: ssh via gateway to work host script
    ... I am writing a shell script to connect to my work computer. ... I get the following prompt (of course with real values but just as a ... I generate a password and input it at the command line. ... use autossh to open a reverse ssh tunnel from ...
    (comp.unix.shell)
  • print subsystem errors
    ... I have an application that executes a shell script to print jobs. ... I can take the same command issued in the shell script; ... ATTENTION ATTENTION ATTENTION ATTENTION ATTENTION ...
    (AIX-L)
  • Re: despair
    ... I once tried to write a cd program in Unix. ... Just putting a cd command in a script and then ... hell are you supposed to write shell script macros to run a frequently ... make "$ FOO BAR" a meaningful DCL command. ...
    (comp.os.vms)
  • Re: cron and command quote
    ... if you are going to be using a shell script you have to make sure that it exits properly. ... So, '||' is just as legal as '&&' and would do just as it does on the command line, assuming of course there is nothing found by the grep. ... with && we have execute command1 if it returns true execute command2 ... To UNSUBSCRIBE, email to debian-user-REQUEST@xxxxxxxxxxxxxxxx with a subject of "unsubscribe". ...
    (Debian-User)
  • Re: Oracle dbi ?
    ... Can you execute a command line ... > shell script using OCI? ... Not using OCI, but Perl can run SQL*Plus very nicely. ...
    (perl.dbi.users)