stopCisSession

Stops a CIS session. This API is used by the Amazon Inspector SSM plugin to communicate with the Amazon Inspector service. The Amazon Inspector SSM plugin calls this API to start a CIS scan session for the scan ID supplied by the service.

Samples


fun main() { 
   //sampleStart 
   // Sample StopCisSession Call
val resp = inspector2Client.stopCisSession {
    scanJobId = "624b746d-e080-44ae-8c1d-48e653365a38"
    sessionToken = "624b746d-e080-44ae-8c1d-48e653365a31"
    message = StopCisSessionMessage {
        status = StopCisSessionStatus.fromValue("FAILED")
        reason = "Failure Reason"
        progress = StopCisMessageProgress {
            informationalChecks = 1
            errorChecks = 1
            successfulChecks = 5
            notApplicableChecks = 0
            totalChecks = 10
            unknownChecks = 0
            notEvaluatedChecks = 2
            failedChecks = 0
        }
        computePlatform = ComputePlatform {
            vendor = "canonical"
            product = "ubuntu"
            version = "20.04"
        }
        benchmarkVersion = "2.0.0"
        benchmarkProfile = "xccdf_org.cisecurity.benchmarks_profile_Level_1"
    }
} 
   //sampleEnd
}