What to "expect".... ?
Available news archives: comp.lang.tcl - comp.lang.python - comp.security.firewalls - sci.crypt - comp.lang.php - comp.lang.javascript
Google
 
Web news.hping.org


comp.lang.tcl archive

What to "expect".... ?

From: dushkin <dushkin@012.net.il>
Date: Sun May 29 2005 - 10:08:16 CEST

Hi guys!
 This is an "Expect" question (if there is a better group for it - let
me know...

While stdout has this prompt:

*********************************************
Connecting to 10.106.242.91...
The authenticity of host '10.106.242.91 (10.106.242.91)' can't be
established.
RSA key fingerprint is e1:c1:00:ed:bd:62:82:24:d4:62:b3:df:f4:c3:e8:f4.
Are you sure you want to continue connecting (yes/no)?
*********************************************

I evaluate the following "expect" command:

*********************************************
expect -i exp_spawn0 -gl "yes" {set var 2} -gl "10.106.242.91" {set var
1} ... (more patterns-actions come here...) -gl "some pattern"
*********************************************

I need to find the word "yes"! But I get the IP string al the time, and
thus var is set to 1.

What is wrong here???
Thanks!!!
Received on Thu Sep 29 14:19:35 2005