Chris Carlson

Qualys Cloud Suite 2.30 API Notification 1

Blog Post created by Chris Carlson Employee on Jul 13, 2017

A new release of Qualys Cloud Suite, Version 2.30 includes an updated API which is targeted for release in September 2017. The specific day will differ depending on the platform. See platform release dates on the Qualys Status page. This API notification provides an early preview into the coming API, allowing you to identify use cases that can leverage this updated API and make changes to any scripts that utilize this specific API.

 

Host Asset Management API adds additional Amazon EC2 Instance Metadata

 

The Host Asset Management API now adds additional metadata of Amazon EC2 hosts when inventoried using the Qualys EC2 Connector.  The API output schema is changed to add new tags for additional EC2 metadata, populated with respective values for EC2 assets and empty for non-EC2 assets.

 

The new EC2 tags in the <Ec2AssetSourceSimple> element include:

 

<ec2InstanceTags>

<EC2Tags>

<createdDate>

<instanceState>

<groupId>

<groupName>

<spotInstance>

<ownerId>

<subnetId>

<vpcId>

<region>

<zone>

<publicIpAddress>

<accountId>

 

The example below is of the full output with the new and existing tags:

 

<?xml version="1.0" encoding="UTF-8"?>
<ServiceResponse xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="http://v-qps1.dev.qualys.com:8080/portal-api/xsd/2.0/am/hostasset.xsd">
   <responseCode>SUCCESS</responseCode>
   <count>1</count>
   <data>
       <HostAsset>
           <id>52331</id>
           <name>wenlin_scanner_sjc</name>
           <created>2017-06-15T02:34:25Z</created>
           <modified>2017-06-15T04:34:02Z</modified>
           <type>HOST</type>
           <tags>
               <list>
                   <TagSimple>
                       <id>7515612</id>
                       <name>AWS-Connector#2</name>
                   </TagSimple>
               </list>
           </tags>
           <sourceInfo>
               <list>
                   <Ec2AssetSourceSimple>
                       <firstDiscovered>2017-06-15T02:34:27Z</firstDiscovered>
                       <lastUpdated>2017-06-21T01:37:04Z</lastUpdated>
                       <assetId>52331</assetId>
                       <ec2InstanceTags>
                           <tags>
                               <list>
                                   <EC2Tags>
                                       <key>Name</key>
                                       <value>wn_scanner_sjc</value>
                                   </EC2Tags>
                                   <EC2Tags>
                                       <key>wn_scanner_sjc</key>
                                   </EC2Tags>
                               </list>
                           </tags>
                       </ec2InstanceTags>
                       <availabilityZone>us-west-1c</availabilityZone>
                       <instanceId>i-07d6f50d34s2e22a2ac69</instanceId>
                       <instanceType>t2.medium</instanceType>
                       <createdDate>2017-06-20T18:52:38Z</createdDate>
                       <instanceState>RUNNING</instanceState>
                       <groupId>sg-5547324f32</groupId>
                       <groupName>sg-5547324f32</groupName>
                       <spotInstance>true</spotInstance>
                       <ownerId>2057623237712438</ownerId>
                       <subnetId>subnet-b7dc77adbde</subnetId>
                       <vpcId>vpc-a334bdc7bca</vpcId>
                       <region>us-west-1</region>
                       <zone>VPC</zone>
                       <imageId>ami-169bc676</imageId>
                       <publicIpAddress>127.0.0.1</publicIpAddress>
                       <privateIpAddress>10.91.76.239</privateIpAddress>

<accountId>18943245667116622211526272</accountId>
            <monitoringEnabled>false</monitoringEnabled>
                   </Ec2AssetSourceSimple>
               </list>
           </sourceInfo>
           <os>Linux</os>
           <address>10.91.76.239</address>
           <trackingMethod>INSTANCE_ID</trackingMethod>
           <openPort>
               <list/>
           </openPort>
           <software>
               <list/>
           </software>
           <vuln>
               <list/>
           </vuln>
           <processor>
               <list/>
           </processor>
           <volume>
               <list/>
           </volume>
           <account>
               <list/>
           </account>
           <networkInterface>
               <list>
                   <HostAssetInterface>
                       <interfaceId>eni-50851450</interfaceId>
                       <interfaceName>Primary network interface</interfaceName>
                       <type>PRIVATE</type>
                       <address>10.91.76.239</address>
                   </HostAssetInterface>
               </list>
           </networkInterface>
       </HostAsset>
   </data>
</ServiceResponse>

Outcomes