Marco Tech Blog

In Delphi and C++Builder Tokyo 10.2.2 we have added a number of features to the HTTP client and REST client libraries. Here is a summary.

The new features for the HTTP client library offer more flexibility and options in terms of protocol and standards support.

Better Secure Protocols Support

The first change is the improved support for security protocols. In the past it wasn't possible to specify the required security protocols (TLS1.1, TLS1.2, etc.) for an HTTP request. We have added a new enumeration, THTTPSecureProtocol with the values (SSL2, SSL3, TLS1, TLS11, TLS12). THPPTClient and related classes have now a SecureProtocols property which is a set based on that enumeration.

HTTP Redirect Improvements

Another set of improvements is in the way the HTTP client library handles redirects. There is a new RedirectsWithGET runtime property offering another set of options, this time based on the following enumeration:

MIME Name Helper

We added a function that to the TEncoding support, which returns the encoding MIME for a speficied encoding:

function GetEncodingMimeName(AEncoding: TEncoding): string;

Changed TIniFile Behaviour

This one is totally unrelated, beside the fact it was also done in 10.2.2. The Ini File behavior was platform specific, not is it platform independent. On Windows, TIniFile ReadString ignores the case of Key parameter. On Linux, the ReadString call was case sensitive, leading to issues when migrating code and configuration files. Now by default TIniFile content structure (not the actual values) is treated in a case-insensitive way on all supported platforms.

1 Comments

HTTP Protocol Related Improvements in Delphi 10.2.2

I hope you succeed in your daily work
I would like to ask you a question
I will try to think it as clear as possible
To one of our clients we have developed an application that
connects to a WebService had been working very well
But the WebService provider changed to TLS 1.2 and since then it
stopped working and could not connect.
We use Delphi 10.2.2 trial version (the idea is to solve it with this
version to acquire the license)
To generate the WSDL we use the IDE assistant.
We use the THTTPRIO class
My question is :
there is some way to change the TLS version to TLS 1.2 from code
checking the source code of Delphi in its previous version I see
that it is not using indy, on the other hand it uses the Windows API
(Winint)
my English is bad
regards

Comment by Carlos Alberto Reyes Garcia
[]
on January 25, 21:27

Post Your Comment

A blog about Delphi programming, Embarcadero, XML, Web 2.0,
JavaScript, and anything else Marco is working on
and has worked on in the past.
Site content is copyright
Marco Cantu' 2005-2016. Powered by Bootstrap and
Delphi.