Solved

Auto Telnet session to POP3 mail drop

Posted on 1998-04-01
2
335 Views
Last Modified: 2013-12-26
Hello:
I actually have two questions rolled into one situation.

I need to automate a telnet connection from a UNIX box to a POP3 compliant mail server.

Obviously, I need to pass a username:password pair to the Mail daemon.. but how?  Then I need to have the mail deamon send all messages to the UNIX box from which I'm invoking this capability.

I was hoping a meta-character coupled with the RETR command would work (RETR *)... but it does not. <duh>

Can anyone offer assistance?

Thanks.

0
Comment
Question by:xtian120897
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
2 Comments
 
LVL 2

Accepted Solution

by:
seedy earned 120 total points
ID: 1296221
There is no straight forward shell script based solution
for this - atleast in my opinion.    The reason being
you cannot redirect input to commands like telent from normal
files are pipes - they do a lot of ioctl calls that fail on the
normal files.

You could write a small 'c' program that
  1. open pty (read man pages for more details)
  2. fork and exec telnet
  3. communicate to the telnet thru the pty
  4. send USER, PASS commands to the authenticate
  5. send RETR command to retrieve.

One more point, you cannot use RETR *.  You must sepcify
a message/mail number.  You normally would use LIST and then
RETR for the messages 'listed'.
Hope this helps.
-Seedy-
 
0
 
LVL 2

Expert Comment

by:seedy
ID: 1296222
Sorry, I lost the big picture here.  Your intention is to get
all the mails down to your UNIX box.  It is rather
easily done through making a socket connection than
through the 'pty' and telnet.
Cheers,
-Chellah-
0

Featured Post

Free Tool: ZipGrep

ZipGrep is a utility that can list and search zip (.war, .ear, .jar, etc) archives for text patterns, without the need to extract the archive's contents.

One of a set of tools we're offering as a way to say thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
How to know only "File created" with EventLog 3 35
twoTwo  challenge 35 118
tripleUp challenge 7 95
Bartender label printing - switch on and off graphics 3 91
Here is how to use MFC's automatic Radio Button handling in your dialog boxes and forms.  Beginner programmers usually start with a OnClick handler for each radio button and that's just not the right way to go.  MFC has a very cool system for handli…
Introduction: Ownerdraw of the grid button.  A singleton class implentation and usage. Continuing from the fifth article about sudoku.   Open the project in visual studio. Go to the class view – CGridButton should be visible as a class.  R…
This video will show you how to get GIT to work in Eclipse.   It will walk you through how to install the EGit plugin in eclipse and how to checkout an existing repository.
Exchange organizations may use the Journaling Agent of the Transport Service to archive messages going through Exchange. However, if the Transport Service is integrated with some email content management application (such as an antispam), the admini…

742 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question