createAppRole Managing Application Policies with OPSS Scripts

9-18 Oracle Fusion Middleware Application Security Guide ■ appStripe specifies an application stripe. If not specified, then the script works on system policies. ■ codeBaseURL specifies the URL of the code granted the permission. ■ principalClass specifies the fully qualified name of a class grantee. ■ principalName specifies the name of the grantee principal. ■ permClass specifies the fully qualified name of the permission class. ■ permTarget specifies, when available, the name of the permission target. Note that some permissions may not include this attribute. ■ permActions specifies the list of actions removed. Note that some permissions may not include this attribute and the actions available depend on the permission class. Examples of Use The following invocation removes the application permission for the application with application stripe myApp with the specified data: revokePermission.py -appStripe myApp -principalClass my.custom.Principal -principalName manager -permClass java.security.AllPermission The following invocation removes the system permission with the specified data: revokePermission.py -principalClass my.custom.Principal -principalName manager -permClass java.io.FilePermission -permTarget tmpfileName.ext -permActions read,write

9.3.10 listPermissions

The script listPermissions lists all permissions granted to a given principal. Script Mode Syntax listPermissions [-appStripe appName] -principalClass className -principalName prName Interactive Mode Syntax listPermissions[appStripe=appName,] principalClass=className, principalName=prName The meanings of the arguments optional arguments are enclosed in between square brackets are as follows: ■ appStripe specifies an application stripe. If not specified, then the script works on system policies. ■ principalClass specifies the fully qualified name of a class grantee. ■ principalName specifies the name of the grantee principal. Examples of Use The following invocation lists all permissions granted to a principal by the policies of application myApp: Managing the Policy Store 9-19 listPermissions.py -appStripe myApp -principalClass my.custom.Principal -principalName manager The following invocation lists all permissions granted to a principal by system policies: listPermissions.py -principalClass my.custom.Principal -principalName manager

9.3.11 deleteAppPolicies

The script deleteAppPolicies removes all policies with a given application stripe. Script Mode Syntax deleteAppPolicies -appStripe appName Interactive Mode Syntax deleteAppPoliciesappStripe=appName The meaning of the argument required is as follows: ■ appStripe specifies an application stripe. If not specified, then the script works on just system policies. Example of Use deleteAppPolicies -appStripe myApp

9.3.12 createResourceType

The script createResourceType inserts a new resource-type entry in the policy store within a given application stripe and with specified name, display name, description, and actions. Optional arguments are enclosed in between square brackets; all other arguments are required. Script Mode Syntax createResourceType -appStripe appStripeName -resourceTypeName resTypeName -displayName displName -description descripString [-provider resTypeProvider] [-matcher resTypeClass] -actions resTypeActions [-delimiter delimChar] Interactive Mode Syntax createResourceTypeappStripe=appStripeName, resourceTypeName=resTypeName, displayName=displName, description=descripString [, provider=resTypeProvider, matcher=resTypeClass], actions=resTypeActions[, delimiter=delimChar] The meaning of the arguments is as follows: ■ appStripe specifies the application stripe where to insert the resource type. ■ resourceTypeName specifies the name of the resource type to insert. ■ displayName specifies the name for the resource type used in UI gadgets.