Search code examples
javaweblogicwlst

How can I configure a custom UserNameMapper using WLST in Weblogic?


You can configure it using the console: https://docs.oracle.com/middleware/12212/wls/WLACH/taskhelp/security/ConfigureCustomUserNameMappers.html

How do you do the same thing in the Weblogic Scripting tool?

I already have example code for a Custom Username mapper, I need to figure out how to tell weblogic about it.


Solution

  • Found it.

    cd('/SecurityConfiguration/<yourDomain>/DefaultRealm/<yourSecurityRealm>/AuthenticationProviders/DefaultIdentityAsserter')
    set('UseDefaultUserNameMapper','false')
    set('UserNameMapperClassName','custom.UserNameMapper')
    

    Could not find it before because I was doing dir() instead of ls() .