[AccessD] Data Encryption

Gustav Brock Gustav at cactus.dk
Mon Jan 28 01:55:59 CST 2008


Hi Pete

Hi Max

One option is to encrypt the field content itself of those fields with sensitive data.
I've used that for mdb files sent over the Internet thus eliminating the need for VPN or encrypted mail. I just zipped and attached the mdb files.

Here's the header info with the description of the functions:

' PC1 Cipher 128-bit key
' (c) Alexander Pukall 1991
' Can be used freely even for commercial applications
'
' MS Access 97 version by
' Gustav Brock, Cactus Data ApS
' gustav at cactus.dk 
'
' 2002-03-09. V1.0
'   Initial port from Visual Basic.
' 2002-06-23. V1.1
'   Code clean up and constants added.
'   Redundant code removed.
'   Modified to fully comply with VB datatypes.
'   Modified to not crash for certain passwords.
'   Modified for high speed conversion of long strings ( > 32K).
' 2002-06-24. V1.2
'   Functions added for en/decrypting to/from binary strings.

' Usage:
'   SetPassword(password) sets password prior to en/decryption.
'   GetPassword() retrieves current password.
'   StrEncrypt(DecryptedString) returns encrypted ascii string.
'   StrDecrypt(EncryptedString_ascii) returns decrypted string.
'   StrEncryptBin(DecryptedString) returns encrypted binary string.
'   StrDecryptBin(EncryptedString_binary) returns decrypted string.
'
' Encrypted ascii string is twice the length of the decrypted string.
' Encrypted ascii string contains low ascii chars from a to p only.
' Encrypted binary string is same length as the decrypted string.
' Encrypted binary string may contain any char including Chr(0).
' Password may contain any ascii char including Chr(0).
' Password is maintained in global variable strPC1Password16.

I've posted the full module previously:

http://databaseadvisors.com/pipermail/dba-tech/2005-February/003711.html 

/gustav


>>> pete.phillipps at ntlworld.com 26-01-2008 16:00:15 >>>
Hi Everyone,

	I'm due to start work on creating a database in a couple of weeks
amd in view of the recent UK government record on losing data it has made me
thing about data encryption. Does anyone have any advice/code on encrypting
data in an Access 2003 back-end that would be accessed via an Access 2003
front end and via ASP/ASP. NET?

Pete





More information about the AccessD mailing list