AccesSoft - Articles - Start through main form
Main | Articles | Links | Map

Start through main form

In this article we shall consider one of the ways of protection of exhibit Access. The Speech will go about entry in the base through entering the password, or dialect otherwise - авторизация. In Access is provided possibility to assign the password on database: Service Protection Assign the password a database. However password itself is kept in system roll in clear type, and to open such protected base, it is enough only to call at in roll and read him(it). We shall try to create the similar interface, but with scrambled password already moreover we shall do so that in an effort open the form if user to manage to fall into the base, avoiding start form авторизации, the base emergency was closed.

For this we shall be necessary in official table, for instance tAdminCop, wind the field Password, in which shall keep the password, but in the same way module of the cryptooperation of the password AdminPassword.

Scheme авторизации following:

At start of exhibit is started form авторизации formAdmPassword, in which enter password

Password is read, encode and compared with scrambled password in field of the table tAdminCop

If passwords coincide, that is opened starting form of the exhibit if no output from exhibit.

Constant of the logical type is given In module Constants. Under correct password she takes importance True, under false (by default) accordingly False. There is such procedure In event of the form frmStart:

     Private Sub Form_Open(Cancel As Integer)
          If flgEnabled = False Then
               DoCmd.Quit acPrompt
          End If
     End Sub

As it is seen if flgEnabled = False, that, became to be, output from exhibit. Thereby, and impossibility of the opening of the form is done without entering the password. If similar procedures to hang on rest forms, reports, that single loopholes for "enemy" will remain only tables, beside which, regrettably, no no event, which possible was intercept. Single protection for them will be a hiding window exhibits and installation of protection from Shift.

Obviously that such авторизация efficient only in that event, when "enemy of" no move to source code of the modules, other word base is transformed in format .mde. In general, base of any protection of applications Access this .mde format. Really, вздумай You protect such a image .mdb, any could simply open module Constants and prescribe there

     Public Const flgEnabled = True

And all, no protection.

Protection by cryptooperation of the password will depend on difficulties of the cryptooperation. I have shown only simplest example (the module AdminPassword). In general, cost(stand)s to search for in Internete, or try придумать most more cunning (steadfast) algorithm cryptooperations.
The Ithaca, shall conduct test:

We Start exhibit. Appears the form an авторизации. We Enter 123456, жмем entering is opened starting form. Now we shall try to open the form frmStart without entering the password. We Start exhibit, holding Shift is opened window of the project Access. We Try to start frmStart exhibit is closed.
If now add in our program protection from Shift, that application will become else more impregnable .

Using protection from Shift and input through the form авторизации, possible sound to damage slightly the nerves all amateur to climb where does not follow. But possible, You solve to install (sell) its program to whom - or. What do so that he not smog to spread her(it) without Your knowledge? Other word, what organize the service to registrations of the program? About this in the following article...

The Example, as so much for works, You may below.

Author: Admin Size: 64 kB It Is Added: 02.02.2007

Main | Articles | Links | Map
тема про выписка из егрип.

Copyright 2007 - 2008 AccesSoft. All Rights Reserved