Hi Team,
I am working on created an Generic Rule. The purpose of this rule is to concatenate the values from account to the identity. I am not sure how to pass the identity attribute in the rule. I am directly refering the attirbute in the rule but when i use the validator utility it gives me the below error
Line 25 - [LintBSHMethodInvocation(93)] null Exception: Could not retrieve definition for variable name ‘identity’
25: List multValAttr = ( List ) idn .getRawAccountAttribute ( cloudSourceName , identity .getName ( ) , attributeName )
How can we pass the identity as an object in the rule to make this work ?
There’s a note in the guide bundled with the validator zip that details how to do this:
Generic rules may need additional objects adding to the Signature. The next example shows that “identity” of type “sailpoint.object.Identity” is injected into the BeanShell script for linting:
<?xml version='1.0' encoding='UTF-8'?>
<!DOCTYPE Rule PUBLIC "sailpoint.dtd" "sailpoint.dtd">
<Rule name="Test" >
<Description>Designed to generate mail for active directory. </Description>
<Signature returnType="Object">
<Inputs>
<Argument name="identity" type="sailpoint.object.Identity">
<Description>
Identity object type pushed into this rule... note the "type" attribute is set
to "sailpoint.object.Identity", if not type is specified the Linter will "assume"
this is of type "string".
</Description>
</Argument>
</Inputs>
</Signature>
<Source><![CDATA[
log.debug("Identity name: " + identity.getName());
]]></Source>
</Rule>