Re: SSH pipe probelm

From: Chris Nystrom (cnystrom_at_gmail.com)
Date: 11/26/04


Date: 26 Nov 2004 03:17:32 -0800

Gary Tay Teng Teck <garyttt@singnet.com.sg> wrote in message news:<41a5e548@news.starhub.net.sg>...
> Chris Nystrom wrote:
> > I have a graphical application and I want to use ssh as the backend,
> > and also have this transparent to the users for ease of use (ie, I
> > don't want to force users to install public keys).
> >
> > Everything works great, except for when ssh asks for the password.
> > Apparently ssh forces input from the TTY and redirecting STDIO does
> > not help. I have the password, but I do not want to force my
> > application users to go to the command line to type it in. How can I
> > get this password to the ssh process?
> >
> > Is there any work around to this issue, or has anyone already solved
> > this in some way?
>
> May be u could use "expect", I have never used it.
>
> http://expect.nist.gov/

Which leads natually to the next question: How does expect do it? :)

I am playing around with calling an expect script from my C program,
but so far no go. SSH does not like it when there is no pty
allocated...

Chris



Relevant Pages

  • Re: SSH pipe problem
    ... Chris Nystrom wrote: ... > I have a graphical application and I want to use ssh as the backend, ... > and also have this transparent to the users for ease of use (ie, ... except for when ssh asks for the password. ...
    (comp.unix.programmer)
  • Re: SSH pipe problem
    ... Chris Nystrom wrote: ... Read the thread in this group titled "Creating a tty in a C program." ... except for when ssh asks for the password. ... > int i; ...
    (comp.unix.programmer)
  • Re: SSH pipe probelm
    ... Chris Nystrom wrote: ... > and also have this transparent to the users for ease of use (ie, ... except for when ssh asks for the password. ... > int i; ...
    (comp.security.ssh)