Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Secure Password Authentication and SMTP

Status
Not open for further replies.

tsdragon

Programmer
Dec 18, 2000
5,133
US
Anyone know anything about using the Net::SMTP module with a smtp server that requires login with secure password authentication (like microsoft network)?

I can't seem to get Net::STMP to work on my windows machine, and I think that the fact that the smtp server requires login is the problem.
Tracy Dryden
tracy@bydisn.com

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard.
 
#!/usr/local/bin/perl -w

open (STDERR, ">std.err");
use Net::SMTP;

$smtp = Net::SMTP->new('smtp.rnp.ru',
Hello => 'smtp.rnp.ru',
Timeout => 30,
Debug => 1
);


$smtp->mail('lightelf@rnp.ru');
$smtp->to('lightelf@rnp.ru');
@mass = ("bla-bla", ".\r\n");
$smtp->data(@mass);
$smtp->quit;

# OS 98. Smtp server on the Linux.
# smtp protocol does not have password protection.
# so check the std.err log
 
I'll give that a try, but I know what the problem is. When you use Microsoft Network as your ISP (not my first choice, but I got stuck with it, now), you have to configure your email software smtp (outgoing) to login using Secure Password Authentication. Outlook, and apparently a lot of other email programs, handle this pretty well, but using the Net::SMTP doesn't. Here's the message I get from the "to" command: "5.7.3 Due to a recent security enhancement, changes to your email client configuration are required. Please go to for complete information about the steps to make these quick changes. You will be unable to send email from your MSN account until those changes are made." That's where they tell you how to configure your email program for SPA. Tracy Dryden
tracy@bydisn.com

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard.
 
I've just spent over an hour researching this via Google and I think I've been "friction fastened" by Microsoft, AGAIN! Apparently "Secure Password Authentication" is an MS-proprietary scheme for preventing unauthorized access to mail servers. Unfortunately, if you're using MSN as your ISP you CANNOT use any other smtp server but theirs! I found the name of the MS dll that does SPA, but that doesn't do me any good in this case, and I can't find anything about someone having reverse engineered it and posted how it works. The closest hint I can find is that its some variation of CRAM-MD5, but that's it.

I guess that means that it is impossible to send email from your PC via a PERL program if you're using MSN. Typical! Funny how Microsoft's "standards" keep messing up the standard way of doing things. Tracy Dryden
tracy@bydisn.com

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard.
 
I do most of my programming on Unix, but I'm trying to write a program that people can run on *nix or Windows systems. I had it working perfectly on Unix a week ago, but it has been nothing but headaches getting it to work on Windows, even though I'm using ActivePerl and Apache, which should make it pretty portable. I decided to use the Net::SMTP module to make it portable - before I was just using sendmail. A lot of little differences, like the fact that flock isn't implemented for Windows 98, and one big one, like it doesn't work at all if you use MSN. I can't even test the Net::SMTP part, since it won't work on my local machine, and my ISP doesn't have Net::SMTP installed. Guess I'll have to try to install it on my ISP account and test it there. That's kind of a pain too, without shell access, but I've got a cute way around that with my TDShellCommander. As long as I don't have to compile anything I should be able to get it installed. Tracy Dryden
tracy@bydisn.com

Meddle not in the affairs of dragons,
For you are crunchy, and good with mustard.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top