list of chapters    previous chapter   next chapter

Ch 11 - Passwords and related matters



Ch 11 - Passwords and related matters

11.1 Levels of protection

Powerbase provides three levels of password protection. None of the sample databases uses passwords, so you may examine the password-setting dialogue box which is accessed by choosing Set passwords from the Miscellaneous submenu. If passwords have been defined then an attempt to open the database leads to a request for a password. This is not readable as you type it in; all the characters are replaced by hyphens. If Powerbase does not recognize the supplied password it beeps and prints an error message in red then prompts for the password to be re-entered. After three failed attempts Powerbase will shut down.

The lowest password level is Read. It is intended to let users examine the database but otherwise keep them out of mischief. A user opening a database with the Read password will be allowed to browse, search and print reports (unless debarred as described in 11.2), but not much else. In fact it will be found impossible to place the caret in a field. The function keys won't work, many of the buttons on the tool-pane will be inactive and some menu items will be shaded. In particular, the whole of the Miscellaneous submenu is unavailable, thus preventing the user from getting at the other passwords!

The next level, Read/write, allows more operations. Everything on the tool-pane is allowed, including altering, creating and deleting records. You may create indexes and create and edit validation tables. What you cannot do is change passwords or alter the size and structure of the database by means of options on the iconbar Utilities menu.

The top level is Manager. At this level you are allowed to set and alter passwords, as well as use all the iconbar menu options. Passwords may be up to 10 characters long and are normally case-specific. Note that when you are setting the two lower ones they can be read but the Manager password appears even here as a row of hyphens. Take care not to forget it! If no passwords at all are set you have full Manager rights so you may ignore the password facility altogether if you are the only user of the database.

If you decide to use passwords you might not wish to use all three levels of protection and don't need to do so. You may set a Manager level password only, leaving the other two blank. When you attempt to open the database in such circumstances the password-entry window appears because Powerbase can't read your mind and doesn't know whether you're the Manager and wish to enter your password or whether you're a lower-level user being given limited access without needing a password. If the latter you would simply click on Open or type Return, thus entering a null password. This would give you Write access. If you set the Manager and Read/write passwords then entering a null password would give Read access.

It obviously makes no sense to set a low-level password and leave a higher level one blank! Powerbase prevents you from doing this in the following way. If there is a Read password but no Write password Powerbase makes the Read and Write passwords the same. Similarly, if there is a Write password and no Manager password these two are made the same. This means that setting only the Read password makes all three identical. You are then admitted to Manager level when you enter this password - otherwise you could never get Manager level access again! The rule is that when two or more passwords are identical you are always given the higher level access when using that password.

11.1.1 Individual I.D.s and passwords

The Access button makes it possible to assign a user an I.D. and a personal password which allows access at one of the three levels described above. This gives even greater security by limiting access to those people who appear on a concealed list. It does not seem appropriate, however, to describe the creation of such an access-control list in a manual for the general reader and the Access button is therefore shaded on copies of Powerbase as distributed. Anyone wishing to set up a secure database for use by a list of specified users is welcome to write for information to Powerbase Support, explaining their requirements.

If a database is protected by an access-control list the password-entry window which appears when you attempt to open the database will display two writable icons instead of one. The first is for the user's I.D., the second is for the password. Enter both and click on Open. A an error in either the I.D. or the password will result in access being denied without informing the user which input contained the error.

11.2 Options selected from the password-setting window

As well as the icons for the passwords you will see eight option buttons which may be used to enable or disable certain features of Powerbase. They are placed here so that they may only be altered by someone who has Manager rights as that is the only access level which allows you to open this window. All the buttons except the last (Log changes) are selected by default so that all the named features are enabled. If you deselect any of these buttons the feature concerned will cease to operate when you click on Set and will remain inoperative every time the database is opened unless you set the button to re-enable it.

The first four buttons determine the availability of the tool-pane/keypad, the equivalent function keys, the main menu and the iconbar menu. All these features are enabled by default but you may disable some or all of them in order to restrict the actions of other users of the database. This subject is treated fully in Ch 14.

The fifth button determines whether or not the exporting of CSV files and subset databases is allowed and the sixth does the same with regard to report printing.

11.2.1 Duplicate primary keys

The seventh button determines whether the database is allowed to have duplicated primary keys or not. As mentioned elsewhere (see 4.5.2) the primary key should, ideally, be unique for each record. Sometimes the very nature of the data will make it so but, if this is not the case, you can enforce primary key uniqueness by deselecting this button. Any attempt to enter a record which would have a primary key identical to one which already exists will then result in an error message and the new record will not be placed in the file.

If you decide to allow duplicate primary keys (and this is the default, remember) you might still want to be warned that such a key is about to be created and a button on the Preferences window allows you to enable or disable this feature. You can also make Powerbase print a list of duplicate primary keys (see 10.8).

The above refers only to the primary key. Other, subsidiary, keys which are generated when you create an index on some other field (see 7.1) are not subject to these restrictions and may be repeated many times.

11.3 Logging database changes

Selecting the last option button (Log changes) and clicking on Set opens a log inside the database directory. Powerbase will then keep a record of when the database is opened and closed and details of changes made to the records. The following changes are logged, details in brackets showing what is recorded:

As long as the Log changes button remains selected the log file will be opened whenever the database is opened. The title of the database is recorded and the password level at which entry was achieved. This takes the form of a number with the following meaning:

0 - no password required, 1 - read only, 2 - read/write, 3 - manager

The date and time are also recorded. When you close the database the date and time are recorded again and the log file closed.

The log file is a plain text file and is always called Log. Although the default location for the file is inside the database directory you may start a log somewhere else by dragging the small text-file icon next to the Log changes button to a directory display. When you release the mouse button the password window is closed just as if you'd clicked Set and logging is enabled. (It doesn't matter whether you have selected the option button or not in this case; Powerbase will select it for you.) An advantage of this method is that you may perform the same drag to the same directory from many different databases and have them all use the same log. The !Scrap application is a possible location for a general log of this kind.

View loads the log file into an editor for inspection.



top of page   list of chapters    previous chapter   next chapter