Autor Beitrag
stiftmaster
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 149



BeitragVerfasst: Di 17.06.08 15:51 
Hallo,

bisher konnte ich mit Indy (unter Verwendung von Delphi 7) mit http-Seiten herunterladen - also den Quelltext. Das gleiche möchte ich jetzt auch mit https-Seiten ermöglichen. Daher habe ich meine Funktion zum Erzeigen von einem TIdHttp wie folgt erweitert:

ausblenden Delphi-Quelltext
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
function TBase.GetIdHTTP: TIdHTTP;
var
  IOHandler: TIdSSLIOHandlerSocket;
begin
  Result := TIdHTTP.Create(nil);
  Result.AllowCookies := False;
  Result.Request.BasicAuthentication := cServerAuthentification;
  if (Result.Request.BasicAuthentication = True) then
  begin
    Result.Request.Username := cServerUsername;
    Result.Request.Password := cServerPassword;
  end;

  if (cServerUseSSL = True) then
  begin
    IOHandler := TIdSSLIOHandlerSocket.Create(nil);
    Result.IOHandler := IOHandler;
    Result.Port := 443;
  end;


Compilieren lässt sich das ganze und läuft auch, wenn cServerUseSSL = False ist. Wenn ich allerdings cServerUseSSL auf True setze, dann erhalte ich die Meldung:

Im Projekt Bla.exe ist eine Exception der Klasse EIdOSSLCouldNotLoadSSLLibrary aufgetreten. Meldung: 'SSL.-Bibliothek konnte nicht geladen werden.'. Prozess wurde angehalten. Mit Einzelne Anweisung oder Start fortsetzen.

Nach Suchen in Google habe ich erfahren, dass ich die beiden DLLs "libeay32.lib" und "ssleay32.lib" benötige. Diese habe ich in das Applikations-Verzeichnis kopiert. Aber auch dann kommt noch die Meldung.

Hat jemand von euch n' Idee, was mir fehlt?

Vielen Dank für eure Infos.

Stefan
stiftmaster Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 149



BeitragVerfasst: So 22.06.08 13:07 
Hi,

hat hier keiner eine Idee? Ich kann doch nicht der erste sein, der versucht, eine https-Seite aufzurufen, oder?

Vielen Dank für eure Hilfe

Stefan
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: So 22.06.08 17:53 
kopier die beiden DLLs doch mal ins System Verzeichnis rein.

_________________
In the beginning was the word.
And the word was content-type: text/plain.
stiftmaster Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 149



BeitragVerfasst: Mo 23.06.08 08:38 
Hallo,

und vielen Dank für deinen Hinweis. Auf diesen Versuch hätte ich auch selber kommen können, aber leider hat dies auch nicht geklappt.

Ebenso bin ich drauf gestoßen, dass ich .lib Dateien verwende und es die gleichen Dateien auch in .dll Form gibt. Daher habe ich alle 4 Dateien (2x lib, 2x dll) in das Applikations- und in das System32-Verzeichnis kopiert.

Trotz alledem bleibt die Fehlermeldung die gleiche und ich bin wieder auf einen Tipp angewiesen, da ich absolut nicht nachvollziehen kann, was die Kiste von mir will.

Vielen Dank

Stefan
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Mo 23.06.08 09:40 
Dann ist da irgendwas anderes im Eimer. Installier doch mal die Indys neu oder frage in der Indy Mailingliste...

_________________
In the beginning was the word.
And the word was content-type: text/plain.
stiftmaster Threadstarter
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starontopic star
Beiträge: 149



BeitragVerfasst: Mo 23.06.08 10:26 
Hi,

vielen Dank für den Hinweis. Bin direkt auf Indy 9 umgestiegen und damit läuft es jetzt einwandfrei. Nochmals danke an alle.

Man hört sich

Stefan
Hendi48
ontopic starontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic star
Beiträge: 271



BeitragVerfasst: So 29.06.08 11:51 
Hi,

ich habe dasselbe Problem, dass Indy die Libs nicht akzeptiert. Ich verwende das aktuellste Build (vom SVN) und trotzdem geht es nicht. Und ich will auch nicht downgraden, weil dann einige Verbesserungen von Indy 9 -> 10 fehlen. Gibt es vielleicht aktuellere DLL's mit denen es geht?

Gruß,
Hendi
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: So 29.06.08 15:01 
Meines Wissens nicht, aber frag doch mal in der Indy Mailingliste. Und wenn die da eine Antwort haben, dann sag sie uns noch bitte :-)

_________________
In the beginning was the word.
And the word was content-type: text/plain.
Klabautermann
ontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic starofftopic star
Veteran
Beiträge: 6366
Erhaltene Danke: 60

Windows 7, Ubuntu
Delphi 7 Prof.
BeitragVerfasst: Mo 30.06.08 12:56 
Hallo,

das Problem kommt mir bekannt vor. Allerdings in der Form, das das laden der Librarys beim ersten Nutzungsversuch scheitert (auch nicht auf allen Systemen) beim zweiten Versuch aber klappt. Das unschöne Workaround sieht also bei mir so aus, das ich es wenn es nicht Klappt erneut versuche. Nach x Versuchen gibt es dann die Fehlermeldung. Irgendwie scheinen die Indys sich da selbst zu überholen (versuch zu nutzen wenn Laden noch nicht abgeschlossen)

Gruß
Klabautermann
matze
ontopic starontopic starontopic starontopic starontopic starontopic starhalf ontopic starofftopic star
Beiträge: 4613
Erhaltene Danke: 24

XP home, prof
Delphi 2009 Prof,
BeitragVerfasst: Mo 21.07.08 09:51 
Ich hab da gerade einen interessanten Blog-Artikel gefunden. Evtl hilft der euch ja was:
ruminatedrumblings.b...07/indy-and-ssl.html

_________________
In the beginning was the word.
And the word was content-type: text/plain.