Automated Login Example

published 3/10/2006

this is a small script for automated login,
can be used for regular maintenance or something…

#!/bin/sh
#
#
server=x.x.x.x

(
   sleep 2;
   echo "username";
   sleep 2;
   echo "password";
   sleep 2;
   echo "do some manipulations in the session";
   sleep 3;
   echo "exit";
) | telnet $server