@@ -1496,6 +1496,7 @@ paths:
14961496 - Exposures and Remediations
14971497 parameters :
14981498 - $ref : ' parameters.yaml#/ParamConcluded'
1499+ - $ref : ' parameters.yaml#/ParamQueryExposuresBasicDetails'
14991500 - $ref : ' parameters.yaml#/ParamQueryExposuresDetails'
15001501 - $ref : ' parameters.yaml#/ParamDisposed'
15011502 - $ref : ' parameters.yaml#/ParamQueryExposuresFilter'
@@ -1622,6 +1623,8 @@ paths:
16221623 properties :
16231624 concluded :
16241625 $ref : parameters.yaml#/ExposuresConcluded
1626+ basic_details :
1627+ $ref : parameters.yaml#/ExposuresBasicDetails
16251628 details :
16261629 $ref : parameters.yaml#/ExposuresDetails
16271630 disposed :
@@ -1845,6 +1848,8 @@ paths:
18451848 schema :
18461849 $ref : ' schemas.yaml#/QueryRemediationItemsResponse'
18471850 examples :
1851+ Default Response (when existing remediation-item filter_match_mode is any) :
1852+ $ref : ' examples.yaml#/QueryRemediationItemsFilterMatchModeAnyExample'
18481853 Default Response (single deployment) :
18491854 $ref : ' examples.yaml#/QueryRemediationItemsSingleDeploymentExample'
18501855 Default Response (single deployment, details=true) :
@@ -2412,18 +2417,8 @@ paths:
24122417 - $ref : ' parameters.yaml#/UrlParamAccountId'
24132418 put :
24142419 operationId : dispose_conclude_remediations
2415- summary : Dispose/Conclude Remediations
2420+ summary : Conclude/ Dispose/Undispose Remediations
24162421 description : |-
2417- `dispose_remediations` disposes the vulnerability instances (`"vinstances"`) associated with a
2418- set of `remediations` or `vulnerabilities` (by ID). A set of `remediation-item`s is created, 1
2419- per deployment/remediation_id/vulnerability_id, with the state set to `"disposed"` and all
2420- vulnerability instances associated to that `"remediation_id"` or `"vulnerability_id"` on
2421- assets described by the given `"filters"` have their `"disposed"` property set to `true`.
2422-
2423- Note that, if the `"expires"` property is set on a `"disposed"` remediation-item, that item will
2424- be undisposed when the `"expires"` timestamp is in the past, and all associated vulnerability
2425- instances will have their `"disposed"` property set back to `false`.
2426-
24272422 `conclude_remediations` concludes the vulnerability instances (`"vinstances"`) associated with a
24282423 set of `remediations` or `vulnerabilities` (by ID). A set of `remediation-item`s is created, 1
24292424 per deployment/remediation_id/vulnerability_id, with the state set to `"concluded"` and all
@@ -2436,37 +2431,69 @@ paths:
24362431 *will be* unconcluded (their `"concluded"` property will be set to `false`). If *all*
24372432 existing vulnerability instances are newer than the `remediation-item`, then the
24382433 `remediation-item` will be cleared (deleted).
2434+
2435+ `dispose_remediations` disposes the vulnerability instances (`"vinstances"`) associated with a
2436+ set of `remediations` or `vulnerabilities` (by ID). A set of `remediation-item`s is created, 1
2437+ per deployment/remediation_id/vulnerability_id, with the state set to `"disposed"` and all
2438+ vulnerability instances associated to that `"remediation_id"` or `"vulnerability_id"` on
2439+ assets described by the given `"filters"` have their `"disposed"` property set to `true`.
2440+
2441+ Note that, if the `"expires"` property is set on a `"disposed"` remediation-item, that item will
2442+ be undisposed when the `"expires"` timestamp is in the past, and all associated vulnerability
2443+ instances will have their `"disposed"` property set back to `false`.
2444+
2445+ `undispose_remediations` partially undispose (or unconclude) the given `remediation-item`(s). The
2446+ `remediation-item`, if it exists, will be updated to only cover filters other than given
2447+ filters in the request. If all filters match, the `remediation-items` will be deleted.
2448+ Any vulnerability instances that were concluded or disposed by the remediation-item will be
2449+ accordingly unconcluded and undisposed (that is, their `concluded` and `disposed` properties
2450+ will be set to `false`). **Note** that this operation will only effectively partially remove
2451+ filters if the `remediation-item` has the `filter_match_mode` flag set to `any`. Otherwise,
2452+ the remediation-item will be deleted. **Note** that because of the way the `remediation_id`
2453+ is generated, if a remediation-item is partially undisposed/unconcluded, the output
2454+ remediation-item will contain a diffent `remediation_id`. In other words, the old remediation-item
2455+ will be deleted an replaced with a remediation-item with a diff of existing filters and request filters.
24392456 tags :
24402457 - Exposures and Remediations
24412458 requestBody :
24422459 content :
24432460 application/json :
24442461 schema :
24452462 oneOf :
2446- - $ref : ' schemas.yaml#/DisposeRemediationsRequestBody'
24472463 - $ref : ' schemas.yaml#/ConcludeRemediationsRequestBody'
2464+ - $ref : ' schemas.yaml#/DisposeRemediationsRequestBody'
2465+ - $ref : ' schemas.yaml#/UndisposeRemediationsRequestBody'
24482466 responses :
24492467 " 201 " :
24502468 description : Created
24512469 content :
24522470 application/json :
24532471 schema :
24542472 oneOf :
2455- - $ref : ' schemas.yaml#/DisposeRemediationsResponse'
24562473 - $ref : ' schemas.yaml#/ConcludeRemediationsResponse'
2474+ - $ref : ' schemas.yaml#/DisposeRemediationsResponse'
2475+ - $ref : ' schemas.yaml#/UndisposeRemediationsResponse'
24572476 examples :
2477+ Conclude a single remediation :
2478+ $ref : ' examples.yaml#/ConcludeSingleRemediationExample'
2479+ Conclude a single remediation for 2 hosts with a filters set :
2480+ $ref : ' examples.yaml#/ConcludeSingleRemediationFiltersSetExample'
2481+ Conclude a single vulnerability :
2482+ $ref : ' examples.yaml#/ConcludeSingleVulnerabilityExample'
24582483 Dispose a single remediation :
24592484 $ref : ' examples.yaml#/DisposeSingleRemediationExample'
24602485 Dispose a single remediation for 2 hosts with a filters set :
24612486 $ref : ' examples.yaml#/DisposeSingleRemediationFiltersSetExample'
24622487 Dispose a single vulnerability :
24632488 $ref : ' examples.yaml#/DisposeSingleVulnerabilityExample'
2464- Conclude a single remediation :
2465- $ref : ' examples.yaml#/ConcludeSingleRemediationExample'
2466- Conclude a single remediation for 2 hosts with a filters set :
2467- $ref : ' examples.yaml#/ConcludeSingleRemediationFiltersSetExample'
2468- Conclude a single vulnerability :
2469- $ref : ' examples.yaml#/ConcludeSingleVulnerabilityExample'
2489+ Dispose a single remediation for 2 hosts (filter_match_mode=any) :
2490+ $ref : ' examples.yaml#/DisposeSingleRemediationFilterMatchModeExample'
2491+ Partially undispose a single remediation by remediation-item ID :
2492+ $ref : ' examples.yaml#/PartiallyUndisposeByRemediationItemId'
2493+ Partially undispose a remediation-item by audit_id/vulnerability_id :
2494+ $ref : ' examples.yaml#/PartiallyUndisposeByAuditId'
2495+ " 204 " :
2496+ description : No Content (full undispose remediations response)
24702497 " 400 " :
24712498 $ref : ' responses.yaml#/InvalidValueError'
24722499 " 401 " :
@@ -2550,6 +2577,7 @@ paths:
25502577 "operation": "dispose_remediations",
25512578 "applies_to_specific_assets": true,
25522579 "comment": "Vulnerable database contains automated test data, not customer records.",
2580+ "filter_match_mode": "all",
25532581 "filters": [
25542582 "application:Apache",
25552583 "image:/aws/us-east-1/image/ami-1"
@@ -2560,6 +2588,25 @@ paths:
25602588 ]
25612589 }
25622590 EOF
2591+ - lang : Shell
2592+ label : Dispose a single remediation for 2 hosts (filter_match_mod
2593+ source : |-
2594+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/remediations" \
2595+ -X PUT -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
2596+ {
2597+ "operation": "dispose_remediations",
2598+ "comment": "Vulnerable database contains automated test data, not customer records.",
2599+ "filter_match_mode": "any",
2600+ "filters": [
2601+ "host:/aws/us-west-2/host/i-1e272a96c803bf6e1",
2602+ "host:/aws/us-west-2/host/i-03bf219df1d75f14a"
2603+ ],
2604+ "reason": "acceptable_risk",
2605+ "remediation_ids": [
2606+ "45af6dc636774a4d822b9eff57b99ae8"
2607+ ]
2608+ }
2609+ EOF
25632610 - lang : Shell
25642611 label : Conclude a single remediation (all deployments)
25652612 source : |-
@@ -2636,6 +2683,71 @@ paths:
26362683 ]
26372684 }
26382685 EOF
2686+ - lang : Shell
2687+ label : Partially undispose a single remediation by remediation-item ID
2688+ source : |-
2689+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/remediations" \
2690+ -X PUT -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
2691+ {
2692+ "operation": "undispose_remediations",
2693+ "filters": [
2694+ "host:host_key_1"
2695+ ],
2696+ "remediation_item_ids": [
2697+ "0536575B914C32C8A5D28415D02E4545"
2698+ ]
2699+ }
2700+ EOF
2701+ - lang : Shell
2702+ label : Undispose a single remediation by remediation-item ID (request and existing filters match)
2703+ source : |-
2704+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/remediations" \
2705+ -X PUT -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
2706+ {
2707+ "operation": "undispose_remediations",
2708+ "filters": [
2709+ "host:host_key_1",
2710+ "host:host_key_2",
2711+ "host:host_key_3"
2712+ ],
2713+ "remediation_item_ids": [
2714+ "0536575B914C32C8A5D28415D02E4545"
2715+ ]
2716+ }
2717+ EOF
2718+ - lang : Shell
2719+ label : Partially undispose a remediation-item by audit_id/vulnerability_id
2720+ source : |-
2721+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/remediations" \
2722+ -X PUT -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
2723+ {
2724+ "operation": "undispose_remediations",
2725+ "filters": [
2726+ "host:host_key_1"
2727+ ],
2728+ "audit_ids": [
2729+ "37CA08E6-9CC7-4575-BA9B-B6F961976E8D"
2730+ ],
2731+ "vulnerability_ids": [
2732+ "b9890b5c62d542c4830b43b53dabcc15"
2733+ ]
2734+ }
2735+ EOF
2736+ - lang : Shell
2737+ label : Undispose a remediation-item by audit_id/vulnerability_id (no filters)
2738+ source : |-
2739+ curl "https://api.cloudinsight.alertlogic.com/assets_query/v2/12345678/remediations" \
2740+ -X PUT -H "x-aims-auth-token: $TOKEN" -H "accept: application/json" -d@- << EOF
2741+ {
2742+ "operation": "undispose_remediations",
2743+ "audit_ids": [
2744+ "37CA08E6-9CC7-4575-BA9B-B6F961976E8D"
2745+ ],
2746+ "vulnerability_ids": [
2747+ "b9890b5c62d542c4830b43b53dabcc15"
2748+ ]
2749+ }
2750+ EOF
26392751 security :
26402752 - x-aims-auth-token : []
26412753 delete :
0 commit comments