Getting CDONTS to work on Windows Server 2008 x64

http://www.iislogs.com/steveschofield/getting-cdonts-to-work-on-windows-server-2008-x64 

A few questions come up in the forums @ http://forums.iis.net about people moving Classic ASP applications that use CDONTS.  CDONTS was introduced in NT4 and was widely popular.  With the success of ASP applications 'back in the day', many used CDONTS to send emails from their application.   Windows Server 2008 x64 introduces a different challenge.  Here is the procedure I used to get CDONTS working.

1) Copy CDONTS.dll from another server to C:\Windows\SysWOW64

2) Run regsvr32 c:\windows\SysWOW64\cdonts.dll

3) Grant the appropriate permissions on C:\inetpub\mailroot\pickup (I granted USERS group Modify permissions).  You could get permission denied if the folder security isn't adjusted.

4) I'm assuming you have installed the SMTP Service located in Server Manager > Features > SMTP Server option

5) Make sure when you when you install the SMTP service, you enable Relay for localhost > Administrative Tools > Internet Information Services (IIS6) > SMTP Virtual Server > Right click, Properties > Access Tab > Relay button > Add 127.0.0.1 in the option.   Also enable logging for additional troubleshooting. 

'Enable logging
http://weblogs.asp.net/steveschofield/archive/2007/03/25/want-help-with-iis-smtp-service-please-enable-logging.aspx

'Ensure logging will work on x64
http://weblogs.asp.net/steveschofield/archive/2008/02/29/windows-server-2008-smtp-service-logging-tip.aspx

6) Test using code listed below.

Here is the code to run CDONTS webpage.

<%
    Dim strBody
    Dim CDONTSMail
    Set CDONTSMail = CreateObject("CDONTS.NewMail")
    CDONTSMail.From= "user@example.com"
    CDONTSMail.To= "user@example.com"
    CDONTSMail.Subject="This is a Test email"
    strBody = "Thank you for order from www.iislogs.com." & vbCrLf
    CDONTSMail.Body= strBody
    CDONTSMail.Send
    set CDONTSMail=nothing
%>

I recommend you use CDOSYS instead of CDONTS, however if you are trying to migrate from NT4, 2000/2003 and don't want to make code changes, hope this helps. 

PS:I tested this using Network Service as the application pool user, a custom application pool user, IUSR (default anonymous authentication module user) and the Anonymous Authentication module inherit the application pool user as network service and a custom user.  If you are having permissions issues, enable auditing and use process monitor.  

Here is a article that can help with auditing.  http://weblogs.asp.net/steveschofield/archive/2008/03/07/detecting-permission-issues-using-auditing-and-process-monitor.aspx

Cheers,

Steve

转载于:https://www.cnblogs.com/gongsh/archive/2011/09/15/2178068.html

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
CSDN IT狂飙上传的代码均可运行,功能ok的情况下才上传的,直接替换数据即可使用,小白也能轻松上手 【资源说明】 基于MATLAB实现的GO-CFAR检测是信号处理中非常常用的检测方法该程序比较了理论值和实际值的仿真结果实际中雷达信号往往是起伏的,该程序从SweringI型为例+使用说明文档 1、代码压缩包内容 主函数:main.m; 调用函数:其他m文件;无需运行 运行结果效果图; 2、代码运行版本 Matlab 2020b;若运行有误,根据提示GPT修改;若不会,私信博主(问题描述要详细); 3、运行操作步骤 步骤一:将所有文件放到Matlab的当前文件夹中; 步骤二:双击打开main.m文件; 步骤三:点击运行,等程序运行完得到结果; 4、仿真咨询 如需其他服务,可后台私信博主; 4.1 期刊或参考文献复现 4.2 Matlab程序定制 4.3 科研合作 功率谱估计: 故障诊断分析: 雷达通信:雷达LFM、MIMO、成像、定位、干扰、检测、信号分析、脉冲压缩 滤波估计:SOC估计 目标定位:WSN定位、滤波跟踪、目标定位 生物电信号:肌电信号EMG、脑电信号EEG、心电信号ECG 通信系统:DOA估计、编码译码、变分模态分解、管道泄漏、滤波器、数字信号处理+传输+分析+去噪、数字信号调制、误码率、信号估计、DTMF、信号检测识别融合、LEACH协议、信号检测、水声通信 5、欢迎下载,沟通交流,互相学习,共同进步!

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值