|
Title:
|
64-bit DataSnap and RSA + PC1 filters
|
Author:
|
Bob Swart |
Posted:
|
11/11/2011 5:11:11 PM
(GMT+1)
|
Content:
|
The following is also documented in my upcoming Delphi XE2 DataSnap book, but I want to share it with all Delphi XE2 DataSnap users already: DataSnap relies on OpenSSL for the encryption of the keys in the RSA + PC1 filter combination; which requires some manual assembly for 64-bit applications.
If you deploy 32-bit DataSnap servers, using the RSA and PC1 filters, then you must also deploy two Indy specific OpenSSL DLLs: libeay32.dll and ssleay32.dll – or make sure they already exist somewhere in the path of the server machine. These two DLLs are needed for the RSA filter (which encrypts the password used by the PC1 filter). Without these two DLLs, any client who wants to connect to the server will get an “Connection Closed Gracefully” message, because the server was unable to load the two DLLs to start the RSA filter to encrypt the PC1 keys, etc.
When Delphi is installed, three 32-bit versions of the OpenSLL DLLs can be found on your machine (actually all three slightly different):
C:\Program Files\CollabNet C:\Program Files\Embarcadero\RAD Studio\9.0\bin\SubVersion C:\Program Files\FinalBuilder 7 XE2
Even on a 64-bit Windows machine, I could find no 64-bit version of OpenSSL, other than on the OpenSSL site. So, I had to look for them on the internet ;-) You can find the 64-bit version of OpenSSL 0.9.8g for Windows for the AMD64 instruction set as AMD64-Win64OpenSSL-0_9_8g.zip. This includes the .LIB and .EXP files plus headers from the inc32 directory. In this AMD64-Win64OpenSSL-0_9_8g.zip file, you'll also find libeay32.dll and ssleay32.dll. Note that these are 64-bit versions of the OpenSLL DLLs, having the same name as the 32-bit counterparts. Make sure they do not end up in your 32-bit Windows directory. In fact, you may want to make sure that they are in the directory of your 64-bit DataSnap Server and/or 64-bit DataSnap Client only.
In the next couple of week I'm going to demonstrate this at the BE Delphi Developer Day on November 17th in Edegem (B), and my DataSnap XE2 training on November 25th in Helmond Brandevoort (NL), still one place left! Here, I'll also show the RSA and PC1 filters in action on Mac OS X clients, among others.
|
Back |
|