IBM Security Z Security

Security for Z

Join this online user group to communicate across Z Security product users and IBM experts by sharing advice and best practices with peers and staying up to date regarding product enhancements.

 View Only
Expand all | Collapse all

I have a question on how to use Carla to identify when a value in one field matches that of another field

  • 1.  I have a question on how to use Carla to identify when a value in one field matches that of another field

    Posted Thu May 29, 2025 04:25 PM
    For example I have the following data:
    I exploded the ACL of SURROGAT *.SUBMIT profiles to identify whether a UserID might be on the ACL of it's own profile. So I exploded the ACL/Groups.    
                                                                     
     Class            Profile                      ProfID       XplodeID    ACLID    
     SURROGAT USERID1.SUBMIT  USERID1  USERID9  GROUP1   
     SURROGAT USERID1.SUBMIT  USERID1  USERID1  GROUP2    
     SURROGAT USERID1.SUBMIT  USERID1  USERID2  GROUP2    
     SURROGAT USERID2.SUBMIT  USERID2  USERID2  GROUP3    
     SURROGAT USERID2.SUBMIT  USERID2  USERID3  GROUP3    
     SURROGAT TEST123.SUBMIT  TEST123  TEST123  TEST123  
     
    ProfID = QUAL1 of SURROGAT Profile
    XplodeID = Exploded ID of Group on ACL or UserID on ACL
    ACLID = Userid or Group on ACL
     
    I have tried a few different ways to identify whether the value in ProfID is equal to the value in XplodeID but have been unsuccessful
    Here's a couple of my attempts using a define and using the select statement
     
    deftype type=@input           
    alloc type=@input 
    newlist type=@input 
    def cls(8,char,'Class') as Substr(record,1,8)      
    def prf(15,char,'Profile') as Substr(record,10,15) 
    def pid(8,char,'ProfID') as Substr(record,26,8)    
    def xid(8,char,'XplodeID') as Substr(record,35,8)  
    def aid(8,char,'ACLID') as Substr(record,44,8)     
    def itself boolean where (pid=xid) 
    newlist type=@input,                
     tt="IDs on ACL of themselves"                     
     select pid=xid                                       
     SORTLIST cls prf pid xid aid itself
     
    I can easily do this with sort INCLUDE COND=(26,8,CH,EQ,35,8,CH) but would prefer to do it all within Carla.


    ------------------------------
    Scott Lahner
    ------------------------------


  • 2.  RE: I have a question on how to use Carla to identify when a value in one field matches that of another field

    Posted Fri May 30, 2025 03:46 AM
    Edited by Rob van Hoboken Fri May 30, 2025 03:52 AM

    The normal operators compare a field with a (fixed) value, for example

    SELECT OWNER=SYS1

    is the same as

    SELECT OWNER='SYS1'

    If you want to compare a field value with the value of (another) field, you double up the operator, like so

    SELECT OWNER==DFLTGRP

    See here.

    By the way, can you tell us the reason why you single out users with a SURROGAT authority on themselves?

    ------------------------------
    Rob van Hoboken
    ------------------------------



  • 3.  RE: I have a question on how to use Carla to identify when a value in one field matches that of another field

    Posted Fri May 30, 2025 09:39 AM

    Thanks Rob! That did the trick. It's been a while since I've used that operator and had forgotten about it.



    ------------------------------
    Scott Lahner
    ------------------------------