AnsweredAssumed Answered

Cannot update host assets

Question asked by Edward Luck on May 21, 2019

I'm trying to remove an asset tag from a list of host assets (which worked in 2018), but now it does not work.

 

Here's the curl command using an account with Manager privileges and full scope:
curl -u <name>:<password> -X "POST" -H "Content-Type: text/xml" -H "Cache-Control: no-cache" --data-binary @- "https://qualysapi.qg2.apps.qualys.com/qps/rest/2.0/update/am/hostasset" < incorrect-tags.xml

 

Here's the XML content:

<?xml version="1.0" encoding="UTF-8" ?>
<ServiceRequest>
   <filters>
      <Criteria field="id" operator="IN">123456789,987654321</Criteria>
   </filters>
   <data>
      <HostAsset>
         <tags>
            <remove>
               <TagSimple><id>12345678</id><TagSimple>
            </remove>
         </tags>
      </HostAsset>
   </data>
</ServiceRequest>

 

I constantly receive the following error now:

 

<?xml version="1.0" encoding="UTF-8"?>
<ServiceResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="https://qualysapi.qg2.apps.qualys.com/qps/xsd/2.0/am/hostasset.xsd">
<responseCode>OTHER_ERROR</responseCode>
<responseErrorDetails>
<errorMessage>An error occurred during request processing. Please contact your account manager.</errorMessage>
</responseErrorDetails>

 

What gives?

Outcomes