isUserInRole method not working if portlet is accessed over WSRP

Solution Unverified - Updated -

Issue

We have a requirement of using role-based security approach in our project for specific portlets. In order to do this we are using the methods isUserInRole(java.lang.String role) and getRemoteUser() from the javax.portlet.PortletRequest class. The method isUserInRole returns always false when we deploy the portlet remotely via WSRP (Please note the methods getRemoteUser() returns logged in user). For testing purposes we deployed the portlet locally and the method isUserInRole returns the expected results. So it seems that the problem is related to wsrp communication between the portal and the portlet. Please note that the ws-security for the portlet consumer is enabled.

Environment

  • JBoss Enterprise Portal Platform (EPP)
    • 5.2.1

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content