start_pentest_job
¶
start_pentest_job(
agent_space_id: str,
pentest_id: str,
*,
config_overrides: Optional[SecurityAgentClientConfig] = None,
job_type: Optional[JobType] = None,
selected_finding_ids: Optional[StringList] = None,
scope_changes: Optional[ScopeChangeList] = None,
) -> StartPentestJobOutput
Starts a new pentest job for a pentest configuration. The job executes the security tests defined in the pentest.
Parameters:
-
agent_space_id(str) –The unique identifier of the agent space.
-
pentest_id(str) –The unique identifier of the pentest to start a job for.
-
job_type(Optional[JobType], default:None) –The type of pentest job to start. Valid values are FULL, REVALIDATION, and CICD. When set to REVALIDATION, the selectedFindingIds parameter is required. When set to CICD, the scopeChanges parameter defines the code changes to test.
-
selected_finding_ids(Optional[StringList], default:None) –The list of finding identifiers to revalidate. Required when jobType is REVALIDATION. Each finding must belong to the same agent space and pentest.
-
scope_changes(Optional[ScopeChangeList], default:None) –The code changes that define the scope of a CI/CD pentest job. Provide this when starting a job with jobType CICD to test only the changes in the current pipeline run.
Raises:
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_securityagent/_services/security_agent.py
4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 | |