Hi, I'm trying to ship something to a script on a remote machine via SSH and catch its output.
As an example, let's say that user foo on machine bar has "cat" defined as her shell. Thus, after connecting to bar as foo, anything that is sent to bar is sent back. Theoretically, piping something into the ssh command should result in that something being thrown back. This does indeed work as expected when using openssh's ssh client, like this: echo baz | ssh -qi IDENTITY foo@bar Trying the same with dbclient yields "Failed reading termmodes" for this command: echo baz | dbclient -i DB_IDENTITY foo@bar This points to the fact that no pty is available, which is correct, of course, and can be prevented by using the -T switch, which tells dbclient not to allocate a pty: echo baz | dbclient -T -i DB_IDENTITIY foo@bar However, this is where things go wrong. The "baz" string does still indeed arrive at the remote server and is processed by foo's shell, but is not printed by dbclient. This is unfortunate as I really need to capture the output. So, the obvious question is, how can I get to the output? THX & Cheers, Toby. -- E Pluribus Unix ---- Karlsruhe Institute of Technology (KIT) Steinbuch Centre for Computing (SCC) KIT-CERT Tobias Dussa CERT Manager, CA Manager Zirkel 2 Building 20.21 76131 Karlsruhe, Germany Phone: +49 721 608-42479 Fax: +49 721 608-9-42479 Email: [email protected] Web: http://www.kit.edu/ KIT – University of the State of Baden-Wuerttemberg and National Laboratory of the Helmholtz Association
smime.p7s
Description: S/MIME cryptographic signature
