Solved

CDONTS authentication

Posted on 2004-04-09
9
851 Views
Last Modified: 2009-12-16
Set myCDONTSMail = CreateObject("CDONTS.NewMail")

is there anyway to specify authentication using this object? smtp server name / usr and pass?
0
Comment
Question by:alain123
  • 5
  • 3
9 Comments
 
LVL 7

Expert Comment

by:brgivens
ID: 10792454
No, but all you need to do is allow relaying for localhost

IIS -> Expand [Server Name] -> Right-Click on Default SMTP Virtual Server -> Properties -> Access -> Relay -> Add -> 127.0.0.1 -> OK
0
 
LVL 1

Author Comment

by:alain123
ID: 10792618
hello,

trust me, i have tried everything you can possibly imagine regarding smtp config and haven't been able to solve it ( i have a wireless router attached to the server).. so i was looking for another slution
0
 
LVL 7

Expert Comment

by:brgivens
ID: 10792666
CDONTS doesn't support authentication.  Did you try the solution I suggested?  The wireless router shouldn't make a difference, you just have to allow relaying for the IP address of the machine where the ASP files are located.  Unless the ASP files are on a different box than IIS, the IP address will be 127.0.0.1
0
 
LVL 1

Author Comment

by:alain123
ID: 10792732
yes i did tried your suggestion, emails are sitting on the emailroot queue folder, they don't go anywhere
0
Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

 
LVL 1

Author Comment

by:alain123
ID: 10792757
0
 
LVL 1

Author Comment

by:alain123
ID: 10792862
0
 
LVL 7

Expert Comment

by:brgivens
ID: 10792884
0
 
LVL 1

Author Comment

by:alain123
ID: 10793020
thank you.. i have check all that, nothing, still doesn't work
0
 
LVL 21

Accepted Solution

by:
ap_sajith earned 500 total points
ID: 10795723
IF you are using Win2k or above, You can use CDOSYS.. Which is much more flexible and efficient than CDONTS. Here's some sample code on how to configure SMTP server and the server authentication code.

<%
Dim objMsg
Dim objConfig

Set objMsg    = CreateObject("CDO.Message")
Set objConfig = CreateObject("CDO.Configuration")


Dim objFields
Set objFields = objConfig.Fields

' Setup server information
objFields("http://schemas.microsoft.com/cdo/configuration/smtpserver")       = "mysmtpserver.com"
objFields("http://schemas.microsoft.com/cdo/configuration/smtpserverport")   = 25
objFields("http://schemas.microsoft.com/cdo/configuration/sendusing")        = 2

' Setup server login information if your server require it
objFields("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1
objFields("http://schemas.microsoft.com/cdo/configuration/sendusername")     = "SMTPAUTHUser"
objFields("http://schemas.microsoft.com/cdo/configuration/sendpassword")     = "SMTPAUTHPassword"

objFields.Update

' Now you can setup message to send
Set objMsg.Configuration = objConfig
objMsg.To       = "tosomeone@somewhere.com"
objMsg.From     = "fromme@withlove.com"
objMsg.Subject  = "Hello"
objMsg.TextBody = "This is my test mail from CDOSYS"

objMsg.Send
%>

Hope this helps..

Cheers!!
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Hello, all! I just recently started using Microsoft's IIS 7.5 within Windows 7, as I just downloaded and installed the 90 day trial of Windows 7. (Got to love Microsoft for allowing 90 days) The main reason for downloading and testing Windows 7 is t…
I would like to start this tip/trick by saying Thank You, to all who said that this could not be done, as it forced me to make sure that it could be accomplished. :) To start, I want to make sure everyone understands the importance of utilizing p…
Windows 10 is mostly good. However the one thing that annoys me is how many clicks you have to do to dial a VPN connection. You have to go to settings from the start menu, (2 clicks), Network and Internet (1 click), Click VPN (another click) then fi…
Sending a Secure fax is easy with eFax Corporate (http://www.enterprise.efax.com). First, just open a new email message. In the To field, type your recipient's fax number @efaxsend.com. You can even send a secure international fax — just include t…

863 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

Need Help in Real-Time?

Connect with top rated Experts

20 Experts available now in Live!

Get 1:1 Help Now