We're running under AREV 3.12. We have a screen that we are trying to build. One of the prompts will hold a person's Social Security Number. For security reasons we would like to show that there is data in the prompt but not show the number itself. We've been trying to figure out how to put something like asteriks (*) inplace of any data that may be in that field. Can anyone point us in the right direction to find that information?
We tried to use the MASKing for that prompt but all it did was fill the prompt with asterisks even before there is data in the prompt. The MASK is just used to show a template of what can be placed within the prompt. We are looking for something that will put and asterisk in the prompt for every digit entered as it is being entered. So if one digit has been entered then only one askterisk will be displayed. Then when the second digit is entered, two will be displayed and so on.
Plus we would like to see askterisks in place of the data within the prompt, when a row is displayed that contains data for that prompt. That is without actually overwiting the real data in the row with askterisks. The reason for that is to indicate to the user that there is or isn't data within that column.
Along with this particular screen we are creating one that will be used to enter the Social Security Number into the given table. With the needed security checks and so forth to only allow authorized users into it.
If you can point us in the right direction, it would be much appricated.
Thank You,
Michael Slack
E-mail: [email protected]
Michael,
I don't know about masking the data with an asterisk, but I can tell you how I mask data that I don't want to be seen.
There is an AREV subroutine, that should be in your SYSOBJ table, called $SEC. We have an employee information window that has a password field. Obviously, once that password has been entered, we don't want anyone to be able to see that password. So, what we do is on that field, in the Output Format field, we put the followin code and command:
@S SEC,7@
The overall effect of this is to display the string "" in the field, without modifying the data that is actually stored in the table.
Don't know of any other options besides '7' for this subroutine, but I imagine you could create a test window and play around with it.
Hope this helps.
Matt Sorrell
Just for fun
![]()
From the REVMEDIA FKB
Jens Diederichs writes "Has anybody been playing with the revised (for AREV 3.0) version of SEC() yet? I used to be able to use the SEC(6) call to encrypt passwords as per RevMedia Vol 1 Issue 6. Some calls to SEC (such as 7) still work. A '6' call still works from a window but from TCL falls over.
There is obviously something very simple here that I am missing - any
guesses?"
As Jens noted, SEC has fundamentally changed for version 3. This is a function of a number of things - not least of which is that security had been harmonised and centralised in the system. SEC still takes 1 parameter but instead of a range of 1 to 12, the parameters can now be from 1 to 19.
In addition SEC expects to always find Window_Common% loaded. If you wish to call it from your own program (not from a window) you must load a modified version of Window_Common% in which the WC_W% array is dimmed to a number rather than WC_WCnt%, then you must ClearCommon. Note also that some of the operations only make sense from a window and that these operations will require full Window_Common%.
CODE ACTION
ÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ
1 Closes window if application is not SYSPROG.
2 Provides a popup of valid usernames. If WC_Register%(1) is loaded with an account name (see 18) then only users for this account will be displayed.
3 Provides a popup of valid applications
4 Provides a popup of valid environments
5 Calls the ACCOUNTLOGTO window and permits the alteration of
characteristics of the logto password. Note that it expects @Record to be loaded with the Application row from SysEnv with Field 1 replaced with the Application name rather than the word "ACCOUNT". For details of how to load @Record in this fashion see the documentation on SECUREACCOUNT_SUB later in this issue. Note that this call will only work in SYSPROG.6 Encrypts contents of @Ans
7 Used as an Oconv to display "" message
8 Used to load a User row into the current row from a window. Place on the post prompt process of the username prompt and @Record will be loaded from that SysEnv row. This works from any account.
9 Used to save a User row as loaded by 8. This only works from SysProg.
10 Used to load an Application row into the current row from a window. Place on the post prompt process of the application name prompt and @Record will be loaded from that SysEnv row. This works from any account.
11 Used to save an application row as loaded by 10. This only works from SysProg.
12 Used to validate an entry as a valid application name. Used as an edit pattern, it will set Status() accordingly and display an error
message if the entry in @Ans is not an application.13 This is used by a large number of SysWindows and is therefore
probably "Kill if RunTime" but until a 3.0 RunTime is available itwill not be possible to test this.14 Calls the ACCOUNTADVANCED window and permits the alteration of characteristics of the application. Note that it expects @Record to be loaded with the Application row from SysEnv with Field 1 replaced with the Application name rather than the word "ACCOUNT". For details of how to load @Record in this fashion see the documentation on SECUREACCOUNT_SUB later in this issue. Note that this call will only work in SYSPROG.
15 Used to delete an account or user. Only works in SysProg.
16 Takes the value of @Ans and ensures that it is a valid location by truncating any directory name to 8 characters. Used as an edit
pattern, looks for its input in @Ans. Therefore C:\AREV\TEST123456 would be returned as C:\AREV\TEST1234.17 Used by the Account window to warn you if you change a location that you have to move the Dos files as well. (B276)
18 Used by the AccountUser window on a post initialise when looking at the users for an application. Seems only to load WC_Register%(1) with the name of the application.
19 Used by Account window to call AccountUser window.
(Volume 4, Issue 6, Pages 5,6)
World Leaders in all things RevSoft