An R-type or V-type VOC entry can optionally include the name of a catalogued security subroutine in field 4 (R-type) or field 5 (V-type). This subroutine can be used to determine whether the user is to be allowed to execute the command.
The security subroutine is written using QMBasic. A simple subroutine that prompts for a password is shown below.
SUBROUTINE SECURITY(OK, VERB, REMOTE.FILE, REMOTE.ID)
DISPLAY 'Enter security password: ' :
FOR I = 1 TO 3
IF PASSWORD = 'FSKJJ' THEN RETURN @TRUE
The arguments to this subroutine are:
If the validation fails or the subroutine cannot be found in the catalogue a message is displayed:
This command is restricted (verb)
The security subroutine mechanism can also be used for other purposes such as auditing use of specific commands, diagnostic traps, etc.