Free Support Forum - aspose.com

Loading of some saved Emls results in infinite loop

Hello.

We are using Aspose.Networks 3.5.3 and have noticed, that an old problem is back. The enclosed eml was stored by Aspose.Network.Exchange.ExchangeClient and cannot be loaded by Aspose.Networks anymore.

Andre


Dear Andre,

Thanks for the info.

We are now checking the root. I will get back to you soon.

Hello.

I just want to add, that this is a very critical bug for us, because this error happened in the production system. We hope, you can provide a solution as soon as possible.

Andre

Dear Andre,

We have located the root, and fixed it. Please check it out. The root is some header containing unexpected chars, not the previouse bug.

www.aspose.com/products/Aspose.Network/Releases/3.5.3/Aspose.Networkv3.5.3.2.zip

Please let me know if it works.

Thanks

Hello.

The original problem is solved but now retrieving mails does not work anymore. Using Aspose.Network.Exchange.ExchangeClient.ListMessages results in this exception:

Header ends prematurely while character ‘>’ was expected at position 30.
bei Aspose.Network.Mime.x48f5bcaa993d2e2c.xa227c01e5e59cdc4(Char x3362caa77b1
f70b4)


We cannot determine, which mail causes this error, because there are some thousands of mails in the mailbox. These thousands of mails are generate from exchange servers, so these mails are real world mails. Again, we need a solution asap.

Andre

Hello, Andre,

It looks like the Exchang server giving some kind of messages contain invalid charactors. I am working on this issue and try to get back to you shortly.

Thanks,

Hello, Andre,

Could you please try this hotfix? I have added some debug information and extracted more info about the infomations. Please run it and get the exception to me. Print out the exception you catched by

using Exception.ToString() function, we will get all info we need to debug.

www.aspose.com/products/Aspose.Network/Releases/3.5.3/Aspose.Networkv3.5.3.3.zip

Thanks,

Hello.

Aspose.Network.Mime.MimeException
bei Aspose.Network.Mime.x9562fab6cd9b077f.x1f490eac106aee12(x48f5bcaa993d2e2c
xe134235b3526fa75)
bei Aspose.Network.Mail.MailAddress.x1f490eac106aee12(x48f5bcaa993d2e2c xe134
235b3526fa75, x9562fab6cd9b077f& x179bb663e71b1f59, x067709715f06eb57& xf0d47d76
98b4e263, Boolean& xe2c9497bf778cd2b)
bei Aspose.Network.Mail.MailAddressCollection.x6a81a30bcaf20a97(x48f5bcaa993d
2e2c xe134235b3526fa75)
bei Aspose.Network.Mail.MailAddressCollection.op_Implicit(String addresses)
bei Aspose.Network.Exchange.ExchangeMessageInfo.x19890931227f0f56(x9b55ae2d38
50d157 xe464d907306ccb86, ExchangeMessageInfo& x02f8da7b6171e2e6)
bei Aspose.Network.Exchange.ExchangeMessageInfoCollection.x1f490eac106aee12(x
9b55ae2d3850d157[] x94d801a1518a39e4)
bei Aspose.Network.Exchange.ExchangeClient.ListMessages(String folder, Boolea
n recursive)
bei Aspose.Network.Exchange.ExchangeClient.ListMessages(String folder)
bei Mobilkom.ZdvCore.EmailService.BounceManager.ProcessBounces()


Hope this helps.

Andre

Please post the content of the exception here, instead of the call stack.

You can catch the exception and get its .ToString function return. I added some debug message in to the content of the exception.

Thanks

But the ToString function returns the call stack.

I´ve investigated the exception with the debugger: it´s a Aspose.Network.Mime.MimeException with NO message and NO inner exception (both are null). (So beside the problem retrieving the messages the exception is not very helpful). But we have found a message in the not public members: “Header parse failed:“A1 Team” <A1-Team@mob.cc”. Here we can see, that there is a missing ‘>’.
Please check, if Aspose.Networks deletes this character. I don´t think so, but we have to assure. If not, the original mail on the exchange server has this (apparently erroneous) mime header, but Aspose.Networks SHOULD NOT throw an exception because of this. Because it´s a valid email and the email could be a bounce email (with erroneous content).

Thank you.
Andre





Thanks for your info.

Could you add an Try-Catch in the code, and save that EML to me? I could like to investigate about the issue, before doing to much fixing works.

Well, we can be sure to add some fail-over handling in the email parsing. Therefore, it will not throw out exceptions.

Hello.

As mentioned above Aspose.Network.Exchange.ExchangeClient.ListMessages throws this exception. How can I save a message, if ListMessages does not return messages, because it cannot parse MimeHeaders? But I will try to develop a application to extract the erroneous email.

Beside this problem, I have attached an eml, which cannot be loaded by Aspose. Is it really ok that Aspose throws an exceception while loading this email?

Andre


Here are two emls.

error_534.eml: here the header is not entire correct (see “A1 Team” <A1-Team@mobilkom.at)
error_1428.eml: some loading error.

Hope this helps.


Hello.

Are there news about this?

Andre

Hello,

We have released a new version of Aspose.Network. The empty attachment bug you mentioned has been fixed. Please check it out.

http://www.aspose.com/Community/Files/54/aspose.network/entry95314.aspx

Thanks,