13.1.3 External Interface for Query Security
The "QUERY SECURITY
" function calls a “stub” named
ExternQuerySecurity
.
The delivered ExternQuerySecurity stub receives all parameters of the QUERY
SECURITY
, it always allows access to the resources and returns zero in the return
code. It can be replaced by a customer function that respects the interface described
below.
The QUERY SECURITY
passes the following parameters:
restype pic x(7).
restype-data-value pic x(12).
resclass pic x(8).
resclass-data-value pic x(8).
residlength pic x(11).
residlength-data-value pic s9(8) comp-5.
resid pic x(5).
resid-data-value pic x(246).
logmessage pic x(10).
logmessage-cvda pic s9(8) comp-5.
read pic x(10).
read-cvda pic s9(8) comp-5.
update pic x(10).
update-cvda pic s9(8) comp-5.
control pic x(10).
control-cvda pic s9(8) comp-5.
alter pic x(10).
alter-cvda pic s9(8) comp-5.
resp pic s9(8) comp-5.
resp2 pic s9(8) comp-5.
userid pic x(8).
All parameters are passed to ExternQuerySecurity, only the following parameters are expected in return:
read-cvda pic s9(8) comp-5.
update-cvda pic s9(8) comp-5.
control-cvda pic s9(8) comp-5.
alter-cvda pic s9(8) comp-5.
resp pic s9(8) comp-5.
resp2 pic s9(8) comp-5.
If "read" is fulfilled with "READ", read-cvda is expected.
If "update" is fulfilled with "READ", update-cvda is expected.
If "control" is fulfilled with "READ", control-cvda is expected.
If "alter" is fulfilled with "READ", alter-cvda is expected.
"resp" and "resp2" are always expected.
Note:
Each interface field is ended by a binary zero, it easier if you want write the "ExternQuerySecurity" in C.The cvda values for "read" are:
READABLE 35.
NOTREADABLE 36.
The cvda values for "update" are:
UPDATABLE 37.
NOTUPDATABLE 38.
The cvda values for "control" are:
CTRLABLE 56.
NOTCTRLABLE 57.
The cvda values for "alter" are:
ALTERABLE 52.
NOTALTERABLE 53.
For more details, see cvda values in IBM documentation.
S9(9) COMP-5 is equivalent to a signed int.