[jboss-dev-forums] [JBoss AS 7 Development] - Using JBoss Negotiation on AS7

guillaume cornet do-not-reply at jboss.com
Thu Nov 29 11:25:02 EST 2012


guillaume cornet [https://community.jboss.org/people/raoulpetitpied] commented on the document

"Using JBoss Negotiation on AS7"

To view all comments on this document, visit: https://community.jboss.org/docs/DOC-16876#comment-11198

--------------------------------------------------
@Tim H


You can acheive the same results in a 'cleaner' way, with the PropertiesRolesMappingProvider.
Just replace your 'RealmUsersRoles' login-module with :

<mapping>
    <mapping-module code="PropertiesRoles" type="role">
        <module-option name="rolesProperties" value="/path/to/users-roles-mapping.properties" />
    </mapping-module>
</mapping>

And the content of '/path/to/users-roles-mapping.properties' should be
username at DOMAIN=Users
username2 at DOMAIN=Users
username3 at DOMAIN=Users



An alternate solution is to use the 'SimpleRolesMappingProvider' mapping-module :

<mapping>
    <mapping-module code="SimpleRoles" type="role">
        <module-option name="username at DOMAIN" value="Users" />
        <module-option name="username2 at DOMAIN" value="Users" />
        <module-option name="username3 at DOMAIN" value="Users" />
    </mapping-module>
</mapping>

Cheers
--------------------------------------------------

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-dev-forums/attachments/20121129/92be10ac/attachment.html 


More information about the jboss-dev-forums mailing list