Hello Rob. Thanks for looking at my issue. Masklist is what I actually need.
I have a compliance check with domain defined, like this:
DOMAIN Thisisjustdomainname, SELECT(racf(class=DATASET,s=base, masklist:variable1.var.var<>' '))And also I have external file, where all definitions are put in this matter:
deftype type=variable1 nowarn alloc type=variable1 dd=C1234567(extrfile) define type=variable1 var as substr(record,3,9)extrfile - dataset member with list of dataset profiles in format
ABCD.**I tried a few places to add your suggested definition (
define masklist as mask), unfortunately, got these errors:
CKR0103 12 Field "MASK" to be processed not found in any templateorCKR0103 12 Field "MASKLIST" to be processed not found in any templateAny suggestions, what else could be missing? looks like mask not accepted in my carla
------------------------------
Viktorija Kulbaciauskiene
------------------------------
Original Message:
Sent: Wed January 25, 2023 07:04 AM
From: Rob van Hoboken
Subject: CARLa: getting mask from another dataset file
Illustrating Jeroen's answer with an example:
newlist type=racf
select class=dataset segment=base mask=ABCD.**
sortlist profile owner
This selects all dataset profiles starting with ABCD. The MASK selection accepts a pattern and applies it to the profile key. You can even use generic characters in the first qualifier, where RACF requires non-generic HLQ, so SELECT ... MASK=AB*.** finds all profiles starting with AB.
Now, if you have a list of masks, the SELECT command leaves you dangling: MASK does not accept a list. You could define a new field with the same function as MASK, and now SELECT accepts a list:
newlist type=racf
define masklist as mask
select class=dataset segment=base masklist=(ABCD.**,EFGH.**)
sortlist profile owner
If you use PROFILE in the SELECT command, it matches the profile key character for character, exactly matching the generic characters. This report prints only one specific profile:
newlist type=racf
select class=dataset segment=base profile=ABCD.**
sortlist profile owner
------------------------------
Rob van Hoboken
Original Message:
Sent: Tue January 24, 2023 10:39 AM
From: Viktorija Kulbaciauskiene
Subject: CARLa: getting mask from another dataset file
Hello Jeroen. Thanks for quick reply. I require to use mask instead of profile in dataset class because I'm checking access (type=racf and type=racf_access) of dataset profiles listed in another file. The reason why I have to use mask is because in company's racf database we have number of dataset profiles, like:
ABCD.*.**
ABCD.EFGHIJKL.**
ABCD.MNOPQRS.**
and etc.
In another dataset, I have a list of dataset profiles with only first qualifier, like ABCD.**
------------------------------
Viktorija Kulbaciauskiene
Original Message:
Sent: Tue January 24, 2023 10:16 AM
From: Jeroen Tiggelman
Subject: CARLa: getting mask from another dataset file
Hi Viktorija,
I am afraid I do not really understand your question.
For starters, I do not understand from what you write why you need to use MASK in the first place.
Can you explain with a bit more detail what you are trying to check?
Regards,
------------------------------
Jeroen Tiggelman
Software Development and Level 3 Support Manager IBM Security zSecure Suite
IBM
Delft
Original Message:
Sent: Tue January 24, 2023 09:53 AM
From: Viktorija Kulbaciauskiene
Subject: CARLa: getting mask from another dataset file
Hello folks. I'm trying to write a code to check the list of dataset profiles from external dataset (approx. 200 profiles, which are dynamic). I have to use mask , because I have a list of dataset profiles in format ABCD.**
type= racf
class=dataset
segment=base
Defined variables and it works good with profile, unfortunately, I need to use mask. Any specific parameters need to be added?
------------------------------
Viktorija Kulbačiauskienė
------------------------------