Source language: Translate to:

Question on Access database file extensions and encrypting

Questions about our Advanced Database plug-in

Moderator: Neosoft Support

Question on Access database file extensions and encrypting

Postby Enigman » Mon Apr 28, 2014 10:40 am

Can anyone comment on the ramifications of using a filename extension other than "mdb" with Access databases? Has anyone run into any performance or stability issues with using a name like "2m5.m19" for an Access database?

Also, I have noticed that the dbp open database and compact database commands have the ability to encrypt the Access database. However, if I use the option to encrypt, I see no indication of encryption if I open the database without my application, such as opening it directly in Access. That would indicate to me that Access is decrypting it upon opening, without a key, which to me, makes encryption pointless.

Can anyone comment on using the dbp encryption option with an Access database? Any issues? Is it worth it?

Thanks.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA

Re: Question on Access database file extensions and encrypti

Postby Neosoft Support » Tue Apr 29, 2014 9:35 am

I'm not aware of any issues with changing the file extension of .mdb files. I've done this in several apps without problems. The only exception would be if you're using the .accdb format the file must have the .accdb extension otherwise DBPro won't be able to open it.

The encryption option should work, but it's the MS Access engine that handles the actual encryption process - not DBPro. It may be that the database must be initially created with encryption enabled.
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5603
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Re: Question on Access database file extensions and encrypti

Postby Enigman » Tue Apr 29, 2014 9:55 am

The encryption option should work, but it's the MS Access engine that handles the actual encryption process - not DBPro. It may be that the database must be initially created with encryption enabled.

