Anders Melander 1782 Posted July 29, 2020 It seems that the Delphi SOAP framework is unable to handle SOAP responses that contain cookies with Expired=Fri, 31-dec-9999 23:59 GMT. Is this a known problem? The web service that sends this response in my case is the Microsoft Terminology Service. While there seem to be some disagreement about whether the year 9999 is out of range (some say 2038 is the maximum allowed value), the value so common that Delphi should be able to handle it. Under any circumstance the reason that Delphi fails to handle to value is clearly not by design - i.e. it's a bug. Here's what happens: The client (the Delphi application) sends a request to the SOAP server. The SOAP server responds. The response contains a cookie with an expiration time of "Fri, 31-dec-9999 23:59 GMT". The Delphi SOAP framework converts the expiration date to the local timezone (CET in my case). The result is 31-dec-10000 01:59. The value 31-dec-10000 is passed to SysUtils.EncodeDate but because the year value is outside the allowed TDateTime range (1-9999) this fails with an EConvertError exception: Invalid argument to date encode. I have not been able to find a way to work around the problem. Share this post Link to post
Guest Posted August 2, 2020 SOAP problems esp. regarding M$, IMHE is best handled compiling a dll using visual studio and then importing that. AtoZ has a Crosstalk product that let's you call that dll, if you lack time to import it. Wrap edge case stuff in simpler dll exports. HTH Share this post Link to post
Dmitry Arefiev 101 Posted August 3, 2020 Please report this issue to quality.embarcadero.com, and get it fixed in 10.4 Update 1. 1 Share this post Link to post
Anders Melander 1782 Posted August 3, 2020 3 hours ago, Dmitry Arefiev said: Please report this issue to quality.embarcadero.com, and get it fixed in 10.4 Update 1. Done: https://quality.embarcadero.com/browse/RSP-30282 Share this post Link to post