Granting the Same Role to the Same User Twice Causes Unclear WLST Message (Doc ID 1344014.1)

Last updated on SEPTEMBER 16, 2011

Applies to:

Oracle SOA Platform - Version: 11.1.1.1.0 to 11.1.1.5.0 - Release: 11gR1 to 11gR1
This problem can occur on any platform.

Symptoms

Inaccurate message when granting duplicate roles for the same user:

Command FAILED, Reason: Cannot add principal to application role

For example:
  1. Create a domain with Oracle WebCache and extend it with Oracle SOA Suite.
  2. Associate the Oracle WebCache application with LDAP and grant the admin role to a user (for example, user name test) in Oracle Internet Directory using the WebLogic Scripting Tool (WLST).
  3. Grant the same role (admin role) to the same user again (test).
You expect to see a WLST error message such as the following:

This particular user already has admin role to access your application

Instead, you receive the following message, which is inaccurate:

Command FAILED, Reason: Cannot add principal to application role

Cause

Sign In with your My Oracle Support account

Don't have a My Oracle Support account? Click to get started

My Oracle Support provides customers with access to over a
Million Knowledge Articles and hundreds of Community platforms