@@ -1427,6 +1427,205 @@ paths:
14271427 $ref : ' responses.yaml#/UnavailableError'
14281428 security :
14291429 - x-aims-auth-token : []
1430+ post :
1431+ summary : Query Exposures
1432+ operationId : query_exposures_post
1433+ description : |-
1434+ Groups vulnerabilities for an account by exposure (by default), remediation, or vulnerable asset.
1435+ In combination with filtering, it's easy to view vulnerabilities across your account in the manner
1436+ most appropriate.
1437+
1438+ *Note*: exposures uses a `threatiness` property which is an internal measurement used for
1439+ relative comparison and is not considered useful for external purposes.
1440+
1441+ Vulnerabilities can be filtered using the `filter` parameter in the query string. The `filter` param
1442+ can be used multiple times. The [remediation filters](#section/Remediation-filters) documented above
1443+ are allowed.
1444+ tags :
1445+ - Exposures and Remediations
1446+ requestBody :
1447+ content :
1448+ application/json :
1449+ schema :
1450+ type : object
1451+ properties :
1452+ concluded :
1453+ $ref : parameters.yaml#/ExposuresConcluded
1454+ details :
1455+ $ref : parameters.yaml#/ExposuresDetails
1456+ disposed :
1457+ $ref : parameters.yaml#/ExposuresDisposed
1458+ filters :
1459+ $ref : parameters.yaml#/ExposuresFilters
1460+ group :
1461+ $ref : parameters.yaml#/ExposuresGroup
1462+ include_exposures :
1463+ $ref : parameters.yaml#/IncludeExposures
1464+ included_filters :
1465+ $ref : parameters.yaml#/IncludeFilters
1466+ included_remediations :
1467+ $ref : parameters.yaml#/IncludeRemediations
1468+ include_remediation_items :
1469+ $ref : parameters.yaml#/IncludeRemediationItems
1470+ limit :
1471+ $ref : parameters.yaml#/ExposuresLimit
1472+ scope :
1473+ $ref : parameters.yaml#/ScopeTrue
1474+ sort :
1475+ $ref : parameters.yaml#/ExposuresSort
1476+ security :
1477+ - x-aims-auth-token : []
1478+ x-codeSamples :
1479+ - lang : Shell
1480+ label : Basic exposures query
1481+ source : |-
1482+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1483+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1484+ {}
1485+ EOF
1486+ - lang : Shell
1487+ label : Exposures with filter by deployment ID
1488+ source : |-
1489+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1490+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1491+ {
1492+ "filters": ["deployment_id:814C2911-09BB-1005-9916-7831C1BAC182"]
1493+ }
1494+ EOF
1495+ - lang : Shell
1496+ label : ' Exposures with filter on deployment ID, subnet, image, and application'
1497+ source : |-
1498+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1499+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1500+ {
1501+ "filters": [
1502+ "deployment_id:814C2911-09BB-1005-9916-7831C1BAC182",
1503+ "subnet:/aws/us-east-1/subnet/subnet-1a-web",
1504+ "image:/aws/us-east-1/image/ami-1",
1505+ "application:Apache"
1506+ ],
1507+ }
1508+ EOF
1509+ - lang : Shell
1510+ label : Basic remediations query
1511+ source : |-
1512+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1513+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1514+ {
1515+ "group": "remediation"
1516+ }
1517+ EOF
1518+ - lang : Shell
1519+ label : Remediations with filter by deployment ID
1520+ source : |-
1521+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1522+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1523+ {
1524+ "filters": ["deployment_id:814C2911-09BB-1005-9916-7831C1BAC182"],
1525+ "group": "remediation"
1526+ }
1527+ EOF
1528+ - lang : Shell
1529+ label : ' Remediations with filter on deployment ID, subnet, image, and application'
1530+ source : |-
1531+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1532+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1533+ {
1534+ "filters": [
1535+ "deployment_id:814C2911-09BB-1005-9916-7831C1BAC182",
1536+ "subnet:/aws/us-east-1/subnet/subnet-1a-web",
1537+ "image:/aws/us-east-1/image/ami-1",
1538+ "application:Apache"
1539+ ],
1540+ "group": "remediation"
1541+ }
1542+ EOF
1543+ - lang : Shell
1544+ label : Basic vulnerable assets query
1545+ source : |-
1546+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1547+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1548+ {
1549+ "group": "asset"
1550+ }
1551+ EOF
1552+ - lang : Shell
1553+ label : Vulnerable assets with filter by deployment ID
1554+ source : |-
1555+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1556+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1557+ {
1558+ "filters": [
1559+ "deployment_id:814C2911-09BB-1005-9916-7831C1BAC182"
1560+ ],
1561+ "group": "asset"
1562+ }
1563+ EOF
1564+ - lang : Shell
1565+ label : ' Vulnerable assets with filter on deployment ID, subnet, image, and application'
1566+ source : |-
1567+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1568+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1569+ {
1570+ "filters": [
1571+ "deployment_id:814C2911-09BB-1005-9916-7831C1BAC182",
1572+ "subnet:/aws/us-east-1/subnet/subnet-1a-web",
1573+ "image:/aws/us-east-1/image/ami-1",
1574+ "application:Apache"
1575+ ],
1576+ "group": "asset"
1577+ }
1578+ EOF
1579+ - lang : Shell
1580+ label : Most vulnerable assets by type (host)
1581+ source : |-
1582+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/exposures" \
1583+ -X POST -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
1584+ {
1585+ "filters": [
1586+ "asset_type:host"
1587+ ],
1588+ "group": "asset"
1589+ }
1590+ EOF
1591+ responses :
1592+ ' 200 ' :
1593+ description : OK
1594+ content :
1595+ application/json :
1596+ schema :
1597+ $ref : schemas.yaml#/QueryExposuresResponse
1598+ examples :
1599+ ' Exposures (include_filters=false, include_exposures=false) ' :
1600+ $ref : examples.yaml#/QueryExposuresExample
1601+ ' Exposures for whole account (details=true, include_filters=true) ' :
1602+ $ref : examples.yaml#/QueryExposuresWholeAccountExample
1603+ ' Exposures for specific deployment ID (details=false, include_filters=true) ' :
1604+ $ref : examples.yaml#/QueryExposuresSpecificDeploymentExample
1605+ ' Remediations (include_filters=false, include_remediations=false) ' :
1606+ $ref : examples.yaml#/QueryExposuresRemediationsExample
1607+ ' Remediations for whole account (details=true, include_filters=true, include_remediation_items=true) ' :
1608+ $ref : examples.yaml#/QueryExposuresRemediationsWholeAccountExample
1609+ ' Remediations for specific deployment ID (details=false, include_filters=true) ' :
1610+ $ref : examples.yaml#/QueryExposuresRemediationsSpecificDeploymentExample
1611+ ' Vulnerable assets (include_filters=false, include_exposures=false) ' :
1612+ $ref : examples.yaml#/QueryExposuresVulnerableAssetsExample
1613+ ' Vulnerable assets for whole account (details=true, include_filters=true) ' :
1614+ $ref : examples.yaml#/QueryExposuresVulnerableAssetsWholeAccountExample
1615+ ' Vulnerable assets for specific deployment ID (details=false, include_filters=true) ' :
1616+ $ref : examples.yaml#/QueryExposuresVulnerableAssetsSpecificDeploymentExample
1617+ ' Most vulnerable assets by type (group=asset, filter=asset_type:host, limit=2) ' :
1618+ $ref : examples.yaml#/QueryExposuresMostVulnerableAssetsExample
1619+ ' 400 ' :
1620+ $ref : responses.yaml#/InvalidValueError
1621+ ' 401 ' :
1622+ $ref : responses.yaml#/Unauthorized
1623+ ' 403 ' :
1624+ $ref : responses.yaml#/Forbidden
1625+ ' 404 ' :
1626+ $ref : responses.yaml#/NotFound
1627+ ' 503 ' :
1628+ $ref : responses.yaml#/UnavailableError
14301629 /assets_query/v2/{account_id}/remediation-items :
14311630 parameters :
14321631 - $ref : ' parameters.yaml#/UrlParamAccountId'
@@ -2137,6 +2336,7 @@ paths:
21372336 -X PUT -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
21382337 {
21392338 "operation": "dispose_remediations",
2339+ "applies_to_specific_assets": true,
21402340 "comment": "Vulnerable database contains automated test data, not customer records.",
21412341 "filters": [
21422342 "application:Apache",
@@ -2155,6 +2355,7 @@ paths:
21552355 -X PUT -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
21562356 {
21572357 "operation": "conclude_remediations",
2358+ "applies_to_specific_assets": true,
21582359 "filters": [
21592360 "application:Apache",
21602361 "image:/aws/us-east-1/image/ami-1"
0 commit comments