It works now without <xsd1:requestPathAuthenticatorConfigs></xsd1:requestPathAuthenticatorConfigs>!
From: Omindu Rathnaweera [mailto:[email protected]] Sent: Monday, April 3, 2017 9:14 PM To: Illia Alifanov <[email protected]> Cc: [email protected] Subject: Re: [Dev] IS: createApplication in IdentityApplicationManagementService doesn't return application ID Can you try commenting out the following section from the 1 example request ? <xsd1:requestPathAuthenticatorConfigs></xsd1:requestPathAuthenticatorConfigs> On Mon, Apr 3, 2017 at 4:12 PM, Illia Alifanov <[email protected]<mailto:[email protected]>> wrote: I can update app through UI. This is request for example. <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://org.apache.axis2/xsd" xmlns:xsd1="http://model.common.application.identity.carbon.wso2.org/xsd"> <soapenv:Header/> <soapenv:Body> <xsd:updateApplication> <!--Optional:--> <xsd:serviceProvider> <xsd1:applicationID>108</xsd1:applicationID> <xsd1:applicationName>GServiceProvider</xsd1:applicationName> <xsd1:claimConfig> <xsd1:localClaimDialect>false</xsd1:localClaimDialect> <xsd1:alwaysSendMappedLocalSubjectId>false</xsd1:alwaysSendMappedLocalSubjectId> <xsd1:claimMappings> <xsd1:requested>true</xsd1:requested> <xsd1:localClaim> <xsd1:claimId>0</xsd1:claimId> <xsd1:claimUri>http://wso2.org/claims/userid</xsd1:claimUri> </xsd1:localClaim> <xsd1:remoteClaim> <xsd1:claimId>0</xsd1:claimId> <xsd1:claimUri>http://schemas.microsoft.com/ws/2008/06/identity/claims/userdata</xsd1:claimUri> </xsd1:remoteClaim> </xsd1:claimMappings> <xsd1:claimMappings> <xsd1:requested>true</xsd1:requested> <xsd1:localClaim> <xsd1:claimId>0</xsd1:claimId> <xsd1:claimUri>http://wso2.org/claims/role</xsd1:claimUri> </xsd1:localClaim> <xsd1:remoteClaim> <xsd1:claimId>0</xsd1:claimId> <xsd1:claimUri>http://schemas.microsoft.com/ws/2008/06/identity/claims/role</xsd1:claimUri> </xsd1:remoteClaim> </xsd1:claimMappings> <xsd1:roleClaimURI>http://schemas.microsoft.com/ws/2008/06/identity/claims/role</xsd1:roleClaimURI> </xsd1:claimConfig> <xsd1:description>description</xsd1:description> <xsd1:saasApp>true</xsd1:saasApp> <xsd1:inboundAuthenticationConfig> <xsd1:inboundAuthenticationRequestConfigs> <xsd1:friendlyName></xsd1:friendlyName> <xsd1:inboundAuthKey>GServiceProvider</xsd1:inboundAuthKey> <xsd1:inboundAuthType>samlsso</xsd1:inboundAuthType> <xsd1:inboundConfigType>standardAPP</xsd1:inboundConfigType> </xsd1:inboundAuthenticationRequestConfigs> </xsd1:inboundAuthenticationConfig> <xsd1:inboundProvisioningConfig> <xsd1:provisioningEnabled>false</xsd1:provisioningEnabled> <xsd1:provisioningUserStore>PRIMARY</xsd1:provisioningUserStore> </xsd1:inboundProvisioningConfig> <xsd1:localAndOutBoundAuthenticationConfig> <xsd1:alwaysSendBackAuthenticatedListOfIdPs>false</xsd1:alwaysSendBackAuthenticatedListOfIdPs> <xsd1:authenticationType>default</xsd1:authenticationType> </xsd1:localAndOutBoundAuthenticationConfig> <xsd1:outboundProvisioningConfig> </xsd1:outboundProvisioningConfig> <xsd1:owner> <xsd1:tenantDomain>carbon.super</xsd1:tenantDomain> <xsd1:userName>admin</xsd1:userName> <xsd1:userStoreDomain>PRIMARY</xsd1:userStoreDomain> </xsd1:owner> <xsd1:permissionAndRoleConfig> </xsd1:permissionAndRoleConfig> <xsd1:requestPathAuthenticatorConfigs> </xsd1:requestPathAuthenticatorConfigs> </xsd:serviceProvider> </xsd:updateApplication> </soapenv:Body> </soapenv:Envelope> But I have the same result for any update app request. I tried to send just this simple one and have the same error <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://org.apache.axis2/xsd" xmlns:xsd1="http://model.common.application.identity.carbon.wso2.org/xsd"> <soapenv:Header/> <soapenv:Body> <xsd:updateApplication> <!--Optional:--> <xsd:serviceProvider> <xsd1:applicationID>108</xsd1:applicationID> <xsd1:applicationName>GServiceProvider</xsd1:applicationName> <xsd1:description>description</xsd1:description> <xsd1:saasApp>true</xsd1:saasApp> </xsd:serviceProvider> </xsd:updateApplication> </soapenv:Body> </soapenv:Envelope> From: Omindu Rathnaweera [mailto:[email protected]<mailto:[email protected]>] Sent: Monday, April 3, 2017 1:35 PM To: Illia Alifanov <[email protected]<mailto:[email protected]>> Cc: [email protected]<mailto:[email protected]> Subject: Re: [Dev] IS: createApplication in IdentityApplicationManagementService doesn't return application ID Can you share the update request you are using ? Also, if possible, can you please try to update the created service provider through the management console UI. If the app can be updated through the UI, it usually means that there's an error in the update request. Regards, Omindu. On Mon, Apr 3, 2017 at 3:41 PM, Illia Alifanov <[email protected]<mailto:[email protected]>> wrote: I try to use admin services to create service providers, users and roles. I haven’t problems with creating users and roles but I have one with creating service provider. I can create it but can’t update. I receive Error occurred while updating the application: GServiceProvider. There is a wso2carbon.log TID: [-1234] [] [2017-04-03 13:10:07,847] WARN {org.wso2.carbon.server.admin.module.handler.AuthenticationHandler} - Illegal access attempt at [2017-04-03 13:10:07,0847] from IP address 172.20.20.94 while trying to authenticate access to service IdentityApplicationManagementService TID: [-1234] [] [2017-04-03 13:10:07,890] DEBUG {org.wso2.carbon.identity.core.util.IdentityUtil} - Error while reading user store property CaseInsensitiveUsername. Considering as case sensitive. TID: [-1234] [] [2017-04-03 13:10:07,890] DEBUG {org.wso2.carbon.identity.core.util.IdentityUtil} - Error while reading user store property CaseInsensitiveUsername. Considering as case sensitive. TID: [-1234] [] [2017-04-03 13:10:07,890] DEBUG {org.wso2.carbon.identity.core.util.IdentityUtil} - Error while reading user store property CaseInsensitiveUsername. Considering as case sensitive. TID: [-1234] [] [2017-04-03 13:10:07,891] DEBUG {org.wso2.carbon.identity.core.util.IdentityUtil} - Error while reading user store property CaseInsensitiveUsername. Considering as case sensitive. TID: [-1234] [] [2017-04-03 13:10:07,912] DEBUG {org.wso2.carbon.identity.core.util.IdentityUtil} - Error while reading user store property CaseInsensitiveUsername. Considering as case sensitive. TID: [-1234] [] [2017-04-03 13:10:07,914] DEBUG {org.wso2.carbon.identity.application.common.processors.RandomPasswordProcessor} - Cache Key not found for Random Password Container TID: [-1234] [] [2017-04-03 13:10:07,924] DEBUG {org.wso2.carbon.identity.application.common.processors.RandomPasswordProcessor} - Cache Key not found for Random Password Container TID: [-1234] [] [2017-04-03 13:10:07,926] DEBUG {org.wso2.carbon.identity.application.common.processors.RandomPasswordProcessor} - Cache Key not found for Random Password Container TID: [-1234] [] [2017-04-03 13:10:07,927] INFO {org.wso2.carbon.core.services.util.CarbonAuthenticationUtil} - '[email protected] [-1234]' logged in at [2017-04-03 13:10:07,927+0300] TID: [-1234] [] [2017-04-03 13:10:07,936] DEBUG {org.wso2.carbon.identity.application.mgt.ApplicationMgtUtil} - Checking whether user has role : Application/GServiceProvider by retrieving role list of user : admin TID: [-1234] [] [2017-04-03 13:10:07,953] DEBUG {org.wso2.carbon.identity.application.mgt.ApplicationMgtUtil} - Checking whether user has role : Application/GServiceProvider by retrieving role list of user : admin TID: [-1234] [] [2017-04-03 13:10:07,955] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Loading Application Name for ID: 108 TID: [-1234] [] [2017-04-03 13:10:07,955] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - ApplicationName : GServiceProvider TID: [-1234] [] [2017-04-03 13:10:07,955] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Updating Application with ID: 108 TID: [-1234] [] [2017-04-03 13:10:07,955] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Loading Application Name for ID: 108 TID: [-1234] [] [2017-04-03 13:10:07,955] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - ApplicationName : GServiceProvider TID: [-1234] [] [2017-04-03 13:10:07,956] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Stored Application Name GServiceProvider TID: [-1234] [] [2017-04-03 13:10:07,956] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Updated Application successfully TID: [-1234] [] [2017-04-03 13:10:07,956] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Deleting Clients of the Application 108 TID: [-1234] [] [2017-04-03 13:10:07,956] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Updating inbound authentication request configuration of the application 108inbound auth key: GServiceProvider inbound auth type: samlsso TID: [-1234] [] [2017-04-03 13:10:07,957] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Deleting Steps of Application 108 TID: [-1234] [] [2017-04-03 13:10:07,957] DEBUG {org.wso2.carbon.identity.application.mgt.dao.impl.ApplicationDAOImpl} - Deleting request path authenticators 108 TID: [-1] [] [2017-04-03 13:10:36,544] WARN {java.util.prefs.FileSystemPreferences} - Could not lock System prefs. Unix error code 0. TID: [-1] [] [2017-04-03 13:10:36,544] WARN {java.util.prefs.FileSystemPreferences} - Couldn't flush system prefs: java.util.prefs.BackingStoreException: Couldn't get file lock. From: Omindu Rathnaweera [mailto:[email protected]<mailto:[email protected]>] Sent: Monday, April 3, 2017 12:57 PM To: Illia Alifanov <[email protected]<mailto:[email protected]>> Cc: [email protected]<mailto:[email protected]> Subject: Re: [Dev] IS: createApplication in IdentityApplicationManagementService doesn't return application ID Hi Illia, Seems that the return type was changed to void while fixing an issue ([1], [2]) and the doc comment was not updated accordingly. Can we know your exact requirement so we can provide an alternative to this? [1] - https://github.com/wso2/carbon-identity/pull/976 [2] - https://wso2.org/jira/browse/IDENTITY-2558 Regards, Omindu. On Mon, Apr 3, 2017 at 3:15 PM, Illia Alifanov <[email protected]<mailto:[email protected]>> wrote: Dear, WSO2 dev team, You have a bit confused situation in carbon-identity source code with creatApplication method. https://github.com/wso2/carbon-identity/blob/master/components/application-mgt/org.wso2.carbon.identity.application.mgt/src/main/java/org/wso2/carbon/identity/application/mgt/ApplicationManagementAdminService.java We can see in comments @return application id But void in the method signature. /** * Creates a service provider with basic information.First we need to create * a role with the * application name. Only the users in this role will be able to edit/update * the application.The * user will assigned to the created role.Internal roles used. * * @param serviceProvider Service provider * @return application id * @throws org.wso2.carbon.identity.application.common.IdentityApplicationManagementException */ public void createApplication(ServiceProvider serviceProvider) throws IdentityApplicationManagementException { applicationMgtService = ApplicationManagementService.getInstance(); applicationMgtService.createApplication(serviceProvider, getTenantDomain(), getUsername()); } Regards, Illia. ________________________________ This e-mail may contain privileged and confidential information. If you are not the intended recipient, be aware that any use, disclosure, copying or distribution of this e-mail or any attachments is prohibited. If you have received this e-mail in error, please notify us immediately by returning it to the sender and delete this copy from your system. Thank you. _______________________________________________ Dev mailing list [email protected]<mailto:[email protected]> http://wso2.org/cgi-bin/mailman/listinfo/dev -- Omindu Rathnaweera Senior Software Engineer, WSO2 Inc. Mobile: +94 771 197 211<tel:+94%2077%20119%207211> ________________________________ This e-mail may contain privileged and confidential information. If you are not the intended recipient, be aware that any use, disclosure, copying or distribution of this e-mail or any attachments is prohibited. If you have received this e-mail in error, please notify us immediately by returning it to the sender and delete this copy from your system. Thank you. -- Omindu Rathnaweera Senior Software Engineer, WSO2 Inc. Mobile: +94 771 197 211<tel:+94%2077%20119%207211> ________________________________ This e-mail may contain privileged and confidential information. If you are not the intended recipient, be aware that any use, disclosure, copying or distribution of this e-mail or any attachments is prohibited. If you have received this e-mail in error, please notify us immediately by returning it to the sender and delete this copy from your system. Thank you. -- Omindu Rathnaweera Senior Software Engineer, WSO2 Inc. Mobile: +94 771 197 211 ________________________________ This e-mail may contain privileged and confidential information. If you are not the intended recipient, be aware that any use, disclosure, copying or distribution of this e-mail or any attachments is prohibited. If you have received this e-mail in error, please notify us immediately by returning it to the sender and delete this copy from your system. Thank you.
_______________________________________________ Dev mailing list [email protected] http://wso2.org/cgi-bin/mailman/listinfo/dev
