In order for this site to work correctly, and for us to improve the site, we need to store a small file (called a cookie) on your computer.
By continuing to use this website, you agree to our cookies and privacy policy.
  
Home page Home page Home page Home page
Pixel
Pixel Header R1 C1 Pixel
Pixel Header R2 C1 Pixel
Pixel Header R3 C1 Pixel
Pixel

Version 3 Technical Highlights - Securing Accounts

SecureAccount_Sub

Once the account has been created the security for the account may be manipulated using SecureAccount_Sub. This takes four parameters as follows - MakeAccount_Sub(Action, AccountName, AccountRow, Flag) where

 Action        A code for the action to be performed having the following
               possible values

                 0 Read AccountRow and return

                 1 Write AccountRow and return. Note that this will
                   automatically encrypt the passwords for you, BUT field 1
                   of the AccountRow must be set to the name of the Account
                   NOT the literal "ACCOUNT"

 AccountName   The name of the account to work with

 AccountRow    The account row for updating/retrieving from the SysEnv table

 Flag          A result flag having the following possible values

                 1 An account name was not given

                 2 Valid SysEnv row but not an account

                 3 Account does not exist

                 4 Invalid action code passed

Thus to change an account password programmatically one could


0001    * Set password to NEW in account TEST
0002  
0003    Declare Subroutine SecureAccount_Sub, Msg
0004    Equ AccountName$        To "TEST"
0005    Equ ReadAccount$        To 0
0006    Equ WriteAccount$  To 1
0007  
0008    SecureAccount_Sub(ReadAccount$, "TEST", AccRow, Flag)
0009    If Flag Then
0010      Msg("Error " : Flag)
0011    End Else
0012      AccRow<1> = "TEST"
0013      AccRow<6> = "NEW" ; * Set password to NEW
0014      SecureAccount_Sub(WriteAccount$ , "TEST", AccRow, Flag)
0015      If Flag Then Msg("Error " : Flag)
0016    End

(Volume 4, Issue 6, Pages 9,10)
Pixel
Pixel Footer R1 C1 Pixel
Pixel
Pixel
Pixel