While updating permissions to service provider, sometimes leaf nodes are not getting deleted.
For example,
following permissions exist in Service Provider,
BILL/ADD
BILL/REMOVE
REPORT/ADD
REPORT/REMOVE
on update with only following permission,
REPORT/ADD
REPORT/REMOVE
Sample SOAP Call:
Endpoint:
services/IdentityApplicationManagementService.IdentityApplicationManagementServiceHttpsSoap11Endpoint/
<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>
<xsd:serviceProvider>
<xsd1:applicationID>1</xsd1:applicationID>
<xsd1:applicationName>SP1</xsd1:applicationName>
<xsd1:permissionAndRoleConfig>
<xsd1:permissions>
<xsd1:value>REPORT/ADD</xsd1:value>
</xsd1:permissions>
<xsd1:permissions>
<xsd1:value>REPORT/REMOVE</xsd1:value>
</xsd1:permissions>
</xsd1:permissionAndRoleConfig>
<xsd1:inboundProvisioningConfig>
</xsd1:inboundProvisioningConfig>
<xsd1:outboundProvisioningConfig>
</xsd1:outboundProvisioningConfig>
</xsd:serviceProvider>
</xsd:updateApplication>
</soapenv:Body>
</soapenv:Envelope>
BILL/ADD & BILL/REMOVE has been removed. But after successful update, "BILL" still exist in permission list.
After Update:
BILL
REPORT/ADD
REPORT/REMOVE
And on sometimes, adding/removing multiple permission collapses the other permission nodes