Welcome Guest! To enable all features please Login or Register.

Notification

Icon
Error

Options
Go to last post Go to first unread
TheDirector  
#1 Posted : Wednesday, November 29, 2017 4:32:20 AM(UTC)
TheDirector

Rank: Newbie

Groups: Registered
Joined: 11/29/2017(UTC)
Posts: 1
Italy
Location: Avellino

Hi,

we are going to evaluate EASendMail and EAGetMail for .NET in order to use them in our projects.

Connection trough SOCKS5 Proxy is a key feature for us. EASendMail works fine but when we have tried EAGetMail with this code (without socksproxyserver works fine) :


Imports EAGetMail 'EAGetMail45.dll

[...]

Public Sub ReceivePop3()

Dim curpath As String = Directory.GetCurrentDirectory()
Dim mailbox As String = [String].Format("{0}\inboxpop3", curpath)

If Not Directory.Exists(mailbox) Then
Directory.CreateDirectory(mailbox)
End If

Dim oServer As New EAGetMail.MailServer("XXXXXX",
"YYYYY", "YYYYYY", EAGetMail.ServerProtocol.Pop3)
Dim oClient As New EAGetMail.MailClient("TryIt")

oServer.SSLConnection = True
oServer.Port = 995
oServer.SSLType = SSLConnectType.ConnectSSL

oServer.SocksProxyServer = "ZZZZZZZZZ"
oServer.SocksProxyUser = "ZZZZZZ"
oServer.SocksProxyPassword = "ZZZZZZZZZ"
oServer.SocksProxyPort = 2016
oServer.ProxyProtocol = EAGetMail.SocksProxyProtocol.Socks5

Try
Console.WriteLine("Connessione...")
oClient.LogFileName = [String].Format("{0}\today.log", mailbox)
oClient.Connect(oServer)
Console.WriteLine("Connessione aperta")

Dim infos As EAGetMail.MailInfo() = oClient.GetMailInfos()
For i As Integer = 0 To infos.Length - 1
Dim info As EAGetMail.MailInfo = infos(i)
Console.WriteLine("Index: {0}; Size: {1}; UIDL: {2}",
info.Index, info.Size, info.UIDL)

' Receive email from POP3 server
Dim oMail As Mail = oClient.GetMail(info)

Console.WriteLine("From: {0}", oMail.From.ToString())
Console.WriteLine("Subject: {0}" & vbCr & vbLf, oMail.Subject)

' Generate an email file name based on date time.
Dim d As System.DateTime = System.DateTime.Now
Dim cur As New System.Globalization.CultureInfo("it-IT")
Dim sdate As String = d.ToString("ddMMyyyyHHmmss", cur)
Dim fileName As String = [String].Format("{0}\{1}{2}{3}.eml", mailbox, sdate, d.Millisecond.ToString("d3"), i)

' Save email to local disk
oMail.SaveAs(fileName, True)

' Mark email as deleted from POP3 server.
' oClient.Delete(info)
Next

' Quit and purge emails marked as deleted from POP3 server.
oClient.Quit()
Console.WriteLine("Messaggi ricevuti correttamente!")
Catch ep As Exception
Console.WriteLine(ep.Message)
End Try

End Sub

we have obtained the following error on oServer.Connect():

Value cannot be null!
Parameter name: innerStream

In the log file we have found this:

Resolving proxy ...
Server: XXXX
Port: 995
AuthType: AuthLogin
User: XXXX
Password: XXXX
Alias:
SSLConnection: True
SSLType: ConnectSSL
Protocol: Pop3
SocksProxyServer: XXX.XXX.XXX.XXX
SocksProxyPort: 2016
SocksProxyUser: ZZZZZ
SocksProxyPassword: ZZZZZ
ProxyProtocol: Socks5

Create socket InterNetwork,Stream,Tcp ...
Start to connecting ...
XXX.XXX.XXX.XXX, 2016
Connected

Start to send request to proxy server...
Proxy server responds OK.

What's wrong? Thanks for your help...
ivan  
#2 Posted : Thursday, December 7, 2017 5:47:31 PM(UTC)
ivan

Rank: Administration

Groups: Administrators
Joined: 11/11/2010(UTC)
Posts: 988

Thanks: 9 times
Was thanked: 33 time(s) in 33 post(s)
Hi, this bug has been fixed in latest official version 4.6.3.6

https://www.emailarchite...net/downloads.aspx?cat=1
Users browsing this topic
Forum Jump  
You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.

Powered by YAF.NET | YAF.NET © 2003-2018, Yet Another Forum.NET
This page was generated in 0.066 seconds.

EXPLORE TUTORIALS

© All Rights Reserved, AdminSystem Software Limited.