Beefy Boxes and Bandwidth Generously Provided by pair Networks Cowboy Neal with Hat
laziness, impatience, and hubris
 
PerlMonks  

Re: How to open/what cmd's for a IMAP socket to send email to an Exchange server?

by beebware (Pilgrim)
on Feb 22, 2002 at 20:49 UTC ( [id://147018]=note: print w/replies, xml ) Need Help??

This is an archived low-energy page for bots and other anonmyous visitors. Please sign up if you are a human and want to interact.


in reply to How to open/what cmd's for a IMAP socket to send email to an Exchange server?

Why not just use a standard SMTP module such as Mime::Lite, Mail::Sender or Net::SMTP? Just configure it to use the Exchange IP address, for example (MIME::Lite code follows as I like it a lot :) ):
use Mime::Lite MIME::Lite->send('smtp', $exchange_server_name_or_ip_address, TimeOut= +>60); my $msg=MIME::Lite->new ( From=>"$from_name <$from_email_address>", To =>"$to_email_address", Subject=>"$subject_of_email", Type=>'text', Data=>$body_of_email ); $msg->send;
That way you can easily change which server the mail goes out through and you don't restrict it to an IMAP only mail server. Plus Exchange has a very strange login sequence sometimes (I have to authenticate against mine in the format of 'forename.surname@localdomain.internal' or 'localdomain/forename.surname' dependent on how I'm accessing Exchange2000).
Otherwise you'll have to try Net::IMAP::Simple or Mail::IMAPClient but as I've never used either of those myself, I can't make any recommendations.
  • Comment on Re: How to open/what cmd's for a IMAP socket to send email to an Exchange server?
  • Download Code

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://147018]
help
Sections?
Information?
Find Nodes?
Leftovers?
    Notices?
    hippoepoptai's answer Re: how do I set a cookie and redirect was blessed by hippo!
    erzuuliAnonymous Monks are no longer allowed to use Super Search, due to an excessive use of this resource by robots.