10-17-2013, 09:33 PM
I did figure this out. Problem is that now I am finding that a lot of servers will reply ok even if the user doesn't exist.
VRFY is also disabled on most servers.
and finally, some servers don't seem to recognize RCPT TO:<email> NOTIFY=FAILURE
so here's the script I worked out:
Function TelnetEmail
VRFY is also disabled on most servers.
and finally, some servers don't seem to recognize RCPT TO:<email> NOTIFY=FAILURE
so here's the script I worked out:
Function TelnetEmail
#compile "__TcpIpClient"
TcpIpClient x
str carrier="txt.bell.ca"
str number="5555555555"
str body="HELO WRLD"
RunConsole2(F"nslookup -q=mx {carrier}" _s)
str MailExchange
str pattern="mail exchanger = (.*?)\r\n"
if(findrx(_s pattern 0 0 MailExchange 1)>=0)
,out MailExchange
pattern="mail exchanger = (.*?)\r\n"
str receivedData
if(!x.Connect(MailExchange 25))
,end "failed to connect"
x.Send("HELO HI[]")
x.Send("MAIL FROM:[email protected][]")
x.Send(F"RCPT TO:<{number}@{carrier}>[]")
x.Send(F"DATA[]")
x.Send(F"[]")
x.Send(F"{body}[]")
x.Send(F".[]")
x.SendEnd
x.Receive(receivedData)
out receivedData
x.Close