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.