I'm using CDONTS to send emails and I've just installed MS Exchange on my server and now I can't send emails using CDONTS. I found this article in MS Knowledge Base (http://support.microsoft.com/default.aspx?scid=kb;en-us;324037) it says to give IUSR access to the metabase, i've tried to do that but once i close the properties window and go back to it IUSR is gone from the permissions... so the only thing that works is this vb script:
Option explicit
Dim objSMTP, objInst, objSD, objACL, objACE, objNew
Dim sAccount
sAccount = wscript.arguments(0)
Set objSMTP = GetObject("IIS://LOCALHOST/SMTPSVC")
For Each objInst In objSMTP
If objInst.class = "IIsSmtpServer" Then
set objSD = objInst.AdminACL
set objACL = objSD.DiscretionaryACL
set objNew = CreateObject("AccessControlEntry")
objNew.AccessMask = 9 ' read + enumerate
objNew.AceType = 0 ' ADS_ACETYPE_ACCESS_ALLOWED
objNew.AceFlags = 2 ' ADS_ACEFLAG_INHERIT_ACE
objNew.Trustee = sAccount
objACL.AddAce objNew
objSD.DiscretionaryACL = objACL
objInst.Put "adminACL", Array(objSD)
objInst.SetInfo
End If
Next
|
The problem is that if i reboot the changes also go away... has anybody encountered this problem..? if so is there a solution to it other than editing the forum mail function..?
Also I set the permissions on the SMTP to relay email only from 127.0.0.1 and all the addresses in my LAN but it won't allow me to send emails to emails addresses outside my domain (using an email client)...