0
votes

When I migrated worklight 6.1 projects to 7.0 , it was done successfully. Then when I deployed the adapter and invoked it. It gave me the below output:

"errors": ["Runtime: Adapter 'GetUserInfo' security test has no user realm."],"info": [],"isSuccessful": false, "warnings": []}

I had removed the security test from the procedure GetUserInfo in adapter.xml but I am not able to invoke it.

Here is my authenticationconfig.xml code:

<securityTests>
    <mobileSecurityTest name="customTests">
        <testDeviceId provisioningType="none"/>
        <testUser realm="WASLTPARealm"/>
    </mobileSecurityTest>
    <webSecurityTest name="mobileTests">
        <testUser realm="WASLTPARealm"/>
    </webSecurityTest>
    <!-- 
    -->
    <customSecurityTest name="SubscribeServlet">
        <test realm="wl_directUpdateRealm" step="1"/>
        <test isInternalUserID="true" realm="SubscribeServlet"/>
    </customSecurityTest>
</securityTests>
<realms>
    <realm loginModule="StrongDummy" name="SampleAppRealm">
        <className>com.worklight.core.auth.ext.FormBasedAuthenticator</className>
    </realm>
    <!--IBM migration removed realm named WorklightConsole. It is not supported as of Worklight v6.2. Original xml kept in backup file.-->
    <realm loginModule="rejectAll" name="SubscribeServlet">
        <className>com.worklight.core.auth.ext.HeaderAuthenticator</className>
    </realm>
    <!-- For websphere -->
    <realm loginModule="WASLTPAModule" name="WASLTPARealm">
        <className>com.worklight.core.auth.ext.WebSphereFormBasedAuthenticator</className>
        <parameter name="login-page" value="/login.html"/>
        <parameter name="error-page" value="/loginError.html"/>
    </realm>
</realms>
<loginModules>
    <loginModule name="StrongDummy">
        <className>com.worklight.core.auth.ext.NonValidatingLoginModule</className>
    </loginModule>
    <loginModule name="requireLogin">
        <className>com.worklight.core.auth.ext.SingleIdentityLoginModule</className>
    </loginModule>
    <loginModule name="rejectAll">
        <className>com.worklight.core.auth.ext.RejectingLoginModule</className>
    </loginModule>
    <!-- For websphere -->
    <loginModule name="WASLTPAModule">
        <className>com.worklight.core.auth.ext.WebSphereLoginModule</className>
    </loginModule>
</loginModules>

Please help me out with this.

1
The error message, I think, is saying you have a security test called 'GetUserInfo' applied to your adapter. Are you 100% sure you removed it, rebuilt, and redeployed successfully? - Andrew Ferrier
Can you share adapter XML? - Sami

1 Answers

0
votes

Did you specify a user realm in application-descriptor.xml?

<userIdentityRealms>my-realm</userIdentityRealms>