Resources | oam | localAuth | rule-list | cmdrule

cmdrule

One command access control rule. Command rules control access to CLI commands and Web UI functions. Rules are processed in user-defined order until a match is found. A rule matches if 'context', 'command', and 'access-operations' match the request. If a rule matches, the 'action' leaf determines if access is granted or not.

Configuration

ParameterPresenceTypeDefaultDescription
nameMstringArbitrary name assigned to the rule.
contextOunion*This leaf matches if it has the value '*' or if its value identifies the agent that is requesting access, i.e. 'cli' for CLI or 'webui' for Web UI.
commandOstring*Space-separated tokens representing the command. Refer to the Tail-f AAA documentation for further details.
access-operationsOunion*Access operations associated with this rule. This leaf matches if it has the value '*' or if the bit corresponding to the requested operation is set.
actionMenumerationThe access control action associated with the rule. If a rule is determined to match a particular request, then this object is used to determine whether to permit or deny the request.
commentOstringA textual description of the access rule.
RESTCONF API: GET Example

curl -kisu 'admin:secret' -X GET https://{SBX-SERVER}/restconf/data/sonusOrca:oam/localAuth/rule-list={name}/cmdrule={name}

RESTCONF API: POST Example

curl -kisu 'admin:secret' -X POST -H 'Content-Type: application/yang-data+xml' https://{SBX-SERVER}/restconf/data/sonusOrca:oam/localAuth/rule-list={name} --data '
<cmdrule>
     <name>{name}</name>
     <action>{action}</action>
</cmdrule>
'

RESTCONF API: DELETE Example

curl -kisu 'admin:secret' -X DELETE https://{SBX-SERVER}/restconf/data/sonusOrca:oam/localAuth/rule-list={name}/cmdrule={name}

  • No labels