output_log (truncated):
< 0x00000: 54 72 79 69 6e 67 20 37 33 2e 31 39 2e 32 33 37 Trying x.x.x.x
< 0x00010: 2e 35 2e 2e 2e 0d 0d 0a .x......
< 0x00000: 20 55 73 65 20 63 6f 6e 66 69 67 75 72 65 64 20 Use configured
< 0x00010: 73 6f 75 72 63 65 20 69 6e 74 65 72 66 61 63 65 source interface
< 0x00020: 28 4c 6f 6f 70 62 61 63 6b 30 29 2e 0d 0d 0a (Loopback0)....
< 0x00000: 20 55 73 65 20 36 38 2e 38 37 2e 32 35 33 2e 34 Use x.x.x.x
< 0x00010: 20 61 73 20 6c 6f 63 61 6c 20 61 64 64 72 65 73 as local addres
< 0x00020: 73 2e 0d 0d 0a s....
< 0x00000: 43 6f 6e 6e 65 63 74 65 64 20 74 6f 20 37 33 2e Connected to x.
< 0x00010: 31 39 2e 32 33 37 2e 35 2e 0d 0d 0a 45 73 63 61 x.x.x....Esca
< 0x00020: 70 65 20 63 68 61 72 61 63 74 65 72 20 69 73 20 pe character is
< 0x00030: xx xx xx xx xx xx xx xx '^^'....
< 0x00000: 0d 0a 0d 0a 63 65 2d 6f 72 70 6b 66 6c 68 64 30 ....xx-xxxxxxxxx
< 0x00010: 30 77 2e 63 70 65 2e 66 6c 2e 6a 61 63 6b 73 76 xx.xxx.xx.xxxxxx
< 0x00020: 69 6c 20 4c 45 2d 33 31 31 76 20 30 30 3a 30 33 il xx-xxxx xx:xx
< 0x00030: 3a 31 38 3a 66 35 3a 39 39 3a 38 30 0d 0a 0d 0a :xx:xx:xx:xx....
< 0x00040: 75 73 65 72 6e 61 6d 65 3a 20 username:
xxxxxxxxxxx@xxxxxxxxxxx:~/xxxx/xxxxxxxxxxxxxxx/xxxxxxxxxx>
####
Input_log
xxxxx:xxxxx#telnet x.x.x.x
Trying x.x.x.x...
Use configured source interface(xxxxx).
Use x.x.x.x as local address.
Connected to x.x.x.x.
Escape character is '^^'.
xxxxx xxxxx xxxxx
username:
####
$session_parent->cmd("telnet $cienaIP");
$session_parent->waitfor('/username: $/i');
$session_parent->print($username);
# $session_parent->print('username'); I've tried this
# $session_parent->cmd($username); I've tried this
# $session_parent->login($username,$password); I've tried this
# I've tried very long regex expressions thinking that maybe I need to match
# the whole expression "Trying x.x.x.x Use configured....username: " output
# but that hasn't helped either.