cancel
Showing results for 
Search instead for 
Did you mean: 

Assigning J2EE Roles to Users in NWA

Former Member
0 Kudos

Does anyone know how to configure a user to belong to a J2EE role in NWA?

I have setup an MDB to run-as a role MyRole in the ejb-jar.xml file:

<security-identity>

<run-as>

<role-name>MyRole</role-name>

</run-as>

</security-identity>

I added a security-permission element for this role in my ejb-j2ee-engine.xml file:

<security-permission>

<security-role-map>

<role-name>MyRole</role-name>

<server-role-name>MyRole</server-role-name>

</security-role-map>

</security-permission>

I added a run-as-identity-map in my ejb-j2ee-engine.xml file.

<run-as-identity-map>

<user-name>Guest</user-name>

</run-as-identity-map>

I always get the following error:

Caused by: com.sap.engine.services.ejb3.jacc.JACCException: Run-as is specified for security role MyRole but there isn't a user mapped to this security role.

at com.sap.engine.services.ejb3.jacc.ContainerJ2EESecurityProviderBaseImpl.determineUserName(ContainerJ2EESecurityProviderBaseImpl.java:215)

at com.sap.engine.services.ejb3.jacc.ContainerJ2EESecurityProviderBaseImpl.initRunAs(ContainerJ2EESecurityProviderBaseImpl.java:121)

at com.sap.engine.services.ejb3.jacc.ContainerJ2EESecurityProviderBaseImpl.<init>(ContainerJ2EESecurityProviderBaseImpl.java:64)

at com.sap.engine.services.ejb3.jacc.ContainerJ2EESecurityProviderStandardImpl.<init>(ContainerJ2EESecurityProviderStandardImpl.java:34)

at com.sap.engine.services.ejb3.jacc.ContainerJ2EESecurityProviderFactory.getContainerJ2EESecurityProvider(ContainerJ2EESecurityProviderFactory.java:34)

at com.sap.engine.services.ejb3.jacc.JACCSecurityManager.getContainerJ2EESecurityProvider(JACCSecurityManager.java:167)

I'm not sure if there are other things I need to configure? I couldn't find any place to configure the Guest user to belong to the J2EE role MyRole in NWA. Does this need to happen somewhere else?

Also, is thier documentation or examples for JAAS security in SAP EE5?

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

I think you should make sure that security role MyRole is defined for the server's user store and appropariate users are assigned to it.

You can maintain the security role using the NWA. Once you start it, browse to Operations Management -> User and Access Management -> Identity Management. From a drop-down list select Roles and then maintain your role.

Documentation regarding maintaing users, roles, etc. is available in the <a href="https://www.sdn.sap.comhttp://www.sdn.sap.comhttp://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/library/uuid/806e75a0-0e01-0010-2587-fc518de8ac1a">Administrator's Guide</a>.

Hope that helps!

Former Member
0 Kudos

Thanks Ivaylo!! I am new to SAP so it takes a little while to get around the administration pieces.

Answers (0)