|
From: creecode <icr...@us...> - 2006-03-13 08:19:13
|
Update of /cvsroot/frontierkernel/odbs/frontierRoot/system/verbs/builtins/tcp In directory sc8-pr-cvs1.sourceforge.net:/tmp/cvs-serv7765 Modified Files: sendMail Log Message: added support for SMTP-AUTH CRAM-SHA1 Index: sendMail =================================================================== RCS file: /cvsroot/frontierkernel/odbs/frontierRoot/system/verbs/builtins/tcp/sendMail,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** sendMail 12 Mar 2006 04:32:06 -0000 1.5 --- sendMail 13 Mar 2006 08:19:10 -0000 1.6 *************** *** 3,6 **** --- 3,8 ---- on sendMail (recipient = "", subject = "", message = "", sender = user.prefs.mailAddress, cc = "", bcc = "", host = user.prefs.mailHost, mimeType = "text/plain", adrHdrTable = nil, timeOutTicks = 60 * 60, flMessages = true, port = user.prefs.mailHostPort, smtpAuth = user.prefs.mailSmtpAuth, senderPassword = user.prefs.mailPassword) { «Changes + «3/12/06; 12:12:32 PM by TAC + «added support for SMTP-AUTH CRAM-SHA1 «3/11/06; 8:25:21 PM by TAC «when adding AUTH= xtext the sender *************** *** 239,242 **** --- 241,258 ---- flAuthenticated = true}; + "CRAM-SHA1" { + local (s); + + executeCommand ("AUTH " + smtpAuth, "334", @s); + + s = s - "334 "; + s = base64.decode (s); + + s = crypt.cramSHA1 (string.nthField (sender, '@', 1), string (senderPassword), s); + s = base64.encode (s, 0); + + executeCommand (s, "235"); + + flAuthenticated = true}; "LOGIN" { local (s); |