home *** CD-ROM | disk | FTP | other *** search
- Path: sparky!uunet!mcsun!uknet!stl!robobar!ibmpcug!adrian
- From: adrian@ibmpcug.co.uk (Adrian Hall)
- Newsgroups: comp.unix.shell
- Subject: Re: Automating telnet
- Keywords: telnet, here documents, automatic login
- Message-ID: <Bu7E5q.64C@ibmpcug.co.uk>
- Date: 7 Sep 92 10:22:37 GMT
- References: <ellis.715831025@nova>
- Organization: The IBM PC User Group, UK.
- Lines: 27
-
- In article <ellis.715831025@nova> ellis@nova.gmi.edu (Stew Ellis) writes:
- >
- >I am trying to write a shell script to login to a remote gopher program.
- >The gopher program runs at login for user gopher, with no passwd.
- >
- >I have seen scripts before that automated ftp or telnet login, but I cannot
- >find them.
- >
- >I would have thought that telnet would read a here document in an orderly
- >fashion so something like the following would work:
- > telnet remote.host << EOF
- > loginname
- > EOF
- >
- >The man page for telnet is of no help on this. I am probably missing
- >something obvious to someone, but it is not obvious to me. :(
-
- I tend to use 'expect' for these sorts of tasks (they dont come along
- that often). Check out your local archive site for the sources.
-
- Adrian.
-
- --
- --------------------------------------------------------------------------
- Adrian Hall Connect Systems Manager
- adrian@ibmpcug.co.uk The IBM PC User Group
- Tel: +44 81 863 1191 Harrow, London, UK
-