i would like to create a program that can access my firebird database on 2 different computers via the internet. i would like to know what connection to use and what parameters to set.
thanks
There are some libraries available - see here for a rather comprehensive list.
For the libraries which support more database back-end you must choose the Firebird driver (usually is called Interbase/Firebird Driver or IB/FB Driver).
For protocol, choose TCP/IP - for connection string you must have your server public IP address
: your full database file path as seen by FB server
.
The exact format depends of library but, for example, if your server is example.com
then the connection string would be example.com:c:\myDatabases\myDatabaseFile.FDB
However, this setup isn't advisable because of security (and perhaps speed) issues which arise having a Firebird database directly exposed to the Internet.
Much more advisable is to have an 3-Tier (n-Tier) application in which the middle tier will be responsible to be a secure "firewall" between the server and your clients.
You can implement TCP/IP packets encryption/decryption directly in the firebird engine itself. Personnaly, i have downloaded the Firebird 2.5 source code and injected secure tunnelization code directly in his low level communication layer (the INET socket layer). Now, encryption/decryption is done directly by the firebird engine for each TCP/IP packet both at the server side and the client side (fbclient.dll). Then there is no need to re-structure the client application except adding one line of code that provide the secret key you choose to crypt communication to the fbclient.dll. The same secret key must be declared in the firebird.conf file of your server installation. I have also implemented a proxy negociation solution in the fbclient.dll in order to allow to TCP/IP packets to pass throught any proxy server (like Microsoft ISA Server for example). For us, this architecture is functional for more than one year in a real production system.
来源:https://stackoverflow.com/questions/15685085/how-do-i-connect-to-a-firebird-database-on-delphi-7-from-multiple-clients-spread