TFPHTTPClient with proxy and HTTPS protocol lazarus / 38-Networking and Web Programming ---------------------------------------------------------------------- Abelisto · 2018-08-03 03:26 Is the subj possible? If yes - how? There is the simple test program: Code: Pascal  [Select][+][-]window.onload = function(){var x1 = document.getElementById("main_content_section"); if (x1) { var x = document.getElementsByClassName("geshi");for (var i = 0; i program proxy; {$mode objfpc}{$H+} uses    Classes, SysUtils, openssl, fphttpclient; procedure SetProxy(AHttp: TFPHTTPClient; const AUrl: string);var    i: Integer;begin    with AHttp.Proxy do    begin      if AUrl <> '' then        begin            i := Pos(':', AUrl);          Host := Copy(AUrl, 1, i - 1);            Port := StrToInt(Copy(AUrl, i + 1, Length(AUrl)));            UserName := '';            Password := '';            Writeln(ErrOutput, Format('Set proxy Host: %s, Port: %d', [Host, Port]));        end        else      begin            Host := '';            Port := 0;            UserName := '';            Password := '';        end;    end;end; var    url, proxy: string;    http: TFPHTTPClient;    responce: string;begin    if ParamCount > 1 then    begin        proxy := ParamStr(1);        url := ParamStr(2);    end    else    begin      proxy := '';        url := ParamStr(1)    end;    http := TFPHttpClient.Create(nil);    http.IOTimeout := 5000;    SetProxy(http, proxy);    responce := http.Get(url);    Writeln(responce);    http.Free;end.  Next calls works just fine: ./proxy 185.93.3.123:8080 http://www.lazarus-ide.org ./proxy https://www.lazarus-ide.org curl --proxy 185.93.3.123:8080 https://www.lazarus-ide.org But ./proxy 185.93.3.123:8080 https://www.lazarus-ide.org gives ESocketError: Connect to 185.93.3.123:8080 failed. ---------------------------------------------------------------------- Thaddy · 2018-08-03 10:29 Well. Use trunk for that. There have been quite a few changes including a related one with an example in the last few weeks. ---------------------------------------------------------------------- Abelisto · 2018-08-03 12:12 @Thaddy Thanks, but it seems that the result is same, even with packages/fcl-web/examples/httpclient/httpget.pas example.