How Protect The properties: User Password Database HostName

Forum related to all other 6.x versions of ZeosLib's DBOs

Moderators: gto, cipto_kh, EgonHugeist

jamiguel77
Fresh Boarder
Fresh Boarder
Posts: 9
Joined: 22.12.2007, 18:00

How Protect The properties: User Password Database HostName

Postby jamiguel77 » 13.03.2009, 16:45

hi all, i use Delphi7 and Zeos Components 6.6.1 beta

easy my question: How Protect The properties: User Password Database HostName

sample: suppose i have a form named: FLogin and a Connection named: Zconnection

in form create i have a simple configuration of my Zconnection component:

procedure TFlogin.FormCreate(Sender: TObject);
begin
Zconnection.Hostname:='192.168.0.3';
Zconnection.User:='mydbuser';
Zconnection.Password:='mydbpass';
Zconnection.Database:='mydb';
Zconnection.Connected:=true;
end;
suppose for the rest of my team (5 ppl) i share my Flogin.Dcu they cant see the user and password and hostname and database in design time right ?

but they can know if in any form type something:

Form1.Caption:='User: '+Flogin.Zconnection.User+' Password: '+Flogin.Zconnection.Password+' Hostname: '+Flogin.Zconnection.Hostname+' Database: '+Flogin.Zconnection.Database;

then they know the parameters, my question is: how protect these 4 parameters, and only share the connection?

Thanks

gto
Zeos Dev Team
Zeos Dev Team
Posts: 278
Joined: 11.11.2005, 18:35
Location: Porto Alegre / Brasil
Contact:

Postby gto » 17.03.2009, 12:39

The best method you can go is to encrypt these properties anywhere you want (registry, inifile, config file) and load them at runtime.

Well, sorry for the question, but you're tying to protect the connection details from your team? kinda wired.. Maybe if you use a local server, with a known connection properties, and load the remote (production) lines at runtime, you can do better of both sides.
Use the FU!!!!!IN Google !

gto's Zeos Quick Start Guide

Te Amo Taís!

User avatar
mdaems
Zeos Project Manager
Zeos Project Manager
Posts: 2766
Joined: 20.09.2005, 15:28
Location: Brussels, Belgium
Contact:

Postby mdaems » 21.03.2009, 00:38

Another solution might be to build a new connection object inheriting from TZConnection. Then you can just set the secret properties at create time and hide those properties.

Mark
Image


Return to “Other 6.x Versions”

Who is online

Users browsing this forum: No registered users and 1 guest