locked
[Windows Phone 8.1 MDM] Can not Disable Application via MDM RRS feed

  • Question

  • hi,

            Actually I met exactly the same problem as in this thread, https://social.msdn.microsoft.com/Forums/en-US/6d371d57-2ac7-435b-b3bd-5a834a2db402/windows-phone-81-mdm-can-not-disable-application-via-mdm?forum=developingmdmsolutions, but since the thread seemed not able to append the discuss so I opened a new one here.

          By the way,I also do some query after the request sent to device succesfully, the returned value from the device seemed exactly the same as in the request.

          Could anybody give me some info over this issue?

    Thanks

    Jennifer

    Friday, October 10, 2014 5:05 AM

All replies

  • Can you provide some extra information such as posting the SyncML messages here, so that we can understand the problem a little better? Which app are you trying to disable using MDM?

    Does the MDM Client running on the Phone return back a success message when your MDM server sends the command to disable the app? Meaning, that the command to disable the app is accepted fine, but the app is actually not disabled? Is that the problem or are you facing some other problem?


    Windows Store Developer Solutions, follow us on Twitter: @WSDevSol|| Want more solutions? See our blog

    Saturday, October 11, 2014 12:58 AM
  • I am using our MDM server to send the blacklist. I sent the request to device as following:

    <SyncML xmlns="SYNCML:SYNCML1.2">
    <SyncHdr>
    <VerDTD>1.2</VerDTD>
    <VerProto>DM/1.2</VerProto>
    <SessionID>65</SessionID>
    <MsgID>1</MsgID>
    <Target>
    <LocURI>IMEI:354589052630542</LocURI>
    </Target>
    <Source>
    <LocURI>https://10.202.196.72/wp8device//ManagementService.ashx?udid=5faecfd8-873a-4a1a-9254-7194480b0d35@acc</LocURI>
    </Source>
    <Cred>
    <Meta>
    <Format xmlns="syncml:metinf">b64</Format>
    <Type xmlns="syncml:metinf">syncml:auth-md5</Type>
    </Meta>
    <Data>nT7889k6DTxRZycZD8LHGQ==</Data>
    </Cred>
    </SyncHdr>
    <SyncBody>
    <Status>
    <CmdID>1</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>0</CmdRef>
    <Cmd>SyncHdr</Cmd>
    <Data>212</Data>
    </Status>
    <Status>
    <CmdID>2</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>2</CmdRef>
    <Cmd>Alert</Cmd>
    <Data>200</Data>
    </Status>
    <Status>
    <CmdID>3</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>3</CmdRef>
    <Cmd>Replace</Cmd>
    <Data>200</Data>
    </Status>
    <Atomic>
    <CmdID>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33</CmdID>
    <Replace>
    <CmdID>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33@@1</CmdID>
    <Item>
    <Target>
    <LocURI>./Vendor/MSFT/PolicyManager/My/ApplicationManagement/ApplicationRestrictions</LocURI>
    </Target>
    <Meta>
    <Format xmlns="syncml:metinf">chr</Format>
    <Type xmlns="syncml:metinf">text/plain</Type>
    </Meta>
    <Data><![CDATA[<AppPolicy Version="1" xmlns="http://schemas.microsoft.com/phone/2013/policy"><Deny><App ProductId="{98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4}"/><Publisher PublisherName="Microsoft Corporation"><AllowApp ProductId="{82a23635-5bd9-df11-a844-00237de2db9e}"/><AllowApp ProductId="{dcbb1ac6-a89a-df11-a490- 00237de2db9e}"/></Publisher></Deny></AppPolicy>]]></Data>
    </Item>
    </Replace>
    </Atomic>
    </SyncBody>
    </SyncML>

    The device response as following:

    <?xml version="1.0"?>
    <SyncML xmlns="SYNCML:SYNCML1.2">
    <SyncHdr>
    <VerDTD>1.2</VerDTD>
    <VerProto>DM/1.2</VerProto>
    <SessionID>65</SessionID>
    <MsgID>2</MsgID>
    <Target>
    <LocURI>https://10.202.196.72/wp8device//ManagementService.ashx?udid=5faecfd8-873a-4a1a-9254-7194480b0d35@acc</LocURI>
    </Target>
    <Source>
    <LocURI>IMEI:354589052630542</LocURI>
    </Source>
    </SyncHdr>
    <SyncBody>
    <Status>
    <Status>
    <CmdID>2</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33</CmdRef>
    <Cmd>Atomic</Cmd>
    <Data>200</Data>
    </Status>
    <Status>
    <CmdID>3</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33@@1</CmdRef>
    <Cmd>Replace</Cmd>
    <Data>200</Data>
    </Status>
    <Final/>
    </SyncBody>
    </SyncML>

    In the request , I disable the Angry Birds Go, http://www.windowsphone.com/zh-cn/store/app/angry-birds-go/98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4 , by specify <App ProductId="{98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4}"/> in <Deny>, and as you see the device reponse 200, but actually in device, I can still install/run Angry Birds Go.

    Could you help to sovle?

    Thanks

    Jennifer




    Saturday, October 11, 2014 4:32 AM
  • hi Prashant,

               I've posted request/response according to your requirement, could you please give me a hint what's the problem over the issue?

    Thanks

    Jennifer

    Monday, October 13, 2014 1:41 PM
  • Hi Jennifer,

    In the above payload it looks like you are:

    a.) Trying to deny the Angry Birds app with the Product ID: 98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4

    b.) Disallowing apps published by "Microsoft Corporation", but allow the Product ID: 82a23635-5bd9-df11-a844-00237de2db9e and dcbb1ac6-a89a-df11-a490- 00237de2db9e

    Instead of doing these 3 things together, let's just start with disabling Angry Birds (case a.) and then try doing case b.

    Can you change your XML payload (change the "Data" section which currently has <![CDATA[<AppPolicy...) and use the below instead? If you notice, I have changed the format by escaping the data like a proper XML document. Let me know the results.

    &lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;&lt;AppPolicy  Version=&quot;1&quot; xmlns=&quot;http://schemas.microsoft.com/phone/2013/policy&quot;&gt;&lt;Deny&gt;&lt;App ProductId=&quot;98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4&quot; /&gt;&lt;/Deny&gt;&lt;/AppPolicy&gt;


    Windows Store Developer Solutions, follow us on Twitter: @WSDevSol|| Want more solutions? See our blog


    Tuesday, October 14, 2014 12:24 AM
  • hi Prashant,

                 I've copied your xml into the "Data" section and send it to device, the request is as following

    <?xml version="1.0"?>
    <SyncML xmlns="SYNCML:SYNCML1.2">
    <SyncHdr>
    <VerDTD>1.2</VerDTD>
    <VerProto>DM/1.2</VerProto>
    <SessionID>78</SessionID>
    <MsgID>1</MsgID>
    <Target>
    <LocURI>IMEI:354589052630542</LocURI>
    </Target>
    <Source>
    <LocURI>https://10.202.196.72/wp8device//ManagementService.ashx?udid=5faecfd8-873a-4a1a-9254-7194480b0d35@acc</LocURI>
    </Source>
    <Cred>
    <Meta>
    <Format xmlns="syncml:metinf">b64</Format>
    <Type xmlns="syncml:metinf">syncml:auth-md5</Type>
    </Meta>
    <Data>KtppGoGsiKs5GbdfPKy71A==</Data>
    </Cred>
    </SyncHdr>
    <SyncBody>
    <Status>
    <CmdID>1</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>0</CmdRef>
    <Cmd>SyncHdr</Cmd>
    <Data>212</Data>
    </Status>
    <Status>
    <CmdID>2</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>2</CmdRef>
    <Cmd>Alert</Cmd>
    <Data>200</Data>
    </Status>
    <Status>
    <CmdID>3</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>3</CmdRef>
    <Cmd>Replace</Cmd>
    <Data>200</Data>
    </Status>
    <Atomic>
    <CmdID>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33</CmdID>
    <Replace>
    <CmdID>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33@@1</CmdID>
    <Item>
    <Target>
    <LocURI>./Vendor/MSFT/PolicyManager/My/ApplicationManagement/ApplicationRestrictions</LocURI>
    </Target>
    <Meta>
    <Format xmlns="syncml:metinf">chr</Format>
    <Type xmlns="syncml:metinf">text/plain</Type>
    </Meta>
    <Data><![CDATA[&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;&lt;AppPolicy Version=&quot;1&quot; xmlns=&quot;http://schemas.microsoft.com/phone/2013/policy&quot;&gt;&lt;Deny&gt;&lt;App ProductId=&quot;98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4&quot; /&gt;&lt;/Deny&gt;&lt;/AppPolicy&gt;]] ></Data>
    </Item>
    </Replace>
    </Atomic>
    </SyncBody>
    </SyncML>

            The device response as following:

    <?xml version="1.0"?>
    <SyncML xmlns="SYNCML:SYNCML1.2">
    <SyncHdr>
    <VerDTD>1.2</VerDTD>
    <VerProto>DM/1.2</VerProto>
    <SessionID>78</SessionID>
    <MsgID>2</MsgID>
    <Target>
    <LocURI>https://10.202.196.72/wp8device//ManagementService.ashx?udid=5faecfd8-873a-4a1a-9254-7194480b0d35@acc</LocURI>
    </Target>
    <Source>
    <LocURI>IMEI:354589052630542</LocURI>
    </Source>
    </SyncHdr>
    <SyncBody>
    <Status>
    <CmdID>1</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>0</CmdRef>
    <Cmd>SyncHdr</Cmd>
    <Chal>
    <Meta>
    <Format xmlns="syncml:metinf">b64</Format>
    <Type xmlns="syncml:metinf">syncml:auth-md5</Type>
    <NextNonce xmlns="syncml:metinf">1PazowFjbVzN9jKjwA0A3wY7+6lSMoVKPlZ6qcvNPGM=</NextNonce>
    </Meta>
    </Chal>
    <Data>212</Data>
    </Status>
    <Status>
    <CmdID>2</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33</CmdRef>
    <Cmd>Atomic</Cmd>
    <Data>200</Data>
    </Status>
    <Status>
    <CmdID>3</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33@@1</CmdRef>
    <Cmd>Replace</Cmd>
    <Data>200</Data>
    </Status>
    <Final/>
    </SyncBody>
    </SyncML>

            As you can see device response 200/OK for the request, but unfortunately, I can still run Angry Bird Go! in the device...

            Could you help to check?

    Thanks

    Jennifer


    Tuesday, October 14, 2014 4:08 AM
  • Hi Jennifer,

    Please change your <Data> section to look like this:

    ...// XML
    ...
    <Data>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;&lt;AppPolicy Version=&quot;1&quot; xmlns=&quot;http://schemas.microsoft.com/phone/2013/policy&quot;&gt;&lt;Deny&gt;&lt;App ProductId=&quot;98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4&quot; /&gt;&lt;/Deny&gt;&lt;/AppPolicy&gt;</Data>
    ...
    ...// XML


    Windows Store Developer Solutions, follow us on Twitter: @WSDevSol|| Want more solutions? See our blog

    Tuesday, October 14, 2014 4:50 PM
  • hi,

                 I have changed the data section as you suggested. see below

    <?xml version="1.0"?>
    -<SyncML xmlns="SYNCML:SYNCML1.2">
    -<SyncHdr>
    <VerDTD>1.2</VerDTD>
    <VerProto>DM/1.2</VerProto>
    <SessionID>2</SessionID>
    <MsgID>1</MsgID>
    -<Target>
    <LocURI>IMEI:354589052630542</LocURI>
    </Target>
    -<Source>
    <LocURI>https://192.168.1.113/wp8device//ManagementService.ashx?udid=108fc8bc-c3e1-4e10-af44-5061cafec309@acc</LocURI>
    </Source>
    -<Cred>
    -<Meta>
    <Format xmlns="syncml:metinf">b64</Format>
    <Type xmlns="syncml:metinf">syncml:auth-md5</Type>
    </Meta>
    <Data>hdIDDtCCrZfcu4Z95dlr/w==</Data>
    </Cred>
    </SyncHdr>
    -<SyncBody>
    -<Status>
    <CmdID>1</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>0</CmdRef>
    <Cmd>SyncHdr</Cmd>
    <Data>212</Data>
    </Status>
    -<Status>
    <CmdID>2</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>2</CmdRef>
    <Cmd>Alert</Cmd>
    <Data>200</Data>
    </Status>
    -<Status>
    <CmdID>3</CmdID>
    <MsgRef>1</MsgRef>
    <CmdRef>3</CmdRef>
    <Cmd>Replace</Cmd>
    <Data>200</Data>
    </Status>
    -<Atomic>
    <CmdID>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33</CmdID>
    -<Replace>
    <CmdID>bd3bdfec-d1ed-4342-9c1a-3dcc70d6e362@33@@1</CmdID>
    -<Item>
    -<Target>
    <LocURI>./Vendor/MSFT/PolicyManager/My/ApplicationManagement/ApplicationRestrictions</LocURI>
    </Target>
    -<Meta>
    <Format xmlns="syncml:metinf">chr</Format>
    <Type xmlns="syncml:metinf">text/plain</Type>
    </Meta>
    <Data>&lt;?xml version=&quot;1.0&quot; encoding=&quot;utf-8&quot;?&gt;&lt;AppPolicy Version=&quot;1&quot; xmlns=&quot;http://schemas.microsoft.com/phone/2013/policy&quot;&gt;&lt;Deny&gt;&lt;App ProductId=&quot;98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4&quot; /&gt;&lt;/Deny&gt;&lt;/AppPolicy&gt;</Data>
    </Item>
    </Replace>
    </Atomic>
    </SyncBody>
    </SyncML>

          but the result is the same...

          Could you help?

    Thanks

    Jennifer

    Thursday, October 16, 2014 12:05 PM
  • I think there is a mistake in the value of the "ProductId". You should use curly braces to delimit the product id:

    Your data:

    ProductId=&quot;98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4&quot;

    Correct data:

    ProductId=&quot;{98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4}&quot;

    I couldn't prove that with a test but this seems to be the only difference with the example provided at this link below (see bottom of the thread):

    https://social.msdn.microsoft.com/Forums/en-US/3f1dea49-d24b-4984-90d3-7351b5106e08/windows-phone-81-mdm-application-blacklisting-is-not-working?forum=developingmdmsolutions

    Also note that there are several variants of the "Angry Bird" app on the market store. Make sure that the app you have actually installed in your device is "Angry Birds Go!" (http://www.windowsphone.com/it-it/store/app/angry-birds-go/98fbba41-dafc-4b3e-83e5-21a8d7a4e0f4)

    Sunday, December 7, 2014 1:06 PM