Solved

Protection of .mdb files

Posted on 2002-06-14
4
187 Views
Last Modified: 2010-05-02
How to protect my microsoft database file and open it from my visaul basic project.

Please: not with passowrd protection, because there are a lot of easy to use haker programs to know my complicated password

elzohry
0
Comment
Question by:elzohry
4 Comments
 
LVL 22

Expert Comment

by:rspahitz
ID: 7079525
Well, the other way is to use the VB program to encrypt and decrypt every piece of data going through the DB.

After you set up your fields in the table, have each field call an encrypt routine before being Inserted or Updated such as this:

strSQL = "Update tblXXX Set field1 = " & EncryptData(txtField1.Text) & ", field2 = " & EncryptData(txtField2.Text)
...

And decrypt when retrieved:
strSQL = "Select field1, field2 from tblXXX"
...
txtField1.Text = DecryptData(rstYYY.Field("field1").Value)
txtField2.Text = DecryptData(rstYYY.Field("field2").Value)

Private function EncryptData(DataToEncrypt as String) as String
' encryption routine of your choice
End function

Private function DecryptData(DataToDecrypt as String) as String
' decryption routine of your choice
End function

0
 

Author Comment

by:elzohry
ID: 7079920
is there any other way ,
The Ecryption will make my Database So slow .
I used lot of memo Fields
Thanks
0
 
LVL 16

Expert Comment

by:Richie_Simonetti
ID: 7080080
So, migrate to SQL Server/Oracle/informix or other one.
0
 
LVL 6

Accepted Solution

by:
pierrecampe earned 50 total points
ID: 7080191
pasword protection on access db's is easely bypassed
but i yet have to encounter someone who could get past user-lever security on a access db
i suppose you do not have msaccess so look here:
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/dndao/html/daotoadoupdate_topic7.asp
 
0

Featured Post

Gigs: Get Your Project Delivered by an Expert

Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Have you ever wanted to restrict the users input in a textbox to numbers, and while doing that make sure that they can't 'cheat' by pasting in non-numeric text? Of course you can do that with code you write yourself but it's tedious and error-prone …
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…
Show developers how to use a criteria form to limit the data that appears on an Access report. It is a common requirement that users can specify the criteria for a report at runtime. The easiest way to accomplish this is using a criteria form that a…

776 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question