I assumed that the MS Access or Jet engine was handling the encryption, and assuming that it did encrypt the database ( I don't have a hex editor to check, can you recommend a safe one?) when a compact was done with the encryption turned on, my concern was that the MS engine then decrypted it when I opened it directly with Access.

Has no one done any work with this feature? Does the password option have to be used in order for the encryption to be done?

I am already encrypting individual fields with my own encrytion, but it would be nice to have an overall encryption that would remain when the database is opened directly with Access or viewed with a hex editor.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA

Re: Question on Access database file extensions and encrypti

Postby Wrangler » Wed Apr 30, 2014 8:06 am

Here is an article with info about Access encryption:

http://www.tech-faq.com/how-ms-access-e ... works.html

Here's what I know for sure: A while back I locked myself out of an Access encrypted, password protected database. I purchased a tool online for 10 bucks that extracted the password faster than an eye blink.

So I wouldn't count on this encryption for security. Dec's encryption plugin will work, but I found the process of encrypting and decrypting slow, especially with larger databases.
Wrangler
--------------
"You never know about a woman. Whether she'll laugh, cry or go for a gun." - Louis L'Amour

Windows 7 Ultimate SP1 64bit
16GB Ram
Asus GTX 950 OC Strix
Software made with NeoBook
http://highdesertsoftware.com
User avatar
Wrangler
 
Posts: 1507
Joined: Thu Mar 31, 2005 11:40 pm
Location: USA

Re: Question on Access database file extensions and encrypti

Postby Neosoft Support » Wed Apr 30, 2014 10:16 am

Does the password option have to be used in order for the encryption to be done?


Yes, I would think so since an encrypted database without a password would be useless. If you use a password and encryption then you should not be able to open the database in MS Access without entering the password.

Of course, as Wrangler points out, MS Accesses password protection/encryption isn't very strong.
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5603
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Re: Question on Access database file extensions and encrypti

Postby Enigman » Thu May 01, 2014 8:01 am

Here is an article with info about Access encryption:....

Here's what I know for sure: A while back I locked myself out of an Access encrypted, password protected database. I purchased a tool online for 10 bucks that extracted the password faster than an eye blink.

Okay, well ... obviously there are some "issues" with Access based encryption that make it unattractive. My NB application already encrypts the important 7 fields out of the 17 it uses. I just noticed the capability and thought, why not encrypt the entire database in addition to my own encryption so snoops cannot read the unencrypted fields. No worries. My own brand of field encryption is extremely strong, so my critical data is protected without Access's encryption. I'll just let that go.

Thanks all.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA

Re: Question on Access database file extensions and encrypti

Postby Enigman » Thu May 01, 2014 8:18 am

I'm not aware of any issues with changing the file extension of .mdb files. I've done this in several apps without problems. The only exception would be if you're using the .accdb format the file must have the .accdb extension otherwise DBPro won't be able to open it.

Back to the file extention question ...

The reason I asked originally was that I found some inconsistencies in the DBPro behavior when database extensions are changed, and I just ran into another one.

If I create the MDB file originally with Access, then I can manually change the file extension to something random like "B22" and in the program it will open and operate, although some functions have hiccups that I cannot pin down to the file extension or not, mainly because I am still in development of the app and can't be sure. HOWEVER, if I use DBPro to create the database in the first place, then it seems to be more sensitive to file extensions when I try to use the database.

For example, I created a small database to act as a file to store specific variables to load at run time. I called the file "2mn.ini". The CreateAccessDatabase command creates the file just fine, but it then refuses to open the file, saying it has an invalid file type. I tried INI, INIT, and other extensions and no dice on opening. If I change it back to MDB, then it works fine. So there are differences in reactions to file extensions based on where the file was originally created. Maybe INI and INIT are too close to system file types and that's what is choking the open database command, but I don't know for sure.

I know there are a lot of "reserved words" that DBPro will not allow for field names, which ironically Access doesn't care about at all, so if there is a list of "reserved extensions" it might help to know those as well.

Thanks.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA

Re: Question on Access database file extensions and encrypti

Postby Neosoft Support » Thu May 01, 2014 10:29 am

If you change the extension then you must use dbpOpenAccessDatabase to open the file. Otherwise, DBPro will try to identify the format using the extension.
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5603
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Re: Question on Access database file extensions and encrypti

Postby Enigman » Thu May 01, 2014 11:12 am

Neosoft Support wrote:If you change the extension then you must use dbpOpenAccessDatabase to open the file. Otherwise, DBPro will try to identify the format using the extension.

It doesn't matter. When the extension is "ini", Both open types still say "Unknown database type:" with a colon at the end as if there is something else it cannot display.

And it gets even weirder. If I delete the file, default name the ini database file "2mn.vars" with dbpOpenAccessDatabase, then, upon not finding the file existing it will create the file, open it, add data to it, and it will remain accessible throughout the first session. If I restart the program with no changes, then it chokes on the file type on sytartup and repeats the error above. After that it will not open with either open command format.

Thanks.
Last edited by Enigman on Thu May 01, 2014 11:21 am, edited 1 time in total.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA

Re: Question on Access database file extensions and encrypti

Postby Wrangler » Thu May 01, 2014 11:17 am

What happens if you don't use a system file extension, use something like .gtk? I've never had a problem as long as I don't use an extension that is attributed.
Wrangler
--------------
"You never know about a woman. Whether she'll laugh, cry or go for a gun." - Louis L'Amour

Windows 7 Ultimate SP1 64bit
16GB Ram
Asus GTX 950 OC Strix
Software made with NeoBook
http://highdesertsoftware.com
User avatar
Wrangler
 
Posts: 1507
Joined: Thu Mar 31, 2005 11:40 pm
Location: USA

Re: Question on Access database file extensions and encrypti

Postby Enigman » Thu May 01, 2014 11:32 am

I seem to have found a working combination. This is why I said this is difficult to bebug when I am still developing.

I went back to the "vars" extension and found a code path where the file was already present and found it had an OpenDatabase command in only one place instead of a OpenAccesDatabase command. Changing that coordinated it with the creation code that already had OpenAccessDatabase. "Vars" then worked. So then I went back and reset everything to a "ini" file extension and it still works. I really wanted that extension in the first place because it WAS a known Windows file type, so if someone is trying to thrash their way into understanding what is going on, Windows will treat the file like an ini file and blow it off.

Thanks.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA


Return to NeoBookDBPro

Who is online

Users browsing this forum: No registered users and 2 guests