Microsoft Access 2010 : Securing Databases for Distribution
Suppose you want to make a database available for use by several organizations, but the organizations don’t want their members to be able to change the database objects and perhaps "break" things. You can save the database as an ACCDE file and distribute that file instead of the ACCDB file.
Saving a database as an ACCDE file compiles and compacts the resulting database. Users of the ACCDE file can view forms and reports, update information, and run queries, but they cannot change the design of forms and reports.
Tip
ACCDE files also restrict what can be done with macros, modules, and VBA code.
You can’t save a database in ACCDE format back to the source ACCDB format, so after saving a database as an ACCDE file, be sure to retain the original ACCDB file in a safe place. If you need to change a form or report in the database, you will need to make the change in the original database and then save it as an ACCDE file again.
Important
When creating an ACCDE file for a database that is accessed by multiple users, first make sure that no user has the database open. In Windows Explorer, navigate to the location of the file, and verify that there is no file of the same name with an .laccdb (locked Access database) extension. If you attempt to create an ACCDE file for an open database, you will be warned that the database has already been opened by someone else (the username and computer name are provided) and told to try again later.
In this exercise, you’ll create a secure database by saving it as a distributable ACCDE file. You’ll then test the file.
Set Up
You need the GardenCompany12 database you worked with in the preceding exercise to complete this exercise. Open the GardenCompany12 database (not the GardenCompany12_split database), and then follow the steps.
-
Display the Backstage view, and in the left pane, click Save & Publish.
The Save & Publish page provides several options for saving and distributing the database.
The Save & Publish page of the Backstage view.
-
Below Advanced in the right pane, click Make ACCDE, and then click Save As.
-
In the Save As dialog box, verify that the contents of your practice file folder are displayed, and then click Save.
No message alerts you when the save process is complete.
-
When the Save As dialog box closes, close the database.
-
Display the Backstage view, and then click Open.
-
In the Open dialog box, ensure that the contents of your practice file folder are displayed.
Access has created a database executable file. (You might need to turn off the Navigation task pane and adjust column widths to see the file types in the practice file folder.)
The icon for an ACCDE file displays a blue lock over the standard Access icon.
-
Double-click the GardenCompany12 database executable file that is identified as a Microsoft Access ACCDE Database.
Access displays a somewhat scary security notice.
This security warning is displayed when you open an executable file that is from an untrusted publisher or that is stored in an untrusted location.
-
Because you trust the source of this file (you!), click Open.
-
In the Navigation pane, right-click each object in the Garden Company category, and notice that the Design View command is not available.
Because Design view is inactive, you cannot make any design changes to forms or reports.
Clean Up
If you want, delete the GardenCompany12.accde file. Retain the GardenCompany12.accdb file for use in the last exercise.
Packaging and Signing Databases
If you want to convey to users of a database executable file that they can trust the file, you might want to use the Package And Sign tool to create an Access Deployment (ACCDC) file. An ACCDC file contains one database that has been compressed. The file is signed with a digital signature, signifying that no changes have been made since the package was created.
Tip
You can either purchase a digital signature from a third-party company or you can create your own signature. For information, search for digital signature in Access Help.
To package the current database as a signed ACCDC file:
-
Display the Save & Publish page of the Backstage view.
-
Below Advanced in the right pane, click Package And Sign, and then click Save As.
-
When a security message asks you to confirm that you want to use the installed certificate, click OK.
-
In the Create Microsoft Access Signed Package dialog box, specify a location for the package and assign a name. Then with Save As Type set to Microsoft Access Signed Package, click Create.
To use the packaged file:
-
In Windows Explorer, navigate to the location where the signed ACCDC file is stored.
You can turn on file name extensions so that you can see them.
The signed package is considerably smaller that the source database file.
-
Double-click the package, and when Access displays a security notice, click Show Signature Details.
-
Check the signature in the Digital Signature Details dialog box, and then click OK.
Tip
To trust all files originating from this publisher, you can click Trust All From Publisher to add the source to the Trusted Publishers list in the Trust Center.
-
In the security notice box, click Open.
-
In the Extract Database To dialog box, navigate to the location to which you want to extract the database, and click OK.
You can then work on the database as you normally would.