1use std::error::Error;
14use std::fmt;
15
16use async_trait::async_trait;
17use rusoto_core::credential::ProvideAwsCredentials;
18use rusoto_core::region;
19use rusoto_core::request::{BufferedHttpResponse, DispatchSignedRequest};
20use rusoto_core::{Client, RusotoError};
21
22use rusoto_core::param::{Params, ServiceParams};
23use rusoto_core::proto;
24use rusoto_core::signature::SignedRequest;
25#[allow(unused_imports)]
26use serde::{Deserialize, Serialize};
27use serde_json;
28#[derive(Clone, Debug, Default, PartialEq, Serialize)]
29#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
30pub struct AcceptInvitationRequest {
31 #[serde(rename = "InvitationId")]
33 pub invitation_id: String,
34 #[serde(rename = "MasterId")]
36 pub master_id: String,
37}
38
39#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
40#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
41pub struct AcceptInvitationResponse {}
42
43#[derive(Clone, Debug, Default, PartialEq, Serialize)]
45#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
46pub struct AccountDetails {
47 #[serde(rename = "AccountId")]
49 #[serde(skip_serializing_if = "Option::is_none")]
50 pub account_id: Option<String>,
51 #[serde(rename = "Email")]
53 #[serde(skip_serializing_if = "Option::is_none")]
54 pub email: Option<String>,
55}
56
57#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
59#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
60pub struct ActionTarget {
61 #[serde(rename = "ActionTargetArn")]
63 pub action_target_arn: String,
64 #[serde(rename = "Description")]
66 pub description: String,
67 #[serde(rename = "Name")]
69 pub name: String,
70}
71
72#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
74pub struct AvailabilityZone {
75 #[serde(rename = "SubnetId")]
77 #[serde(skip_serializing_if = "Option::is_none")]
78 pub subnet_id: Option<String>,
79 #[serde(rename = "ZoneName")]
81 #[serde(skip_serializing_if = "Option::is_none")]
82 pub zone_name: Option<String>,
83}
84
85#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
87pub struct AwsAutoScalingAutoScalingGroupDetails {
88 #[serde(rename = "CreatedTime")]
90 #[serde(skip_serializing_if = "Option::is_none")]
91 pub created_time: Option<String>,
92 #[serde(rename = "HealthCheckGracePeriod")]
94 #[serde(skip_serializing_if = "Option::is_none")]
95 pub health_check_grace_period: Option<i64>,
96 #[serde(rename = "HealthCheckType")]
98 #[serde(skip_serializing_if = "Option::is_none")]
99 pub health_check_type: Option<String>,
100 #[serde(rename = "LaunchConfigurationName")]
102 #[serde(skip_serializing_if = "Option::is_none")]
103 pub launch_configuration_name: Option<String>,
104 #[serde(rename = "LoadBalancerNames")]
106 #[serde(skip_serializing_if = "Option::is_none")]
107 pub load_balancer_names: Option<Vec<String>>,
108}
109
110#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
112pub struct AwsCloudFrontDistributionDetails {
113 #[serde(rename = "DomainName")]
115 #[serde(skip_serializing_if = "Option::is_none")]
116 pub domain_name: Option<String>,
117 #[serde(rename = "ETag")]
119 #[serde(skip_serializing_if = "Option::is_none")]
120 pub e_tag: Option<String>,
121 #[serde(rename = "LastModifiedTime")]
123 #[serde(skip_serializing_if = "Option::is_none")]
124 pub last_modified_time: Option<String>,
125 #[serde(rename = "Logging")]
127 #[serde(skip_serializing_if = "Option::is_none")]
128 pub logging: Option<AwsCloudFrontDistributionLogging>,
129 #[serde(rename = "Origins")]
131 #[serde(skip_serializing_if = "Option::is_none")]
132 pub origins: Option<AwsCloudFrontDistributionOrigins>,
133 #[serde(rename = "Status")]
135 #[serde(skip_serializing_if = "Option::is_none")]
136 pub status: Option<String>,
137 #[serde(rename = "WebAclId")]
139 #[serde(skip_serializing_if = "Option::is_none")]
140 pub web_acl_id: Option<String>,
141}
142
143#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
145pub struct AwsCloudFrontDistributionLogging {
146 #[serde(rename = "Bucket")]
148 #[serde(skip_serializing_if = "Option::is_none")]
149 pub bucket: Option<String>,
150 #[serde(rename = "Enabled")]
152 #[serde(skip_serializing_if = "Option::is_none")]
153 pub enabled: Option<bool>,
154 #[serde(rename = "IncludeCookies")]
156 #[serde(skip_serializing_if = "Option::is_none")]
157 pub include_cookies: Option<bool>,
158 #[serde(rename = "Prefix")]
160 #[serde(skip_serializing_if = "Option::is_none")]
161 pub prefix: Option<String>,
162}
163
164#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
166pub struct AwsCloudFrontDistributionOriginItem {
167 #[serde(rename = "DomainName")]
169 #[serde(skip_serializing_if = "Option::is_none")]
170 pub domain_name: Option<String>,
171 #[serde(rename = "Id")]
173 #[serde(skip_serializing_if = "Option::is_none")]
174 pub id: Option<String>,
175 #[serde(rename = "OriginPath")]
177 #[serde(skip_serializing_if = "Option::is_none")]
178 pub origin_path: Option<String>,
179}
180
181#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
183pub struct AwsCloudFrontDistributionOrigins {
184 #[serde(rename = "Items")]
186 #[serde(skip_serializing_if = "Option::is_none")]
187 pub items: Option<Vec<AwsCloudFrontDistributionOriginItem>>,
188}
189
190#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
192pub struct AwsCodeBuildProjectDetails {
193 #[serde(rename = "EncryptionKey")]
195 #[serde(skip_serializing_if = "Option::is_none")]
196 pub encryption_key: Option<String>,
197 #[serde(rename = "Environment")]
199 #[serde(skip_serializing_if = "Option::is_none")]
200 pub environment: Option<AwsCodeBuildProjectEnvironment>,
201 #[serde(rename = "Name")]
203 #[serde(skip_serializing_if = "Option::is_none")]
204 pub name: Option<String>,
205 #[serde(rename = "ServiceRole")]
207 #[serde(skip_serializing_if = "Option::is_none")]
208 pub service_role: Option<String>,
209 #[serde(rename = "Source")]
211 #[serde(skip_serializing_if = "Option::is_none")]
212 pub source: Option<AwsCodeBuildProjectSource>,
213 #[serde(rename = "VpcConfig")]
215 #[serde(skip_serializing_if = "Option::is_none")]
216 pub vpc_config: Option<AwsCodeBuildProjectVpcConfig>,
217}
218
219#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
221pub struct AwsCodeBuildProjectEnvironment {
222 #[serde(rename = "Certificate")]
224 #[serde(skip_serializing_if = "Option::is_none")]
225 pub certificate: Option<String>,
226 #[serde(rename = "ImagePullCredentialsType")]
228 #[serde(skip_serializing_if = "Option::is_none")]
229 pub image_pull_credentials_type: Option<String>,
230 #[serde(rename = "RegistryCredential")]
232 #[serde(skip_serializing_if = "Option::is_none")]
233 pub registry_credential: Option<AwsCodeBuildProjectEnvironmentRegistryCredential>,
234 #[serde(rename = "Type")]
236 #[serde(skip_serializing_if = "Option::is_none")]
237 pub type_: Option<String>,
238}
239
240#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
242pub struct AwsCodeBuildProjectEnvironmentRegistryCredential {
243 #[serde(rename = "Credential")]
245 #[serde(skip_serializing_if = "Option::is_none")]
246 pub credential: Option<String>,
247 #[serde(rename = "CredentialProvider")]
249 #[serde(skip_serializing_if = "Option::is_none")]
250 pub credential_provider: Option<String>,
251}
252
253#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
255pub struct AwsCodeBuildProjectSource {
256 #[serde(rename = "GitCloneDepth")]
258 #[serde(skip_serializing_if = "Option::is_none")]
259 pub git_clone_depth: Option<i64>,
260 #[serde(rename = "InsecureSsl")]
262 #[serde(skip_serializing_if = "Option::is_none")]
263 pub insecure_ssl: Option<bool>,
264 #[serde(rename = "Location")]
266 #[serde(skip_serializing_if = "Option::is_none")]
267 pub location: Option<String>,
268 #[serde(rename = "Type")]
270 #[serde(skip_serializing_if = "Option::is_none")]
271 pub type_: Option<String>,
272}
273
274#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
276pub struct AwsCodeBuildProjectVpcConfig {
277 #[serde(rename = "SecurityGroupIds")]
279 #[serde(skip_serializing_if = "Option::is_none")]
280 pub security_group_ids: Option<Vec<String>>,
281 #[serde(rename = "Subnets")]
283 #[serde(skip_serializing_if = "Option::is_none")]
284 pub subnets: Option<Vec<String>>,
285 #[serde(rename = "VpcId")]
287 #[serde(skip_serializing_if = "Option::is_none")]
288 pub vpc_id: Option<String>,
289}
290
291#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
293pub struct AwsEc2InstanceDetails {
294 #[serde(rename = "IamInstanceProfileArn")]
296 #[serde(skip_serializing_if = "Option::is_none")]
297 pub iam_instance_profile_arn: Option<String>,
298 #[serde(rename = "ImageId")]
300 #[serde(skip_serializing_if = "Option::is_none")]
301 pub image_id: Option<String>,
302 #[serde(rename = "IpV4Addresses")]
304 #[serde(skip_serializing_if = "Option::is_none")]
305 pub ip_v4_addresses: Option<Vec<String>>,
306 #[serde(rename = "IpV6Addresses")]
308 #[serde(skip_serializing_if = "Option::is_none")]
309 pub ip_v6_addresses: Option<Vec<String>>,
310 #[serde(rename = "KeyName")]
312 #[serde(skip_serializing_if = "Option::is_none")]
313 pub key_name: Option<String>,
314 #[serde(rename = "LaunchedAt")]
316 #[serde(skip_serializing_if = "Option::is_none")]
317 pub launched_at: Option<String>,
318 #[serde(rename = "SubnetId")]
320 #[serde(skip_serializing_if = "Option::is_none")]
321 pub subnet_id: Option<String>,
322 #[serde(rename = "Type")]
324 #[serde(skip_serializing_if = "Option::is_none")]
325 pub type_: Option<String>,
326 #[serde(rename = "VpcId")]
328 #[serde(skip_serializing_if = "Option::is_none")]
329 pub vpc_id: Option<String>,
330}
331
332#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
334pub struct AwsEc2NetworkInterfaceAttachment {
335 #[serde(rename = "AttachTime")]
337 #[serde(skip_serializing_if = "Option::is_none")]
338 pub attach_time: Option<String>,
339 #[serde(rename = "AttachmentId")]
341 #[serde(skip_serializing_if = "Option::is_none")]
342 pub attachment_id: Option<String>,
343 #[serde(rename = "DeleteOnTermination")]
345 #[serde(skip_serializing_if = "Option::is_none")]
346 pub delete_on_termination: Option<bool>,
347 #[serde(rename = "DeviceIndex")]
349 #[serde(skip_serializing_if = "Option::is_none")]
350 pub device_index: Option<i64>,
351 #[serde(rename = "InstanceId")]
353 #[serde(skip_serializing_if = "Option::is_none")]
354 pub instance_id: Option<String>,
355 #[serde(rename = "InstanceOwnerId")]
357 #[serde(skip_serializing_if = "Option::is_none")]
358 pub instance_owner_id: Option<String>,
359 #[serde(rename = "Status")]
361 #[serde(skip_serializing_if = "Option::is_none")]
362 pub status: Option<String>,
363}
364
365#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
367pub struct AwsEc2NetworkInterfaceDetails {
368 #[serde(rename = "Attachment")]
370 #[serde(skip_serializing_if = "Option::is_none")]
371 pub attachment: Option<AwsEc2NetworkInterfaceAttachment>,
372 #[serde(rename = "NetworkInterfaceId")]
374 #[serde(skip_serializing_if = "Option::is_none")]
375 pub network_interface_id: Option<String>,
376 #[serde(rename = "SecurityGroups")]
378 #[serde(skip_serializing_if = "Option::is_none")]
379 pub security_groups: Option<Vec<AwsEc2NetworkInterfaceSecurityGroup>>,
380 #[serde(rename = "SourceDestCheck")]
382 #[serde(skip_serializing_if = "Option::is_none")]
383 pub source_dest_check: Option<bool>,
384}
385
386#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
388pub struct AwsEc2NetworkInterfaceSecurityGroup {
389 #[serde(rename = "GroupId")]
391 #[serde(skip_serializing_if = "Option::is_none")]
392 pub group_id: Option<String>,
393 #[serde(rename = "GroupName")]
395 #[serde(skip_serializing_if = "Option::is_none")]
396 pub group_name: Option<String>,
397}
398
399#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
401pub struct AwsEc2SecurityGroupDetails {
402 #[serde(rename = "GroupId")]
404 #[serde(skip_serializing_if = "Option::is_none")]
405 pub group_id: Option<String>,
406 #[serde(rename = "GroupName")]
408 #[serde(skip_serializing_if = "Option::is_none")]
409 pub group_name: Option<String>,
410 #[serde(rename = "IpPermissions")]
412 #[serde(skip_serializing_if = "Option::is_none")]
413 pub ip_permissions: Option<Vec<AwsEc2SecurityGroupIpPermission>>,
414 #[serde(rename = "IpPermissionsEgress")]
416 #[serde(skip_serializing_if = "Option::is_none")]
417 pub ip_permissions_egress: Option<Vec<AwsEc2SecurityGroupIpPermission>>,
418 #[serde(rename = "OwnerId")]
420 #[serde(skip_serializing_if = "Option::is_none")]
421 pub owner_id: Option<String>,
422 #[serde(rename = "VpcId")]
424 #[serde(skip_serializing_if = "Option::is_none")]
425 pub vpc_id: Option<String>,
426}
427
428#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
430pub struct AwsEc2SecurityGroupIpPermission {
431 #[serde(rename = "FromPort")]
433 #[serde(skip_serializing_if = "Option::is_none")]
434 pub from_port: Option<i64>,
435 #[serde(rename = "IpProtocol")]
437 #[serde(skip_serializing_if = "Option::is_none")]
438 pub ip_protocol: Option<String>,
439 #[serde(rename = "IpRanges")]
441 #[serde(skip_serializing_if = "Option::is_none")]
442 pub ip_ranges: Option<Vec<AwsEc2SecurityGroupIpRange>>,
443 #[serde(rename = "Ipv6Ranges")]
445 #[serde(skip_serializing_if = "Option::is_none")]
446 pub ipv_6_ranges: Option<Vec<AwsEc2SecurityGroupIpv6Range>>,
447 #[serde(rename = "PrefixListIds")]
449 #[serde(skip_serializing_if = "Option::is_none")]
450 pub prefix_list_ids: Option<Vec<AwsEc2SecurityGroupPrefixListId>>,
451 #[serde(rename = "ToPort")]
453 #[serde(skip_serializing_if = "Option::is_none")]
454 pub to_port: Option<i64>,
455 #[serde(rename = "UserIdGroupPairs")]
457 #[serde(skip_serializing_if = "Option::is_none")]
458 pub user_id_group_pairs: Option<Vec<AwsEc2SecurityGroupUserIdGroupPair>>,
459}
460
461#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
463pub struct AwsEc2SecurityGroupIpRange {
464 #[serde(rename = "CidrIp")]
466 #[serde(skip_serializing_if = "Option::is_none")]
467 pub cidr_ip: Option<String>,
468}
469
470#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
472pub struct AwsEc2SecurityGroupIpv6Range {
473 #[serde(rename = "CidrIpv6")]
475 #[serde(skip_serializing_if = "Option::is_none")]
476 pub cidr_ipv_6: Option<String>,
477}
478
479#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
481pub struct AwsEc2SecurityGroupPrefixListId {
482 #[serde(rename = "PrefixListId")]
484 #[serde(skip_serializing_if = "Option::is_none")]
485 pub prefix_list_id: Option<String>,
486}
487
488#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
490pub struct AwsEc2SecurityGroupUserIdGroupPair {
491 #[serde(rename = "GroupId")]
493 #[serde(skip_serializing_if = "Option::is_none")]
494 pub group_id: Option<String>,
495 #[serde(rename = "GroupName")]
497 #[serde(skip_serializing_if = "Option::is_none")]
498 pub group_name: Option<String>,
499 #[serde(rename = "PeeringStatus")]
501 #[serde(skip_serializing_if = "Option::is_none")]
502 pub peering_status: Option<String>,
503 #[serde(rename = "UserId")]
505 #[serde(skip_serializing_if = "Option::is_none")]
506 pub user_id: Option<String>,
507 #[serde(rename = "VpcId")]
509 #[serde(skip_serializing_if = "Option::is_none")]
510 pub vpc_id: Option<String>,
511 #[serde(rename = "VpcPeeringConnectionId")]
513 #[serde(skip_serializing_if = "Option::is_none")]
514 pub vpc_peering_connection_id: Option<String>,
515}
516
517#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
519pub struct AwsEc2VolumeAttachment {
520 #[serde(rename = "AttachTime")]
522 #[serde(skip_serializing_if = "Option::is_none")]
523 pub attach_time: Option<String>,
524 #[serde(rename = "DeleteOnTermination")]
526 #[serde(skip_serializing_if = "Option::is_none")]
527 pub delete_on_termination: Option<bool>,
528 #[serde(rename = "InstanceId")]
530 #[serde(skip_serializing_if = "Option::is_none")]
531 pub instance_id: Option<String>,
532 #[serde(rename = "Status")]
534 #[serde(skip_serializing_if = "Option::is_none")]
535 pub status: Option<String>,
536}
537
538#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
540pub struct AwsEc2VolumeDetails {
541 #[serde(rename = "Attachments")]
543 #[serde(skip_serializing_if = "Option::is_none")]
544 pub attachments: Option<Vec<AwsEc2VolumeAttachment>>,
545 #[serde(rename = "CreateTime")]
547 #[serde(skip_serializing_if = "Option::is_none")]
548 pub create_time: Option<String>,
549 #[serde(rename = "Encrypted")]
551 #[serde(skip_serializing_if = "Option::is_none")]
552 pub encrypted: Option<bool>,
553 #[serde(rename = "KmsKeyId")]
555 #[serde(skip_serializing_if = "Option::is_none")]
556 pub kms_key_id: Option<String>,
557 #[serde(rename = "Size")]
559 #[serde(skip_serializing_if = "Option::is_none")]
560 pub size: Option<i64>,
561 #[serde(rename = "SnapshotId")]
563 #[serde(skip_serializing_if = "Option::is_none")]
564 pub snapshot_id: Option<String>,
565 #[serde(rename = "Status")]
567 #[serde(skip_serializing_if = "Option::is_none")]
568 pub status: Option<String>,
569}
570
571#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
573pub struct AwsEc2VpcDetails {
574 #[serde(rename = "CidrBlockAssociationSet")]
576 #[serde(skip_serializing_if = "Option::is_none")]
577 pub cidr_block_association_set: Option<Vec<CidrBlockAssociation>>,
578 #[serde(rename = "DhcpOptionsId")]
580 #[serde(skip_serializing_if = "Option::is_none")]
581 pub dhcp_options_id: Option<String>,
582 #[serde(rename = "Ipv6CidrBlockAssociationSet")]
584 #[serde(skip_serializing_if = "Option::is_none")]
585 pub ipv_6_cidr_block_association_set: Option<Vec<Ipv6CidrBlockAssociation>>,
586 #[serde(rename = "State")]
588 #[serde(skip_serializing_if = "Option::is_none")]
589 pub state: Option<String>,
590}
591
592#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
594pub struct AwsElasticsearchDomainDetails {
595 #[serde(rename = "AccessPolicies")]
597 #[serde(skip_serializing_if = "Option::is_none")]
598 pub access_policies: Option<String>,
599 #[serde(rename = "DomainEndpointOptions")]
601 #[serde(skip_serializing_if = "Option::is_none")]
602 pub domain_endpoint_options: Option<AwsElasticsearchDomainDomainEndpointOptions>,
603 #[serde(rename = "DomainId")]
605 #[serde(skip_serializing_if = "Option::is_none")]
606 pub domain_id: Option<String>,
607 #[serde(rename = "DomainName")]
609 #[serde(skip_serializing_if = "Option::is_none")]
610 pub domain_name: Option<String>,
611 #[serde(rename = "ElasticsearchVersion")]
613 #[serde(skip_serializing_if = "Option::is_none")]
614 pub elasticsearch_version: Option<String>,
615 #[serde(rename = "EncryptionAtRestOptions")]
617 #[serde(skip_serializing_if = "Option::is_none")]
618 pub encryption_at_rest_options: Option<AwsElasticsearchDomainEncryptionAtRestOptions>,
619 #[serde(rename = "Endpoint")]
621 #[serde(skip_serializing_if = "Option::is_none")]
622 pub endpoint: Option<String>,
623 #[serde(rename = "Endpoints")]
625 #[serde(skip_serializing_if = "Option::is_none")]
626 pub endpoints: Option<::std::collections::HashMap<String, String>>,
627 #[serde(rename = "NodeToNodeEncryptionOptions")]
629 #[serde(skip_serializing_if = "Option::is_none")]
630 pub node_to_node_encryption_options: Option<AwsElasticsearchDomainNodeToNodeEncryptionOptions>,
631 #[serde(rename = "VPCOptions")]
633 #[serde(skip_serializing_if = "Option::is_none")]
634 pub vpc_options: Option<AwsElasticsearchDomainVPCOptions>,
635}
636
637#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
639pub struct AwsElasticsearchDomainDomainEndpointOptions {
640 #[serde(rename = "EnforceHTTPS")]
642 #[serde(skip_serializing_if = "Option::is_none")]
643 pub enforce_https: Option<bool>,
644 #[serde(rename = "TLSSecurityPolicy")]
646 #[serde(skip_serializing_if = "Option::is_none")]
647 pub tls_security_policy: Option<String>,
648}
649
650#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
652pub struct AwsElasticsearchDomainEncryptionAtRestOptions {
653 #[serde(rename = "Enabled")]
655 #[serde(skip_serializing_if = "Option::is_none")]
656 pub enabled: Option<bool>,
657 #[serde(rename = "KmsKeyId")]
659 #[serde(skip_serializing_if = "Option::is_none")]
660 pub kms_key_id: Option<String>,
661}
662
663#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
665pub struct AwsElasticsearchDomainNodeToNodeEncryptionOptions {
666 #[serde(rename = "Enabled")]
668 #[serde(skip_serializing_if = "Option::is_none")]
669 pub enabled: Option<bool>,
670}
671
672#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
674pub struct AwsElasticsearchDomainVPCOptions {
675 #[serde(rename = "AvailabilityZones")]
677 #[serde(skip_serializing_if = "Option::is_none")]
678 pub availability_zones: Option<Vec<String>>,
679 #[serde(rename = "SecurityGroupIds")]
681 #[serde(skip_serializing_if = "Option::is_none")]
682 pub security_group_ids: Option<Vec<String>>,
683 #[serde(rename = "SubnetIds")]
685 #[serde(skip_serializing_if = "Option::is_none")]
686 pub subnet_ids: Option<Vec<String>>,
687 #[serde(rename = "VPCId")]
689 #[serde(skip_serializing_if = "Option::is_none")]
690 pub vpc_id: Option<String>,
691}
692
693#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
695pub struct AwsElbv2LoadBalancerDetails {
696 #[serde(rename = "AvailabilityZones")]
698 #[serde(skip_serializing_if = "Option::is_none")]
699 pub availability_zones: Option<Vec<AvailabilityZone>>,
700 #[serde(rename = "CanonicalHostedZoneId")]
702 #[serde(skip_serializing_if = "Option::is_none")]
703 pub canonical_hosted_zone_id: Option<String>,
704 #[serde(rename = "CreatedTime")]
706 #[serde(skip_serializing_if = "Option::is_none")]
707 pub created_time: Option<String>,
708 #[serde(rename = "DNSName")]
710 #[serde(skip_serializing_if = "Option::is_none")]
711 pub dns_name: Option<String>,
712 #[serde(rename = "IpAddressType")]
714 #[serde(skip_serializing_if = "Option::is_none")]
715 pub ip_address_type: Option<String>,
716 #[serde(rename = "Scheme")]
718 #[serde(skip_serializing_if = "Option::is_none")]
719 pub scheme: Option<String>,
720 #[serde(rename = "SecurityGroups")]
722 #[serde(skip_serializing_if = "Option::is_none")]
723 pub security_groups: Option<Vec<String>>,
724 #[serde(rename = "State")]
726 #[serde(skip_serializing_if = "Option::is_none")]
727 pub state: Option<LoadBalancerState>,
728 #[serde(rename = "Type")]
730 #[serde(skip_serializing_if = "Option::is_none")]
731 pub type_: Option<String>,
732 #[serde(rename = "VpcId")]
734 #[serde(skip_serializing_if = "Option::is_none")]
735 pub vpc_id: Option<String>,
736}
737
738#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
740pub struct AwsIamAccessKeyDetails {
741 #[serde(rename = "CreatedAt")]
743 #[serde(skip_serializing_if = "Option::is_none")]
744 pub created_at: Option<String>,
745 #[serde(rename = "PrincipalId")]
747 #[serde(skip_serializing_if = "Option::is_none")]
748 pub principal_id: Option<String>,
749 #[serde(rename = "PrincipalName")]
751 #[serde(skip_serializing_if = "Option::is_none")]
752 pub principal_name: Option<String>,
753 #[serde(rename = "PrincipalType")]
755 #[serde(skip_serializing_if = "Option::is_none")]
756 pub principal_type: Option<String>,
757 #[serde(rename = "Status")]
759 #[serde(skip_serializing_if = "Option::is_none")]
760 pub status: Option<String>,
761}
762
763#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
765pub struct AwsIamRoleDetails {
766 #[serde(rename = "AssumeRolePolicyDocument")]
768 #[serde(skip_serializing_if = "Option::is_none")]
769 pub assume_role_policy_document: Option<String>,
770 #[serde(rename = "CreateDate")]
772 #[serde(skip_serializing_if = "Option::is_none")]
773 pub create_date: Option<String>,
774 #[serde(rename = "MaxSessionDuration")]
776 #[serde(skip_serializing_if = "Option::is_none")]
777 pub max_session_duration: Option<i64>,
778 #[serde(rename = "Path")]
780 #[serde(skip_serializing_if = "Option::is_none")]
781 pub path: Option<String>,
782 #[serde(rename = "RoleId")]
784 #[serde(skip_serializing_if = "Option::is_none")]
785 pub role_id: Option<String>,
786 #[serde(rename = "RoleName")]
788 #[serde(skip_serializing_if = "Option::is_none")]
789 pub role_name: Option<String>,
790}
791
792#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
794pub struct AwsKmsKeyDetails {
795 #[serde(rename = "AWSAccountId")]
797 #[serde(skip_serializing_if = "Option::is_none")]
798 pub aws_account_id: Option<String>,
799 #[serde(rename = "CreationDate")]
801 #[serde(skip_serializing_if = "Option::is_none")]
802 pub creation_date: Option<f64>,
803 #[serde(rename = "KeyId")]
805 #[serde(skip_serializing_if = "Option::is_none")]
806 pub key_id: Option<String>,
807 #[serde(rename = "KeyManager")]
809 #[serde(skip_serializing_if = "Option::is_none")]
810 pub key_manager: Option<String>,
811 #[serde(rename = "KeyState")]
813 #[serde(skip_serializing_if = "Option::is_none")]
814 pub key_state: Option<String>,
815 #[serde(rename = "Origin")]
817 #[serde(skip_serializing_if = "Option::is_none")]
818 pub origin: Option<String>,
819}
820
821#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
823pub struct AwsLambdaFunctionCode {
824 #[serde(rename = "S3Bucket")]
826 #[serde(skip_serializing_if = "Option::is_none")]
827 pub s3_bucket: Option<String>,
828 #[serde(rename = "S3Key")]
830 #[serde(skip_serializing_if = "Option::is_none")]
831 pub s3_key: Option<String>,
832 #[serde(rename = "S3ObjectVersion")]
834 #[serde(skip_serializing_if = "Option::is_none")]
835 pub s3_object_version: Option<String>,
836 #[serde(rename = "ZipFile")]
838 #[serde(skip_serializing_if = "Option::is_none")]
839 pub zip_file: Option<String>,
840}
841
842#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
844pub struct AwsLambdaFunctionDeadLetterConfig {
845 #[serde(rename = "TargetArn")]
847 #[serde(skip_serializing_if = "Option::is_none")]
848 pub target_arn: Option<String>,
849}
850
851#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
853pub struct AwsLambdaFunctionDetails {
854 #[serde(rename = "Code")]
856 #[serde(skip_serializing_if = "Option::is_none")]
857 pub code: Option<AwsLambdaFunctionCode>,
858 #[serde(rename = "CodeSha256")]
860 #[serde(skip_serializing_if = "Option::is_none")]
861 pub code_sha_256: Option<String>,
862 #[serde(rename = "DeadLetterConfig")]
864 #[serde(skip_serializing_if = "Option::is_none")]
865 pub dead_letter_config: Option<AwsLambdaFunctionDeadLetterConfig>,
866 #[serde(rename = "Environment")]
868 #[serde(skip_serializing_if = "Option::is_none")]
869 pub environment: Option<AwsLambdaFunctionEnvironment>,
870 #[serde(rename = "FunctionName")]
872 #[serde(skip_serializing_if = "Option::is_none")]
873 pub function_name: Option<String>,
874 #[serde(rename = "Handler")]
876 #[serde(skip_serializing_if = "Option::is_none")]
877 pub handler: Option<String>,
878 #[serde(rename = "KmsKeyArn")]
880 #[serde(skip_serializing_if = "Option::is_none")]
881 pub kms_key_arn: Option<String>,
882 #[serde(rename = "LastModified")]
884 #[serde(skip_serializing_if = "Option::is_none")]
885 pub last_modified: Option<String>,
886 #[serde(rename = "Layers")]
888 #[serde(skip_serializing_if = "Option::is_none")]
889 pub layers: Option<Vec<AwsLambdaFunctionLayer>>,
890 #[serde(rename = "MasterArn")]
892 #[serde(skip_serializing_if = "Option::is_none")]
893 pub master_arn: Option<String>,
894 #[serde(rename = "MemorySize")]
896 #[serde(skip_serializing_if = "Option::is_none")]
897 pub memory_size: Option<i64>,
898 #[serde(rename = "RevisionId")]
900 #[serde(skip_serializing_if = "Option::is_none")]
901 pub revision_id: Option<String>,
902 #[serde(rename = "Role")]
904 #[serde(skip_serializing_if = "Option::is_none")]
905 pub role: Option<String>,
906 #[serde(rename = "Runtime")]
908 #[serde(skip_serializing_if = "Option::is_none")]
909 pub runtime: Option<String>,
910 #[serde(rename = "Timeout")]
912 #[serde(skip_serializing_if = "Option::is_none")]
913 pub timeout: Option<i64>,
914 #[serde(rename = "TracingConfig")]
916 #[serde(skip_serializing_if = "Option::is_none")]
917 pub tracing_config: Option<AwsLambdaFunctionTracingConfig>,
918 #[serde(rename = "Version")]
920 #[serde(skip_serializing_if = "Option::is_none")]
921 pub version: Option<String>,
922 #[serde(rename = "VpcConfig")]
924 #[serde(skip_serializing_if = "Option::is_none")]
925 pub vpc_config: Option<AwsLambdaFunctionVpcConfig>,
926}
927
928#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
930pub struct AwsLambdaFunctionEnvironment {
931 #[serde(rename = "Error")]
933 #[serde(skip_serializing_if = "Option::is_none")]
934 pub error: Option<AwsLambdaFunctionEnvironmentError>,
935 #[serde(rename = "Variables")]
937 #[serde(skip_serializing_if = "Option::is_none")]
938 pub variables: Option<::std::collections::HashMap<String, String>>,
939}
940
941#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
943pub struct AwsLambdaFunctionEnvironmentError {
944 #[serde(rename = "ErrorCode")]
946 #[serde(skip_serializing_if = "Option::is_none")]
947 pub error_code: Option<String>,
948 #[serde(rename = "Message")]
950 #[serde(skip_serializing_if = "Option::is_none")]
951 pub message: Option<String>,
952}
953
954#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
956pub struct AwsLambdaFunctionLayer {
957 #[serde(rename = "Arn")]
959 #[serde(skip_serializing_if = "Option::is_none")]
960 pub arn: Option<String>,
961 #[serde(rename = "CodeSize")]
963 #[serde(skip_serializing_if = "Option::is_none")]
964 pub code_size: Option<i64>,
965}
966
967#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
969pub struct AwsLambdaFunctionTracingConfig {
970 #[serde(rename = "Mode")]
972 #[serde(skip_serializing_if = "Option::is_none")]
973 pub mode: Option<String>,
974}
975
976#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
978pub struct AwsLambdaFunctionVpcConfig {
979 #[serde(rename = "SecurityGroupIds")]
981 #[serde(skip_serializing_if = "Option::is_none")]
982 pub security_group_ids: Option<Vec<String>>,
983 #[serde(rename = "SubnetIds")]
985 #[serde(skip_serializing_if = "Option::is_none")]
986 pub subnet_ids: Option<Vec<String>>,
987 #[serde(rename = "VpcId")]
989 #[serde(skip_serializing_if = "Option::is_none")]
990 pub vpc_id: Option<String>,
991}
992
993#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
995pub struct AwsLambdaLayerVersionDetails {
996 #[serde(rename = "CompatibleRuntimes")]
998 #[serde(skip_serializing_if = "Option::is_none")]
999 pub compatible_runtimes: Option<Vec<String>>,
1000 #[serde(rename = "CreatedDate")]
1002 #[serde(skip_serializing_if = "Option::is_none")]
1003 pub created_date: Option<String>,
1004 #[serde(rename = "Version")]
1006 #[serde(skip_serializing_if = "Option::is_none")]
1007 pub version: Option<i64>,
1008}
1009
1010#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1012pub struct AwsRdsDbInstanceAssociatedRole {
1013 #[serde(rename = "FeatureName")]
1015 #[serde(skip_serializing_if = "Option::is_none")]
1016 pub feature_name: Option<String>,
1017 #[serde(rename = "RoleArn")]
1019 #[serde(skip_serializing_if = "Option::is_none")]
1020 pub role_arn: Option<String>,
1021 #[serde(rename = "Status")]
1023 #[serde(skip_serializing_if = "Option::is_none")]
1024 pub status: Option<String>,
1025}
1026
1027#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1029pub struct AwsRdsDbInstanceDetails {
1030 #[serde(rename = "AssociatedRoles")]
1032 #[serde(skip_serializing_if = "Option::is_none")]
1033 pub associated_roles: Option<Vec<AwsRdsDbInstanceAssociatedRole>>,
1034 #[serde(rename = "CACertificateIdentifier")]
1036 #[serde(skip_serializing_if = "Option::is_none")]
1037 pub ca_certificate_identifier: Option<String>,
1038 #[serde(rename = "DBClusterIdentifier")]
1040 #[serde(skip_serializing_if = "Option::is_none")]
1041 pub db_cluster_identifier: Option<String>,
1042 #[serde(rename = "DBInstanceClass")]
1044 #[serde(skip_serializing_if = "Option::is_none")]
1045 pub db_instance_class: Option<String>,
1046 #[serde(rename = "DBInstanceIdentifier")]
1048 #[serde(skip_serializing_if = "Option::is_none")]
1049 pub db_instance_identifier: Option<String>,
1050 #[serde(rename = "DBName")]
1052 #[serde(skip_serializing_if = "Option::is_none")]
1053 pub db_name: Option<String>,
1054 #[serde(rename = "DbInstancePort")]
1056 #[serde(skip_serializing_if = "Option::is_none")]
1057 pub db_instance_port: Option<i64>,
1058 #[serde(rename = "DbiResourceId")]
1060 #[serde(skip_serializing_if = "Option::is_none")]
1061 pub dbi_resource_id: Option<String>,
1062 #[serde(rename = "DeletionProtection")]
1064 #[serde(skip_serializing_if = "Option::is_none")]
1065 pub deletion_protection: Option<bool>,
1066 #[serde(rename = "Endpoint")]
1068 #[serde(skip_serializing_if = "Option::is_none")]
1069 pub endpoint: Option<AwsRdsDbInstanceEndpoint>,
1070 #[serde(rename = "Engine")]
1072 #[serde(skip_serializing_if = "Option::is_none")]
1073 pub engine: Option<String>,
1074 #[serde(rename = "EngineVersion")]
1076 #[serde(skip_serializing_if = "Option::is_none")]
1077 pub engine_version: Option<String>,
1078 #[serde(rename = "IAMDatabaseAuthenticationEnabled")]
1080 #[serde(skip_serializing_if = "Option::is_none")]
1081 pub iam_database_authentication_enabled: Option<bool>,
1082 #[serde(rename = "InstanceCreateTime")]
1084 #[serde(skip_serializing_if = "Option::is_none")]
1085 pub instance_create_time: Option<String>,
1086 #[serde(rename = "KmsKeyId")]
1088 #[serde(skip_serializing_if = "Option::is_none")]
1089 pub kms_key_id: Option<String>,
1090 #[serde(rename = "PubliclyAccessible")]
1092 #[serde(skip_serializing_if = "Option::is_none")]
1093 pub publicly_accessible: Option<bool>,
1094 #[serde(rename = "StorageEncrypted")]
1096 #[serde(skip_serializing_if = "Option::is_none")]
1097 pub storage_encrypted: Option<bool>,
1098 #[serde(rename = "TdeCredentialArn")]
1100 #[serde(skip_serializing_if = "Option::is_none")]
1101 pub tde_credential_arn: Option<String>,
1102 #[serde(rename = "VpcSecurityGroups")]
1104 #[serde(skip_serializing_if = "Option::is_none")]
1105 pub vpc_security_groups: Option<Vec<AwsRdsDbInstanceVpcSecurityGroup>>,
1106}
1107
1108#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1110pub struct AwsRdsDbInstanceEndpoint {
1111 #[serde(rename = "Address")]
1113 #[serde(skip_serializing_if = "Option::is_none")]
1114 pub address: Option<String>,
1115 #[serde(rename = "HostedZoneId")]
1117 #[serde(skip_serializing_if = "Option::is_none")]
1118 pub hosted_zone_id: Option<String>,
1119 #[serde(rename = "Port")]
1121 #[serde(skip_serializing_if = "Option::is_none")]
1122 pub port: Option<i64>,
1123}
1124
1125#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1127pub struct AwsRdsDbInstanceVpcSecurityGroup {
1128 #[serde(rename = "Status")]
1130 #[serde(skip_serializing_if = "Option::is_none")]
1131 pub status: Option<String>,
1132 #[serde(rename = "VpcSecurityGroupId")]
1134 #[serde(skip_serializing_if = "Option::is_none")]
1135 pub vpc_security_group_id: Option<String>,
1136}
1137
1138#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1140pub struct AwsS3BucketDetails {
1141 #[serde(rename = "CreatedAt")]
1143 #[serde(skip_serializing_if = "Option::is_none")]
1144 pub created_at: Option<String>,
1145 #[serde(rename = "OwnerId")]
1147 #[serde(skip_serializing_if = "Option::is_none")]
1148 pub owner_id: Option<String>,
1149 #[serde(rename = "OwnerName")]
1151 #[serde(skip_serializing_if = "Option::is_none")]
1152 pub owner_name: Option<String>,
1153 #[serde(rename = "ServerSideEncryptionConfiguration")]
1155 #[serde(skip_serializing_if = "Option::is_none")]
1156 pub server_side_encryption_configuration: Option<AwsS3BucketServerSideEncryptionConfiguration>,
1157}
1158
1159#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1161pub struct AwsS3BucketServerSideEncryptionByDefault {
1162 #[serde(rename = "KMSMasterKeyID")]
1164 #[serde(skip_serializing_if = "Option::is_none")]
1165 pub kms_master_key_id: Option<String>,
1166 #[serde(rename = "SSEAlgorithm")]
1168 #[serde(skip_serializing_if = "Option::is_none")]
1169 pub sse_algorithm: Option<String>,
1170}
1171
1172#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1174pub struct AwsS3BucketServerSideEncryptionConfiguration {
1175 #[serde(rename = "Rules")]
1177 #[serde(skip_serializing_if = "Option::is_none")]
1178 pub rules: Option<Vec<AwsS3BucketServerSideEncryptionRule>>,
1179}
1180
1181#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1183pub struct AwsS3BucketServerSideEncryptionRule {
1184 #[serde(rename = "ApplyServerSideEncryptionByDefault")]
1186 #[serde(skip_serializing_if = "Option::is_none")]
1187 pub apply_server_side_encryption_by_default: Option<AwsS3BucketServerSideEncryptionByDefault>,
1188}
1189
1190#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1192pub struct AwsS3ObjectDetails {
1193 #[serde(rename = "ContentType")]
1195 #[serde(skip_serializing_if = "Option::is_none")]
1196 pub content_type: Option<String>,
1197 #[serde(rename = "ETag")]
1199 #[serde(skip_serializing_if = "Option::is_none")]
1200 pub e_tag: Option<String>,
1201 #[serde(rename = "LastModified")]
1203 #[serde(skip_serializing_if = "Option::is_none")]
1204 pub last_modified: Option<String>,
1205 #[serde(rename = "SSEKMSKeyId")]
1207 #[serde(skip_serializing_if = "Option::is_none")]
1208 pub ssekms_key_id: Option<String>,
1209 #[serde(rename = "ServerSideEncryption")]
1211 #[serde(skip_serializing_if = "Option::is_none")]
1212 pub server_side_encryption: Option<String>,
1213 #[serde(rename = "VersionId")]
1215 #[serde(skip_serializing_if = "Option::is_none")]
1216 pub version_id: Option<String>,
1217}
1218
1219#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1221pub struct AwsSecurityFinding {
1222 #[serde(rename = "AwsAccountId")]
1224 pub aws_account_id: String,
1225 #[serde(rename = "Compliance")]
1227 #[serde(skip_serializing_if = "Option::is_none")]
1228 pub compliance: Option<Compliance>,
1229 #[serde(rename = "Confidence")]
1231 #[serde(skip_serializing_if = "Option::is_none")]
1232 pub confidence: Option<i64>,
1233 #[serde(rename = "CreatedAt")]
1235 pub created_at: String,
1236 #[serde(rename = "Criticality")]
1238 #[serde(skip_serializing_if = "Option::is_none")]
1239 pub criticality: Option<i64>,
1240 #[serde(rename = "Description")]
1242 pub description: String,
1243 #[serde(rename = "FirstObservedAt")]
1245 #[serde(skip_serializing_if = "Option::is_none")]
1246 pub first_observed_at: Option<String>,
1247 #[serde(rename = "GeneratorId")]
1249 pub generator_id: String,
1250 #[serde(rename = "Id")]
1252 pub id: String,
1253 #[serde(rename = "LastObservedAt")]
1255 #[serde(skip_serializing_if = "Option::is_none")]
1256 pub last_observed_at: Option<String>,
1257 #[serde(rename = "Malware")]
1259 #[serde(skip_serializing_if = "Option::is_none")]
1260 pub malware: Option<Vec<Malware>>,
1261 #[serde(rename = "Network")]
1263 #[serde(skip_serializing_if = "Option::is_none")]
1264 pub network: Option<Network>,
1265 #[serde(rename = "NetworkPath")]
1267 #[serde(skip_serializing_if = "Option::is_none")]
1268 pub network_path: Option<Vec<NetworkPathComponent>>,
1269 #[serde(rename = "Note")]
1271 #[serde(skip_serializing_if = "Option::is_none")]
1272 pub note: Option<Note>,
1273 #[serde(rename = "Process")]
1275 #[serde(skip_serializing_if = "Option::is_none")]
1276 pub process: Option<ProcessDetails>,
1277 #[serde(rename = "ProductArn")]
1279 pub product_arn: String,
1280 #[serde(rename = "ProductFields")]
1282 #[serde(skip_serializing_if = "Option::is_none")]
1283 pub product_fields: Option<::std::collections::HashMap<String, String>>,
1284 #[serde(rename = "RecordState")]
1286 #[serde(skip_serializing_if = "Option::is_none")]
1287 pub record_state: Option<String>,
1288 #[serde(rename = "RelatedFindings")]
1290 #[serde(skip_serializing_if = "Option::is_none")]
1291 pub related_findings: Option<Vec<RelatedFinding>>,
1292 #[serde(rename = "Remediation")]
1294 #[serde(skip_serializing_if = "Option::is_none")]
1295 pub remediation: Option<Remediation>,
1296 #[serde(rename = "Resources")]
1298 pub resources: Vec<Resource>,
1299 #[serde(rename = "SchemaVersion")]
1301 pub schema_version: String,
1302 #[serde(rename = "Severity")]
1304 pub severity: Severity,
1305 #[serde(rename = "SourceUrl")]
1307 #[serde(skip_serializing_if = "Option::is_none")]
1308 pub source_url: Option<String>,
1309 #[serde(rename = "ThreatIntelIndicators")]
1311 #[serde(skip_serializing_if = "Option::is_none")]
1312 pub threat_intel_indicators: Option<Vec<ThreatIntelIndicator>>,
1313 #[serde(rename = "Title")]
1315 pub title: String,
1316 #[serde(rename = "Types")]
1318 pub types: Vec<String>,
1319 #[serde(rename = "UpdatedAt")]
1321 pub updated_at: String,
1322 #[serde(rename = "UserDefinedFields")]
1324 #[serde(skip_serializing_if = "Option::is_none")]
1325 pub user_defined_fields: Option<::std::collections::HashMap<String, String>>,
1326 #[serde(rename = "VerificationState")]
1328 #[serde(skip_serializing_if = "Option::is_none")]
1329 pub verification_state: Option<String>,
1330 #[serde(rename = "Vulnerabilities")]
1332 #[serde(skip_serializing_if = "Option::is_none")]
1333 pub vulnerabilities: Option<Vec<Vulnerability>>,
1334 #[serde(rename = "Workflow")]
1336 #[serde(skip_serializing_if = "Option::is_none")]
1337 pub workflow: Option<Workflow>,
1338 #[serde(rename = "WorkflowState")]
1340 #[serde(skip_serializing_if = "Option::is_none")]
1341 pub workflow_state: Option<String>,
1342}
1343
1344#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1346pub struct AwsSecurityFindingFilters {
1347 #[serde(rename = "AwsAccountId")]
1349 #[serde(skip_serializing_if = "Option::is_none")]
1350 pub aws_account_id: Option<Vec<StringFilter>>,
1351 #[serde(rename = "CompanyName")]
1353 #[serde(skip_serializing_if = "Option::is_none")]
1354 pub company_name: Option<Vec<StringFilter>>,
1355 #[serde(rename = "ComplianceStatus")]
1357 #[serde(skip_serializing_if = "Option::is_none")]
1358 pub compliance_status: Option<Vec<StringFilter>>,
1359 #[serde(rename = "Confidence")]
1361 #[serde(skip_serializing_if = "Option::is_none")]
1362 pub confidence: Option<Vec<NumberFilter>>,
1363 #[serde(rename = "CreatedAt")]
1365 #[serde(skip_serializing_if = "Option::is_none")]
1366 pub created_at: Option<Vec<DateFilter>>,
1367 #[serde(rename = "Criticality")]
1369 #[serde(skip_serializing_if = "Option::is_none")]
1370 pub criticality: Option<Vec<NumberFilter>>,
1371 #[serde(rename = "Description")]
1373 #[serde(skip_serializing_if = "Option::is_none")]
1374 pub description: Option<Vec<StringFilter>>,
1375 #[serde(rename = "FirstObservedAt")]
1377 #[serde(skip_serializing_if = "Option::is_none")]
1378 pub first_observed_at: Option<Vec<DateFilter>>,
1379 #[serde(rename = "GeneratorId")]
1381 #[serde(skip_serializing_if = "Option::is_none")]
1382 pub generator_id: Option<Vec<StringFilter>>,
1383 #[serde(rename = "Id")]
1385 #[serde(skip_serializing_if = "Option::is_none")]
1386 pub id: Option<Vec<StringFilter>>,
1387 #[serde(rename = "Keyword")]
1389 #[serde(skip_serializing_if = "Option::is_none")]
1390 pub keyword: Option<Vec<KeywordFilter>>,
1391 #[serde(rename = "LastObservedAt")]
1393 #[serde(skip_serializing_if = "Option::is_none")]
1394 pub last_observed_at: Option<Vec<DateFilter>>,
1395 #[serde(rename = "MalwareName")]
1397 #[serde(skip_serializing_if = "Option::is_none")]
1398 pub malware_name: Option<Vec<StringFilter>>,
1399 #[serde(rename = "MalwarePath")]
1401 #[serde(skip_serializing_if = "Option::is_none")]
1402 pub malware_path: Option<Vec<StringFilter>>,
1403 #[serde(rename = "MalwareState")]
1405 #[serde(skip_serializing_if = "Option::is_none")]
1406 pub malware_state: Option<Vec<StringFilter>>,
1407 #[serde(rename = "MalwareType")]
1409 #[serde(skip_serializing_if = "Option::is_none")]
1410 pub malware_type: Option<Vec<StringFilter>>,
1411 #[serde(rename = "NetworkDestinationDomain")]
1413 #[serde(skip_serializing_if = "Option::is_none")]
1414 pub network_destination_domain: Option<Vec<StringFilter>>,
1415 #[serde(rename = "NetworkDestinationIpV4")]
1417 #[serde(skip_serializing_if = "Option::is_none")]
1418 pub network_destination_ip_v4: Option<Vec<IpFilter>>,
1419 #[serde(rename = "NetworkDestinationIpV6")]
1421 #[serde(skip_serializing_if = "Option::is_none")]
1422 pub network_destination_ip_v6: Option<Vec<IpFilter>>,
1423 #[serde(rename = "NetworkDestinationPort")]
1425 #[serde(skip_serializing_if = "Option::is_none")]
1426 pub network_destination_port: Option<Vec<NumberFilter>>,
1427 #[serde(rename = "NetworkDirection")]
1429 #[serde(skip_serializing_if = "Option::is_none")]
1430 pub network_direction: Option<Vec<StringFilter>>,
1431 #[serde(rename = "NetworkProtocol")]
1433 #[serde(skip_serializing_if = "Option::is_none")]
1434 pub network_protocol: Option<Vec<StringFilter>>,
1435 #[serde(rename = "NetworkSourceDomain")]
1437 #[serde(skip_serializing_if = "Option::is_none")]
1438 pub network_source_domain: Option<Vec<StringFilter>>,
1439 #[serde(rename = "NetworkSourceIpV4")]
1441 #[serde(skip_serializing_if = "Option::is_none")]
1442 pub network_source_ip_v4: Option<Vec<IpFilter>>,
1443 #[serde(rename = "NetworkSourceIpV6")]
1445 #[serde(skip_serializing_if = "Option::is_none")]
1446 pub network_source_ip_v6: Option<Vec<IpFilter>>,
1447 #[serde(rename = "NetworkSourceMac")]
1449 #[serde(skip_serializing_if = "Option::is_none")]
1450 pub network_source_mac: Option<Vec<StringFilter>>,
1451 #[serde(rename = "NetworkSourcePort")]
1453 #[serde(skip_serializing_if = "Option::is_none")]
1454 pub network_source_port: Option<Vec<NumberFilter>>,
1455 #[serde(rename = "NoteText")]
1457 #[serde(skip_serializing_if = "Option::is_none")]
1458 pub note_text: Option<Vec<StringFilter>>,
1459 #[serde(rename = "NoteUpdatedAt")]
1461 #[serde(skip_serializing_if = "Option::is_none")]
1462 pub note_updated_at: Option<Vec<DateFilter>>,
1463 #[serde(rename = "NoteUpdatedBy")]
1465 #[serde(skip_serializing_if = "Option::is_none")]
1466 pub note_updated_by: Option<Vec<StringFilter>>,
1467 #[serde(rename = "ProcessLaunchedAt")]
1469 #[serde(skip_serializing_if = "Option::is_none")]
1470 pub process_launched_at: Option<Vec<DateFilter>>,
1471 #[serde(rename = "ProcessName")]
1473 #[serde(skip_serializing_if = "Option::is_none")]
1474 pub process_name: Option<Vec<StringFilter>>,
1475 #[serde(rename = "ProcessParentPid")]
1477 #[serde(skip_serializing_if = "Option::is_none")]
1478 pub process_parent_pid: Option<Vec<NumberFilter>>,
1479 #[serde(rename = "ProcessPath")]
1481 #[serde(skip_serializing_if = "Option::is_none")]
1482 pub process_path: Option<Vec<StringFilter>>,
1483 #[serde(rename = "ProcessPid")]
1485 #[serde(skip_serializing_if = "Option::is_none")]
1486 pub process_pid: Option<Vec<NumberFilter>>,
1487 #[serde(rename = "ProcessTerminatedAt")]
1489 #[serde(skip_serializing_if = "Option::is_none")]
1490 pub process_terminated_at: Option<Vec<DateFilter>>,
1491 #[serde(rename = "ProductArn")]
1493 #[serde(skip_serializing_if = "Option::is_none")]
1494 pub product_arn: Option<Vec<StringFilter>>,
1495 #[serde(rename = "ProductFields")]
1497 #[serde(skip_serializing_if = "Option::is_none")]
1498 pub product_fields: Option<Vec<MapFilter>>,
1499 #[serde(rename = "ProductName")]
1501 #[serde(skip_serializing_if = "Option::is_none")]
1502 pub product_name: Option<Vec<StringFilter>>,
1503 #[serde(rename = "RecommendationText")]
1505 #[serde(skip_serializing_if = "Option::is_none")]
1506 pub recommendation_text: Option<Vec<StringFilter>>,
1507 #[serde(rename = "RecordState")]
1509 #[serde(skip_serializing_if = "Option::is_none")]
1510 pub record_state: Option<Vec<StringFilter>>,
1511 #[serde(rename = "RelatedFindingsId")]
1513 #[serde(skip_serializing_if = "Option::is_none")]
1514 pub related_findings_id: Option<Vec<StringFilter>>,
1515 #[serde(rename = "RelatedFindingsProductArn")]
1517 #[serde(skip_serializing_if = "Option::is_none")]
1518 pub related_findings_product_arn: Option<Vec<StringFilter>>,
1519 #[serde(rename = "ResourceAwsEc2InstanceIamInstanceProfileArn")]
1521 #[serde(skip_serializing_if = "Option::is_none")]
1522 pub resource_aws_ec_2_instance_iam_instance_profile_arn: Option<Vec<StringFilter>>,
1523 #[serde(rename = "ResourceAwsEc2InstanceImageId")]
1525 #[serde(skip_serializing_if = "Option::is_none")]
1526 pub resource_aws_ec_2_instance_image_id: Option<Vec<StringFilter>>,
1527 #[serde(rename = "ResourceAwsEc2InstanceIpV4Addresses")]
1529 #[serde(skip_serializing_if = "Option::is_none")]
1530 pub resource_aws_ec_2_instance_ip_v4_addresses: Option<Vec<IpFilter>>,
1531 #[serde(rename = "ResourceAwsEc2InstanceIpV6Addresses")]
1533 #[serde(skip_serializing_if = "Option::is_none")]
1534 pub resource_aws_ec_2_instance_ip_v6_addresses: Option<Vec<IpFilter>>,
1535 #[serde(rename = "ResourceAwsEc2InstanceKeyName")]
1537 #[serde(skip_serializing_if = "Option::is_none")]
1538 pub resource_aws_ec_2_instance_key_name: Option<Vec<StringFilter>>,
1539 #[serde(rename = "ResourceAwsEc2InstanceLaunchedAt")]
1541 #[serde(skip_serializing_if = "Option::is_none")]
1542 pub resource_aws_ec_2_instance_launched_at: Option<Vec<DateFilter>>,
1543 #[serde(rename = "ResourceAwsEc2InstanceSubnetId")]
1545 #[serde(skip_serializing_if = "Option::is_none")]
1546 pub resource_aws_ec_2_instance_subnet_id: Option<Vec<StringFilter>>,
1547 #[serde(rename = "ResourceAwsEc2InstanceType")]
1549 #[serde(skip_serializing_if = "Option::is_none")]
1550 pub resource_aws_ec_2_instance_type: Option<Vec<StringFilter>>,
1551 #[serde(rename = "ResourceAwsEc2InstanceVpcId")]
1553 #[serde(skip_serializing_if = "Option::is_none")]
1554 pub resource_aws_ec_2_instance_vpc_id: Option<Vec<StringFilter>>,
1555 #[serde(rename = "ResourceAwsIamAccessKeyCreatedAt")]
1557 #[serde(skip_serializing_if = "Option::is_none")]
1558 pub resource_aws_iam_access_key_created_at: Option<Vec<DateFilter>>,
1559 #[serde(rename = "ResourceAwsIamAccessKeyStatus")]
1561 #[serde(skip_serializing_if = "Option::is_none")]
1562 pub resource_aws_iam_access_key_status: Option<Vec<StringFilter>>,
1563 #[serde(rename = "ResourceAwsIamAccessKeyUserName")]
1565 #[serde(skip_serializing_if = "Option::is_none")]
1566 pub resource_aws_iam_access_key_user_name: Option<Vec<StringFilter>>,
1567 #[serde(rename = "ResourceAwsS3BucketOwnerId")]
1569 #[serde(skip_serializing_if = "Option::is_none")]
1570 pub resource_aws_s3_bucket_owner_id: Option<Vec<StringFilter>>,
1571 #[serde(rename = "ResourceAwsS3BucketOwnerName")]
1573 #[serde(skip_serializing_if = "Option::is_none")]
1574 pub resource_aws_s3_bucket_owner_name: Option<Vec<StringFilter>>,
1575 #[serde(rename = "ResourceContainerImageId")]
1577 #[serde(skip_serializing_if = "Option::is_none")]
1578 pub resource_container_image_id: Option<Vec<StringFilter>>,
1579 #[serde(rename = "ResourceContainerImageName")]
1581 #[serde(skip_serializing_if = "Option::is_none")]
1582 pub resource_container_image_name: Option<Vec<StringFilter>>,
1583 #[serde(rename = "ResourceContainerLaunchedAt")]
1585 #[serde(skip_serializing_if = "Option::is_none")]
1586 pub resource_container_launched_at: Option<Vec<DateFilter>>,
1587 #[serde(rename = "ResourceContainerName")]
1589 #[serde(skip_serializing_if = "Option::is_none")]
1590 pub resource_container_name: Option<Vec<StringFilter>>,
1591 #[serde(rename = "ResourceDetailsOther")]
1593 #[serde(skip_serializing_if = "Option::is_none")]
1594 pub resource_details_other: Option<Vec<MapFilter>>,
1595 #[serde(rename = "ResourceId")]
1597 #[serde(skip_serializing_if = "Option::is_none")]
1598 pub resource_id: Option<Vec<StringFilter>>,
1599 #[serde(rename = "ResourcePartition")]
1601 #[serde(skip_serializing_if = "Option::is_none")]
1602 pub resource_partition: Option<Vec<StringFilter>>,
1603 #[serde(rename = "ResourceRegion")]
1605 #[serde(skip_serializing_if = "Option::is_none")]
1606 pub resource_region: Option<Vec<StringFilter>>,
1607 #[serde(rename = "ResourceTags")]
1609 #[serde(skip_serializing_if = "Option::is_none")]
1610 pub resource_tags: Option<Vec<MapFilter>>,
1611 #[serde(rename = "ResourceType")]
1613 #[serde(skip_serializing_if = "Option::is_none")]
1614 pub resource_type: Option<Vec<StringFilter>>,
1615 #[serde(rename = "SeverityLabel")]
1617 #[serde(skip_serializing_if = "Option::is_none")]
1618 pub severity_label: Option<Vec<StringFilter>>,
1619 #[serde(rename = "SeverityNormalized")]
1621 #[serde(skip_serializing_if = "Option::is_none")]
1622 pub severity_normalized: Option<Vec<NumberFilter>>,
1623 #[serde(rename = "SeverityProduct")]
1625 #[serde(skip_serializing_if = "Option::is_none")]
1626 pub severity_product: Option<Vec<NumberFilter>>,
1627 #[serde(rename = "SourceUrl")]
1629 #[serde(skip_serializing_if = "Option::is_none")]
1630 pub source_url: Option<Vec<StringFilter>>,
1631 #[serde(rename = "ThreatIntelIndicatorCategory")]
1633 #[serde(skip_serializing_if = "Option::is_none")]
1634 pub threat_intel_indicator_category: Option<Vec<StringFilter>>,
1635 #[serde(rename = "ThreatIntelIndicatorLastObservedAt")]
1637 #[serde(skip_serializing_if = "Option::is_none")]
1638 pub threat_intel_indicator_last_observed_at: Option<Vec<DateFilter>>,
1639 #[serde(rename = "ThreatIntelIndicatorSource")]
1641 #[serde(skip_serializing_if = "Option::is_none")]
1642 pub threat_intel_indicator_source: Option<Vec<StringFilter>>,
1643 #[serde(rename = "ThreatIntelIndicatorSourceUrl")]
1645 #[serde(skip_serializing_if = "Option::is_none")]
1646 pub threat_intel_indicator_source_url: Option<Vec<StringFilter>>,
1647 #[serde(rename = "ThreatIntelIndicatorType")]
1649 #[serde(skip_serializing_if = "Option::is_none")]
1650 pub threat_intel_indicator_type: Option<Vec<StringFilter>>,
1651 #[serde(rename = "ThreatIntelIndicatorValue")]
1653 #[serde(skip_serializing_if = "Option::is_none")]
1654 pub threat_intel_indicator_value: Option<Vec<StringFilter>>,
1655 #[serde(rename = "Title")]
1657 #[serde(skip_serializing_if = "Option::is_none")]
1658 pub title: Option<Vec<StringFilter>>,
1659 #[serde(rename = "Type")]
1661 #[serde(skip_serializing_if = "Option::is_none")]
1662 pub type_: Option<Vec<StringFilter>>,
1663 #[serde(rename = "UpdatedAt")]
1665 #[serde(skip_serializing_if = "Option::is_none")]
1666 pub updated_at: Option<Vec<DateFilter>>,
1667 #[serde(rename = "UserDefinedFields")]
1669 #[serde(skip_serializing_if = "Option::is_none")]
1670 pub user_defined_fields: Option<Vec<MapFilter>>,
1671 #[serde(rename = "VerificationState")]
1673 #[serde(skip_serializing_if = "Option::is_none")]
1674 pub verification_state: Option<Vec<StringFilter>>,
1675 #[serde(rename = "WorkflowState")]
1677 #[serde(skip_serializing_if = "Option::is_none")]
1678 pub workflow_state: Option<Vec<StringFilter>>,
1679 #[serde(rename = "WorkflowStatus")]
1681 #[serde(skip_serializing_if = "Option::is_none")]
1682 pub workflow_status: Option<Vec<StringFilter>>,
1683}
1684
1685#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1687pub struct AwsSecurityFindingIdentifier {
1688 #[serde(rename = "Id")]
1690 pub id: String,
1691 #[serde(rename = "ProductArn")]
1693 pub product_arn: String,
1694}
1695
1696#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1698pub struct AwsSnsTopicDetails {
1699 #[serde(rename = "KmsMasterKeyId")]
1701 #[serde(skip_serializing_if = "Option::is_none")]
1702 pub kms_master_key_id: Option<String>,
1703 #[serde(rename = "Owner")]
1705 #[serde(skip_serializing_if = "Option::is_none")]
1706 pub owner: Option<String>,
1707 #[serde(rename = "Subscription")]
1709 #[serde(skip_serializing_if = "Option::is_none")]
1710 pub subscription: Option<Vec<AwsSnsTopicSubscription>>,
1711 #[serde(rename = "TopicName")]
1713 #[serde(skip_serializing_if = "Option::is_none")]
1714 pub topic_name: Option<String>,
1715}
1716
1717#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1719pub struct AwsSnsTopicSubscription {
1720 #[serde(rename = "Endpoint")]
1722 #[serde(skip_serializing_if = "Option::is_none")]
1723 pub endpoint: Option<String>,
1724 #[serde(rename = "Protocol")]
1726 #[serde(skip_serializing_if = "Option::is_none")]
1727 pub protocol: Option<String>,
1728}
1729
1730#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1732pub struct AwsSqsQueueDetails {
1733 #[serde(rename = "DeadLetterTargetArn")]
1735 #[serde(skip_serializing_if = "Option::is_none")]
1736 pub dead_letter_target_arn: Option<String>,
1737 #[serde(rename = "KmsDataKeyReusePeriodSeconds")]
1739 #[serde(skip_serializing_if = "Option::is_none")]
1740 pub kms_data_key_reuse_period_seconds: Option<i64>,
1741 #[serde(rename = "KmsMasterKeyId")]
1743 #[serde(skip_serializing_if = "Option::is_none")]
1744 pub kms_master_key_id: Option<String>,
1745 #[serde(rename = "QueueName")]
1747 #[serde(skip_serializing_if = "Option::is_none")]
1748 pub queue_name: Option<String>,
1749}
1750
1751#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1753pub struct AwsWafWebAclDetails {
1754 #[serde(rename = "DefaultAction")]
1756 #[serde(skip_serializing_if = "Option::is_none")]
1757 pub default_action: Option<String>,
1758 #[serde(rename = "Name")]
1760 #[serde(skip_serializing_if = "Option::is_none")]
1761 pub name: Option<String>,
1762 #[serde(rename = "Rules")]
1764 #[serde(skip_serializing_if = "Option::is_none")]
1765 pub rules: Option<Vec<AwsWafWebAclRule>>,
1766 #[serde(rename = "WebAclId")]
1768 #[serde(skip_serializing_if = "Option::is_none")]
1769 pub web_acl_id: Option<String>,
1770}
1771
1772#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1774pub struct AwsWafWebAclRule {
1775 #[serde(rename = "Action")]
1777 #[serde(skip_serializing_if = "Option::is_none")]
1778 pub action: Option<WafAction>,
1779 #[serde(rename = "ExcludedRules")]
1781 #[serde(skip_serializing_if = "Option::is_none")]
1782 pub excluded_rules: Option<Vec<WafExcludedRule>>,
1783 #[serde(rename = "OverrideAction")]
1785 #[serde(skip_serializing_if = "Option::is_none")]
1786 pub override_action: Option<WafOverrideAction>,
1787 #[serde(rename = "Priority")]
1789 #[serde(skip_serializing_if = "Option::is_none")]
1790 pub priority: Option<i64>,
1791 #[serde(rename = "RuleId")]
1793 #[serde(skip_serializing_if = "Option::is_none")]
1794 pub rule_id: Option<String>,
1795 #[serde(rename = "Type")]
1797 #[serde(skip_serializing_if = "Option::is_none")]
1798 pub type_: Option<String>,
1799}
1800
1801#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1802#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1803pub struct BatchDisableStandardsRequest {
1804 #[serde(rename = "StandardsSubscriptionArns")]
1806 pub standards_subscription_arns: Vec<String>,
1807}
1808
1809#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1810#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1811pub struct BatchDisableStandardsResponse {
1812 #[serde(rename = "StandardsSubscriptions")]
1814 #[serde(skip_serializing_if = "Option::is_none")]
1815 pub standards_subscriptions: Option<Vec<StandardsSubscription>>,
1816}
1817
1818#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1819#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1820pub struct BatchEnableStandardsRequest {
1821 #[serde(rename = "StandardsSubscriptionRequests")]
1823 pub standards_subscription_requests: Vec<StandardsSubscriptionRequest>,
1824}
1825
1826#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1827#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1828pub struct BatchEnableStandardsResponse {
1829 #[serde(rename = "StandardsSubscriptions")]
1831 #[serde(skip_serializing_if = "Option::is_none")]
1832 pub standards_subscriptions: Option<Vec<StandardsSubscription>>,
1833}
1834
1835#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1836#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1837pub struct BatchImportFindingsRequest {
1838 #[serde(rename = "Findings")]
1840 pub findings: Vec<AwsSecurityFinding>,
1841}
1842
1843#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1844#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1845pub struct BatchImportFindingsResponse {
1846 #[serde(rename = "FailedCount")]
1848 pub failed_count: i64,
1849 #[serde(rename = "FailedFindings")]
1851 #[serde(skip_serializing_if = "Option::is_none")]
1852 pub failed_findings: Option<Vec<ImportFindingsError>>,
1853 #[serde(rename = "SuccessCount")]
1855 pub success_count: i64,
1856}
1857
1858#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1859#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1860pub struct BatchUpdateFindingsRequest {
1861 #[serde(rename = "Confidence")]
1863 #[serde(skip_serializing_if = "Option::is_none")]
1864 pub confidence: Option<i64>,
1865 #[serde(rename = "Criticality")]
1867 #[serde(skip_serializing_if = "Option::is_none")]
1868 pub criticality: Option<i64>,
1869 #[serde(rename = "FindingIdentifiers")]
1871 pub finding_identifiers: Vec<AwsSecurityFindingIdentifier>,
1872 #[serde(rename = "Note")]
1873 #[serde(skip_serializing_if = "Option::is_none")]
1874 pub note: Option<NoteUpdate>,
1875 #[serde(rename = "RelatedFindings")]
1877 #[serde(skip_serializing_if = "Option::is_none")]
1878 pub related_findings: Option<Vec<RelatedFinding>>,
1879 #[serde(rename = "Severity")]
1881 #[serde(skip_serializing_if = "Option::is_none")]
1882 pub severity: Option<SeverityUpdate>,
1883 #[serde(rename = "Types")]
1885 #[serde(skip_serializing_if = "Option::is_none")]
1886 pub types: Option<Vec<String>>,
1887 #[serde(rename = "UserDefinedFields")]
1889 #[serde(skip_serializing_if = "Option::is_none")]
1890 pub user_defined_fields: Option<::std::collections::HashMap<String, String>>,
1891 #[serde(rename = "VerificationState")]
1893 #[serde(skip_serializing_if = "Option::is_none")]
1894 pub verification_state: Option<String>,
1895 #[serde(rename = "Workflow")]
1897 #[serde(skip_serializing_if = "Option::is_none")]
1898 pub workflow: Option<WorkflowUpdate>,
1899}
1900
1901#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1902#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1903pub struct BatchUpdateFindingsResponse {
1904 #[serde(rename = "ProcessedFindings")]
1906 pub processed_findings: Vec<AwsSecurityFindingIdentifier>,
1907 #[serde(rename = "UnprocessedFindings")]
1909 pub unprocessed_findings: Vec<BatchUpdateFindingsUnprocessedFinding>,
1910}
1911
1912#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1914#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1915pub struct BatchUpdateFindingsUnprocessedFinding {
1916 #[serde(rename = "ErrorCode")]
1918 pub error_code: String,
1919 #[serde(rename = "ErrorMessage")]
1921 pub error_message: String,
1922 #[serde(rename = "FindingIdentifier")]
1924 pub finding_identifier: AwsSecurityFindingIdentifier,
1925}
1926
1927#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1929pub struct CidrBlockAssociation {
1930 #[serde(rename = "AssociationId")]
1932 #[serde(skip_serializing_if = "Option::is_none")]
1933 pub association_id: Option<String>,
1934 #[serde(rename = "CidrBlock")]
1936 #[serde(skip_serializing_if = "Option::is_none")]
1937 pub cidr_block: Option<String>,
1938 #[serde(rename = "CidrBlockState")]
1940 #[serde(skip_serializing_if = "Option::is_none")]
1941 pub cidr_block_state: Option<String>,
1942}
1943
1944#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1946pub struct Compliance {
1947 #[serde(rename = "RelatedRequirements")]
1949 #[serde(skip_serializing_if = "Option::is_none")]
1950 pub related_requirements: Option<Vec<String>>,
1951 #[serde(rename = "Status")]
1953 #[serde(skip_serializing_if = "Option::is_none")]
1954 pub status: Option<String>,
1955 #[serde(rename = "StatusReasons")]
1957 #[serde(skip_serializing_if = "Option::is_none")]
1958 pub status_reasons: Option<Vec<StatusReason>>,
1959}
1960
1961#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
1963pub struct ContainerDetails {
1964 #[serde(rename = "ImageId")]
1966 #[serde(skip_serializing_if = "Option::is_none")]
1967 pub image_id: Option<String>,
1968 #[serde(rename = "ImageName")]
1970 #[serde(skip_serializing_if = "Option::is_none")]
1971 pub image_name: Option<String>,
1972 #[serde(rename = "LaunchedAt")]
1974 #[serde(skip_serializing_if = "Option::is_none")]
1975 pub launched_at: Option<String>,
1976 #[serde(rename = "Name")]
1978 #[serde(skip_serializing_if = "Option::is_none")]
1979 pub name: Option<String>,
1980}
1981
1982#[derive(Clone, Debug, Default, PartialEq, Serialize)]
1983#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
1984pub struct CreateActionTargetRequest {
1985 #[serde(rename = "Description")]
1987 pub description: String,
1988 #[serde(rename = "Id")]
1990 pub id: String,
1991 #[serde(rename = "Name")]
1993 pub name: String,
1994}
1995
1996#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
1997#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
1998pub struct CreateActionTargetResponse {
1999 #[serde(rename = "ActionTargetArn")]
2001 pub action_target_arn: String,
2002}
2003
2004#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2005#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2006pub struct CreateInsightRequest {
2007 #[serde(rename = "Filters")]
2009 pub filters: AwsSecurityFindingFilters,
2010 #[serde(rename = "GroupByAttribute")]
2012 pub group_by_attribute: String,
2013 #[serde(rename = "Name")]
2015 pub name: String,
2016}
2017
2018#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2019#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2020pub struct CreateInsightResponse {
2021 #[serde(rename = "InsightArn")]
2023 pub insight_arn: String,
2024}
2025
2026#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2027#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2028pub struct CreateMembersRequest {
2029 #[serde(rename = "AccountDetails")]
2031 #[serde(skip_serializing_if = "Option::is_none")]
2032 pub account_details: Option<Vec<AccountDetails>>,
2033}
2034
2035#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2036#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2037pub struct CreateMembersResponse {
2038 #[serde(rename = "UnprocessedAccounts")]
2040 #[serde(skip_serializing_if = "Option::is_none")]
2041 pub unprocessed_accounts: Option<Vec<SecurityHubResult>>,
2042}
2043
2044#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2046pub struct Cvss {
2047 #[serde(rename = "BaseScore")]
2049 #[serde(skip_serializing_if = "Option::is_none")]
2050 pub base_score: Option<f64>,
2051 #[serde(rename = "BaseVector")]
2053 #[serde(skip_serializing_if = "Option::is_none")]
2054 pub base_vector: Option<String>,
2055 #[serde(rename = "Version")]
2057 #[serde(skip_serializing_if = "Option::is_none")]
2058 pub version: Option<String>,
2059}
2060
2061#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2063pub struct DateFilter {
2064 #[serde(rename = "DateRange")]
2066 #[serde(skip_serializing_if = "Option::is_none")]
2067 pub date_range: Option<DateRange>,
2068 #[serde(rename = "End")]
2070 #[serde(skip_serializing_if = "Option::is_none")]
2071 pub end: Option<String>,
2072 #[serde(rename = "Start")]
2074 #[serde(skip_serializing_if = "Option::is_none")]
2075 pub start: Option<String>,
2076}
2077
2078#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2080pub struct DateRange {
2081 #[serde(rename = "Unit")]
2083 #[serde(skip_serializing_if = "Option::is_none")]
2084 pub unit: Option<String>,
2085 #[serde(rename = "Value")]
2087 #[serde(skip_serializing_if = "Option::is_none")]
2088 pub value: Option<i64>,
2089}
2090
2091#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2092#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2093pub struct DeclineInvitationsRequest {
2094 #[serde(rename = "AccountIds")]
2096 pub account_ids: Vec<String>,
2097}
2098
2099#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2100#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2101pub struct DeclineInvitationsResponse {
2102 #[serde(rename = "UnprocessedAccounts")]
2104 #[serde(skip_serializing_if = "Option::is_none")]
2105 pub unprocessed_accounts: Option<Vec<SecurityHubResult>>,
2106}
2107
2108#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2109#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2110pub struct DeleteActionTargetRequest {
2111 #[serde(rename = "ActionTargetArn")]
2113 pub action_target_arn: String,
2114}
2115
2116#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2117#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2118pub struct DeleteActionTargetResponse {
2119 #[serde(rename = "ActionTargetArn")]
2121 pub action_target_arn: String,
2122}
2123
2124#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2125#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2126pub struct DeleteInsightRequest {
2127 #[serde(rename = "InsightArn")]
2129 pub insight_arn: String,
2130}
2131
2132#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2133#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2134pub struct DeleteInsightResponse {
2135 #[serde(rename = "InsightArn")]
2137 pub insight_arn: String,
2138}
2139
2140#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2141#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2142pub struct DeleteInvitationsRequest {
2143 #[serde(rename = "AccountIds")]
2145 pub account_ids: Vec<String>,
2146}
2147
2148#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2149#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2150pub struct DeleteInvitationsResponse {
2151 #[serde(rename = "UnprocessedAccounts")]
2153 #[serde(skip_serializing_if = "Option::is_none")]
2154 pub unprocessed_accounts: Option<Vec<SecurityHubResult>>,
2155}
2156
2157#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2158#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2159pub struct DeleteMembersRequest {
2160 #[serde(rename = "AccountIds")]
2162 #[serde(skip_serializing_if = "Option::is_none")]
2163 pub account_ids: Option<Vec<String>>,
2164}
2165
2166#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2167#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2168pub struct DeleteMembersResponse {
2169 #[serde(rename = "UnprocessedAccounts")]
2171 #[serde(skip_serializing_if = "Option::is_none")]
2172 pub unprocessed_accounts: Option<Vec<SecurityHubResult>>,
2173}
2174
2175#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2176#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2177pub struct DescribeActionTargetsRequest {
2178 #[serde(rename = "ActionTargetArns")]
2180 #[serde(skip_serializing_if = "Option::is_none")]
2181 pub action_target_arns: Option<Vec<String>>,
2182 #[serde(rename = "MaxResults")]
2184 #[serde(skip_serializing_if = "Option::is_none")]
2185 pub max_results: Option<i64>,
2186 #[serde(rename = "NextToken")]
2188 #[serde(skip_serializing_if = "Option::is_none")]
2189 pub next_token: Option<String>,
2190}
2191
2192#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2193#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2194pub struct DescribeActionTargetsResponse {
2195 #[serde(rename = "ActionTargets")]
2197 pub action_targets: Vec<ActionTarget>,
2198 #[serde(rename = "NextToken")]
2200 #[serde(skip_serializing_if = "Option::is_none")]
2201 pub next_token: Option<String>,
2202}
2203
2204#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2205#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2206pub struct DescribeHubRequest {
2207 #[serde(rename = "HubArn")]
2209 #[serde(skip_serializing_if = "Option::is_none")]
2210 pub hub_arn: Option<String>,
2211}
2212
2213#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2214#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2215pub struct DescribeHubResponse {
2216 #[serde(rename = "HubArn")]
2218 #[serde(skip_serializing_if = "Option::is_none")]
2219 pub hub_arn: Option<String>,
2220 #[serde(rename = "SubscribedAt")]
2222 #[serde(skip_serializing_if = "Option::is_none")]
2223 pub subscribed_at: Option<String>,
2224}
2225
2226#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2227#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2228pub struct DescribeProductsRequest {
2229 #[serde(rename = "MaxResults")]
2231 #[serde(skip_serializing_if = "Option::is_none")]
2232 pub max_results: Option<i64>,
2233 #[serde(rename = "NextToken")]
2235 #[serde(skip_serializing_if = "Option::is_none")]
2236 pub next_token: Option<String>,
2237}
2238
2239#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2240#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2241pub struct DescribeProductsResponse {
2242 #[serde(rename = "NextToken")]
2244 #[serde(skip_serializing_if = "Option::is_none")]
2245 pub next_token: Option<String>,
2246 #[serde(rename = "Products")]
2248 pub products: Vec<Product>,
2249}
2250
2251#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2252#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2253pub struct DescribeStandardsControlsRequest {
2254 #[serde(rename = "MaxResults")]
2256 #[serde(skip_serializing_if = "Option::is_none")]
2257 pub max_results: Option<i64>,
2258 #[serde(rename = "NextToken")]
2260 #[serde(skip_serializing_if = "Option::is_none")]
2261 pub next_token: Option<String>,
2262 #[serde(rename = "StandardsSubscriptionArn")]
2264 pub standards_subscription_arn: String,
2265}
2266
2267#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2268#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2269pub struct DescribeStandardsControlsResponse {
2270 #[serde(rename = "Controls")]
2272 #[serde(skip_serializing_if = "Option::is_none")]
2273 pub controls: Option<Vec<StandardsControl>>,
2274 #[serde(rename = "NextToken")]
2276 #[serde(skip_serializing_if = "Option::is_none")]
2277 pub next_token: Option<String>,
2278}
2279
2280#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2281#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2282pub struct DescribeStandardsRequest {
2283 #[serde(rename = "MaxResults")]
2285 #[serde(skip_serializing_if = "Option::is_none")]
2286 pub max_results: Option<i64>,
2287 #[serde(rename = "NextToken")]
2289 #[serde(skip_serializing_if = "Option::is_none")]
2290 pub next_token: Option<String>,
2291}
2292
2293#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2294#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2295pub struct DescribeStandardsResponse {
2296 #[serde(rename = "NextToken")]
2298 #[serde(skip_serializing_if = "Option::is_none")]
2299 pub next_token: Option<String>,
2300 #[serde(rename = "Standards")]
2302 #[serde(skip_serializing_if = "Option::is_none")]
2303 pub standards: Option<Vec<Standard>>,
2304}
2305
2306#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2307#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2308pub struct DisableImportFindingsForProductRequest {
2309 #[serde(rename = "ProductSubscriptionArn")]
2311 pub product_subscription_arn: String,
2312}
2313
2314#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2315#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2316pub struct DisableImportFindingsForProductResponse {}
2317
2318#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2319#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2320pub struct DisableSecurityHubRequest {}
2321
2322#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2323#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2324pub struct DisableSecurityHubResponse {}
2325
2326#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2327#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2328pub struct DisassociateFromMasterAccountRequest {}
2329
2330#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2331#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2332pub struct DisassociateFromMasterAccountResponse {}
2333
2334#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2335#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2336pub struct DisassociateMembersRequest {
2337 #[serde(rename = "AccountIds")]
2339 #[serde(skip_serializing_if = "Option::is_none")]
2340 pub account_ids: Option<Vec<String>>,
2341}
2342
2343#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2344#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2345pub struct DisassociateMembersResponse {}
2346
2347#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2348#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2349pub struct EnableImportFindingsForProductRequest {
2350 #[serde(rename = "ProductArn")]
2352 pub product_arn: String,
2353}
2354
2355#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2356#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2357pub struct EnableImportFindingsForProductResponse {
2358 #[serde(rename = "ProductSubscriptionArn")]
2360 #[serde(skip_serializing_if = "Option::is_none")]
2361 pub product_subscription_arn: Option<String>,
2362}
2363
2364#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2365#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2366pub struct EnableSecurityHubRequest {
2367 #[serde(rename = "EnableDefaultStandards")]
2369 #[serde(skip_serializing_if = "Option::is_none")]
2370 pub enable_default_standards: Option<bool>,
2371 #[serde(rename = "Tags")]
2373 #[serde(skip_serializing_if = "Option::is_none")]
2374 pub tags: Option<::std::collections::HashMap<String, String>>,
2375}
2376
2377#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2378#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2379pub struct EnableSecurityHubResponse {}
2380
2381#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2382#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2383pub struct GetEnabledStandardsRequest {
2384 #[serde(rename = "MaxResults")]
2386 #[serde(skip_serializing_if = "Option::is_none")]
2387 pub max_results: Option<i64>,
2388 #[serde(rename = "NextToken")]
2390 #[serde(skip_serializing_if = "Option::is_none")]
2391 pub next_token: Option<String>,
2392 #[serde(rename = "StandardsSubscriptionArns")]
2394 #[serde(skip_serializing_if = "Option::is_none")]
2395 pub standards_subscription_arns: Option<Vec<String>>,
2396}
2397
2398#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2399#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2400pub struct GetEnabledStandardsResponse {
2401 #[serde(rename = "NextToken")]
2403 #[serde(skip_serializing_if = "Option::is_none")]
2404 pub next_token: Option<String>,
2405 #[serde(rename = "StandardsSubscriptions")]
2407 #[serde(skip_serializing_if = "Option::is_none")]
2408 pub standards_subscriptions: Option<Vec<StandardsSubscription>>,
2409}
2410
2411#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2412#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2413pub struct GetFindingsRequest {
2414 #[serde(rename = "Filters")]
2416 #[serde(skip_serializing_if = "Option::is_none")]
2417 pub filters: Option<AwsSecurityFindingFilters>,
2418 #[serde(rename = "MaxResults")]
2420 #[serde(skip_serializing_if = "Option::is_none")]
2421 pub max_results: Option<i64>,
2422 #[serde(rename = "NextToken")]
2424 #[serde(skip_serializing_if = "Option::is_none")]
2425 pub next_token: Option<String>,
2426 #[serde(rename = "SortCriteria")]
2428 #[serde(skip_serializing_if = "Option::is_none")]
2429 pub sort_criteria: Option<Vec<SortCriterion>>,
2430}
2431
2432#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2433#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2434pub struct GetFindingsResponse {
2435 #[serde(rename = "Findings")]
2437 pub findings: Vec<AwsSecurityFinding>,
2438 #[serde(rename = "NextToken")]
2440 #[serde(skip_serializing_if = "Option::is_none")]
2441 pub next_token: Option<String>,
2442}
2443
2444#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2445#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2446pub struct GetInsightResultsRequest {
2447 #[serde(rename = "InsightArn")]
2449 pub insight_arn: String,
2450}
2451
2452#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2453#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2454pub struct GetInsightResultsResponse {
2455 #[serde(rename = "InsightResults")]
2457 pub insight_results: InsightResults,
2458}
2459
2460#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2461#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2462pub struct GetInsightsRequest {
2463 #[serde(rename = "InsightArns")]
2465 #[serde(skip_serializing_if = "Option::is_none")]
2466 pub insight_arns: Option<Vec<String>>,
2467 #[serde(rename = "MaxResults")]
2469 #[serde(skip_serializing_if = "Option::is_none")]
2470 pub max_results: Option<i64>,
2471 #[serde(rename = "NextToken")]
2473 #[serde(skip_serializing_if = "Option::is_none")]
2474 pub next_token: Option<String>,
2475}
2476
2477#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2478#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2479pub struct GetInsightsResponse {
2480 #[serde(rename = "Insights")]
2482 pub insights: Vec<Insight>,
2483 #[serde(rename = "NextToken")]
2485 #[serde(skip_serializing_if = "Option::is_none")]
2486 pub next_token: Option<String>,
2487}
2488
2489#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2490#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2491pub struct GetInvitationsCountRequest {}
2492
2493#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2494#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2495pub struct GetInvitationsCountResponse {
2496 #[serde(rename = "InvitationsCount")]
2498 #[serde(skip_serializing_if = "Option::is_none")]
2499 pub invitations_count: Option<i64>,
2500}
2501
2502#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2503#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2504pub struct GetMasterAccountRequest {}
2505
2506#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2507#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2508pub struct GetMasterAccountResponse {
2509 #[serde(rename = "Master")]
2511 #[serde(skip_serializing_if = "Option::is_none")]
2512 pub master: Option<Invitation>,
2513}
2514
2515#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2516#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2517pub struct GetMembersRequest {
2518 #[serde(rename = "AccountIds")]
2520 pub account_ids: Vec<String>,
2521}
2522
2523#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2524#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2525pub struct GetMembersResponse {
2526 #[serde(rename = "Members")]
2528 #[serde(skip_serializing_if = "Option::is_none")]
2529 pub members: Option<Vec<Member>>,
2530 #[serde(rename = "UnprocessedAccounts")]
2532 #[serde(skip_serializing_if = "Option::is_none")]
2533 pub unprocessed_accounts: Option<Vec<SecurityHubResult>>,
2534}
2535
2536#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2538#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2539pub struct ImportFindingsError {
2540 #[serde(rename = "ErrorCode")]
2542 pub error_code: String,
2543 #[serde(rename = "ErrorMessage")]
2545 pub error_message: String,
2546 #[serde(rename = "Id")]
2548 pub id: String,
2549}
2550
2551#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2553#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2554pub struct Insight {
2555 #[serde(rename = "Filters")]
2557 pub filters: AwsSecurityFindingFilters,
2558 #[serde(rename = "GroupByAttribute")]
2560 pub group_by_attribute: String,
2561 #[serde(rename = "InsightArn")]
2563 pub insight_arn: String,
2564 #[serde(rename = "Name")]
2566 pub name: String,
2567}
2568
2569#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2571#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2572pub struct InsightResultValue {
2573 #[serde(rename = "Count")]
2575 pub count: i64,
2576 #[serde(rename = "GroupByAttributeValue")]
2578 pub group_by_attribute_value: String,
2579}
2580
2581#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2583#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2584pub struct InsightResults {
2585 #[serde(rename = "GroupByAttribute")]
2587 pub group_by_attribute: String,
2588 #[serde(rename = "InsightArn")]
2590 pub insight_arn: String,
2591 #[serde(rename = "ResultValues")]
2593 pub result_values: Vec<InsightResultValue>,
2594}
2595
2596#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2598#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2599pub struct Invitation {
2600 #[serde(rename = "AccountId")]
2602 #[serde(skip_serializing_if = "Option::is_none")]
2603 pub account_id: Option<String>,
2604 #[serde(rename = "InvitationId")]
2606 #[serde(skip_serializing_if = "Option::is_none")]
2607 pub invitation_id: Option<String>,
2608 #[serde(rename = "InvitedAt")]
2610 #[serde(skip_serializing_if = "Option::is_none")]
2611 pub invited_at: Option<f64>,
2612 #[serde(rename = "MemberStatus")]
2614 #[serde(skip_serializing_if = "Option::is_none")]
2615 pub member_status: Option<String>,
2616}
2617
2618#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2619#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2620pub struct InviteMembersRequest {
2621 #[serde(rename = "AccountIds")]
2623 #[serde(skip_serializing_if = "Option::is_none")]
2624 pub account_ids: Option<Vec<String>>,
2625}
2626
2627#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2628#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2629pub struct InviteMembersResponse {
2630 #[serde(rename = "UnprocessedAccounts")]
2632 #[serde(skip_serializing_if = "Option::is_none")]
2633 pub unprocessed_accounts: Option<Vec<SecurityHubResult>>,
2634}
2635
2636#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2638pub struct IpFilter {
2639 #[serde(rename = "Cidr")]
2641 #[serde(skip_serializing_if = "Option::is_none")]
2642 pub cidr: Option<String>,
2643}
2644
2645#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2647pub struct Ipv6CidrBlockAssociation {
2648 #[serde(rename = "AssociationId")]
2650 #[serde(skip_serializing_if = "Option::is_none")]
2651 pub association_id: Option<String>,
2652 #[serde(rename = "CidrBlockState")]
2654 #[serde(skip_serializing_if = "Option::is_none")]
2655 pub cidr_block_state: Option<String>,
2656 #[serde(rename = "Ipv6CidrBlock")]
2658 #[serde(skip_serializing_if = "Option::is_none")]
2659 pub ipv_6_cidr_block: Option<String>,
2660}
2661
2662#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2664pub struct KeywordFilter {
2665 #[serde(rename = "Value")]
2667 #[serde(skip_serializing_if = "Option::is_none")]
2668 pub value: Option<String>,
2669}
2670
2671#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2672#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2673pub struct ListEnabledProductsForImportRequest {
2674 #[serde(rename = "MaxResults")]
2676 #[serde(skip_serializing_if = "Option::is_none")]
2677 pub max_results: Option<i64>,
2678 #[serde(rename = "NextToken")]
2680 #[serde(skip_serializing_if = "Option::is_none")]
2681 pub next_token: Option<String>,
2682}
2683
2684#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2685#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2686pub struct ListEnabledProductsForImportResponse {
2687 #[serde(rename = "NextToken")]
2689 #[serde(skip_serializing_if = "Option::is_none")]
2690 pub next_token: Option<String>,
2691 #[serde(rename = "ProductSubscriptions")]
2693 #[serde(skip_serializing_if = "Option::is_none")]
2694 pub product_subscriptions: Option<Vec<String>>,
2695}
2696
2697#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2698#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2699pub struct ListInvitationsRequest {
2700 #[serde(rename = "MaxResults")]
2702 #[serde(skip_serializing_if = "Option::is_none")]
2703 pub max_results: Option<i64>,
2704 #[serde(rename = "NextToken")]
2706 #[serde(skip_serializing_if = "Option::is_none")]
2707 pub next_token: Option<String>,
2708}
2709
2710#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2711#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2712pub struct ListInvitationsResponse {
2713 #[serde(rename = "Invitations")]
2715 #[serde(skip_serializing_if = "Option::is_none")]
2716 pub invitations: Option<Vec<Invitation>>,
2717 #[serde(rename = "NextToken")]
2719 #[serde(skip_serializing_if = "Option::is_none")]
2720 pub next_token: Option<String>,
2721}
2722
2723#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2724#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2725pub struct ListMembersRequest {
2726 #[serde(rename = "MaxResults")]
2728 #[serde(skip_serializing_if = "Option::is_none")]
2729 pub max_results: Option<i64>,
2730 #[serde(rename = "NextToken")]
2732 #[serde(skip_serializing_if = "Option::is_none")]
2733 pub next_token: Option<String>,
2734 #[serde(rename = "OnlyAssociated")]
2736 #[serde(skip_serializing_if = "Option::is_none")]
2737 pub only_associated: Option<bool>,
2738}
2739
2740#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2741#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2742pub struct ListMembersResponse {
2743 #[serde(rename = "Members")]
2745 #[serde(skip_serializing_if = "Option::is_none")]
2746 pub members: Option<Vec<Member>>,
2747 #[serde(rename = "NextToken")]
2749 #[serde(skip_serializing_if = "Option::is_none")]
2750 pub next_token: Option<String>,
2751}
2752
2753#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2754#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2755pub struct ListTagsForResourceRequest {
2756 #[serde(rename = "ResourceArn")]
2758 pub resource_arn: String,
2759}
2760
2761#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2762#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2763pub struct ListTagsForResourceResponse {
2764 #[serde(rename = "Tags")]
2766 #[serde(skip_serializing_if = "Option::is_none")]
2767 pub tags: Option<::std::collections::HashMap<String, String>>,
2768}
2769
2770#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2772pub struct LoadBalancerState {
2773 #[serde(rename = "Code")]
2775 #[serde(skip_serializing_if = "Option::is_none")]
2776 pub code: Option<String>,
2777 #[serde(rename = "Reason")]
2779 #[serde(skip_serializing_if = "Option::is_none")]
2780 pub reason: Option<String>,
2781}
2782
2783#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2785pub struct Malware {
2786 #[serde(rename = "Name")]
2788 pub name: String,
2789 #[serde(rename = "Path")]
2791 #[serde(skip_serializing_if = "Option::is_none")]
2792 pub path: Option<String>,
2793 #[serde(rename = "State")]
2795 #[serde(skip_serializing_if = "Option::is_none")]
2796 pub state: Option<String>,
2797 #[serde(rename = "Type")]
2799 #[serde(skip_serializing_if = "Option::is_none")]
2800 pub type_: Option<String>,
2801}
2802
2803#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2805pub struct MapFilter {
2806 #[serde(rename = "Comparison")]
2808 #[serde(skip_serializing_if = "Option::is_none")]
2809 pub comparison: Option<String>,
2810 #[serde(rename = "Key")]
2812 #[serde(skip_serializing_if = "Option::is_none")]
2813 pub key: Option<String>,
2814 #[serde(rename = "Value")]
2816 #[serde(skip_serializing_if = "Option::is_none")]
2817 pub value: Option<String>,
2818}
2819
2820#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
2822#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
2823pub struct Member {
2824 #[serde(rename = "AccountId")]
2826 #[serde(skip_serializing_if = "Option::is_none")]
2827 pub account_id: Option<String>,
2828 #[serde(rename = "Email")]
2830 #[serde(skip_serializing_if = "Option::is_none")]
2831 pub email: Option<String>,
2832 #[serde(rename = "InvitedAt")]
2834 #[serde(skip_serializing_if = "Option::is_none")]
2835 pub invited_at: Option<f64>,
2836 #[serde(rename = "MasterId")]
2838 #[serde(skip_serializing_if = "Option::is_none")]
2839 pub master_id: Option<String>,
2840 #[serde(rename = "MemberStatus")]
2842 #[serde(skip_serializing_if = "Option::is_none")]
2843 pub member_status: Option<String>,
2844 #[serde(rename = "UpdatedAt")]
2846 #[serde(skip_serializing_if = "Option::is_none")]
2847 pub updated_at: Option<f64>,
2848}
2849
2850#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2852pub struct Network {
2853 #[serde(rename = "DestinationDomain")]
2855 #[serde(skip_serializing_if = "Option::is_none")]
2856 pub destination_domain: Option<String>,
2857 #[serde(rename = "DestinationIpV4")]
2859 #[serde(skip_serializing_if = "Option::is_none")]
2860 pub destination_ip_v4: Option<String>,
2861 #[serde(rename = "DestinationIpV6")]
2863 #[serde(skip_serializing_if = "Option::is_none")]
2864 pub destination_ip_v6: Option<String>,
2865 #[serde(rename = "DestinationPort")]
2867 #[serde(skip_serializing_if = "Option::is_none")]
2868 pub destination_port: Option<i64>,
2869 #[serde(rename = "Direction")]
2871 #[serde(skip_serializing_if = "Option::is_none")]
2872 pub direction: Option<String>,
2873 #[serde(rename = "OpenPortRange")]
2875 #[serde(skip_serializing_if = "Option::is_none")]
2876 pub open_port_range: Option<PortRange>,
2877 #[serde(rename = "Protocol")]
2879 #[serde(skip_serializing_if = "Option::is_none")]
2880 pub protocol: Option<String>,
2881 #[serde(rename = "SourceDomain")]
2883 #[serde(skip_serializing_if = "Option::is_none")]
2884 pub source_domain: Option<String>,
2885 #[serde(rename = "SourceIpV4")]
2887 #[serde(skip_serializing_if = "Option::is_none")]
2888 pub source_ip_v4: Option<String>,
2889 #[serde(rename = "SourceIpV6")]
2891 #[serde(skip_serializing_if = "Option::is_none")]
2892 pub source_ip_v6: Option<String>,
2893 #[serde(rename = "SourceMac")]
2895 #[serde(skip_serializing_if = "Option::is_none")]
2896 pub source_mac: Option<String>,
2897 #[serde(rename = "SourcePort")]
2899 #[serde(skip_serializing_if = "Option::is_none")]
2900 pub source_port: Option<i64>,
2901}
2902
2903#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2905pub struct NetworkHeader {
2906 #[serde(rename = "Destination")]
2908 #[serde(skip_serializing_if = "Option::is_none")]
2909 pub destination: Option<NetworkPathComponentDetails>,
2910 #[serde(rename = "Protocol")]
2912 #[serde(skip_serializing_if = "Option::is_none")]
2913 pub protocol: Option<String>,
2914 #[serde(rename = "Source")]
2916 #[serde(skip_serializing_if = "Option::is_none")]
2917 pub source: Option<NetworkPathComponentDetails>,
2918}
2919
2920#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2922pub struct NetworkPathComponent {
2923 #[serde(rename = "ComponentId")]
2925 #[serde(skip_serializing_if = "Option::is_none")]
2926 pub component_id: Option<String>,
2927 #[serde(rename = "ComponentType")]
2929 #[serde(skip_serializing_if = "Option::is_none")]
2930 pub component_type: Option<String>,
2931 #[serde(rename = "Egress")]
2933 #[serde(skip_serializing_if = "Option::is_none")]
2934 pub egress: Option<NetworkHeader>,
2935 #[serde(rename = "Ingress")]
2937 #[serde(skip_serializing_if = "Option::is_none")]
2938 pub ingress: Option<NetworkHeader>,
2939}
2940
2941#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2943pub struct NetworkPathComponentDetails {
2944 #[serde(rename = "Address")]
2946 #[serde(skip_serializing_if = "Option::is_none")]
2947 pub address: Option<Vec<String>>,
2948 #[serde(rename = "PortRanges")]
2950 #[serde(skip_serializing_if = "Option::is_none")]
2951 pub port_ranges: Option<Vec<PortRange>>,
2952}
2953
2954#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2956pub struct Note {
2957 #[serde(rename = "Text")]
2959 pub text: String,
2960 #[serde(rename = "UpdatedAt")]
2962 pub updated_at: String,
2963 #[serde(rename = "UpdatedBy")]
2965 pub updated_by: String,
2966}
2967
2968#[derive(Clone, Debug, Default, PartialEq, Serialize)]
2970#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
2971pub struct NoteUpdate {
2972 #[serde(rename = "Text")]
2974 pub text: String,
2975 #[serde(rename = "UpdatedBy")]
2977 pub updated_by: String,
2978}
2979
2980#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2982pub struct NumberFilter {
2983 #[serde(rename = "Eq")]
2985 #[serde(skip_serializing_if = "Option::is_none")]
2986 pub eq: Option<f64>,
2987 #[serde(rename = "Gte")]
2989 #[serde(skip_serializing_if = "Option::is_none")]
2990 pub gte: Option<f64>,
2991 #[serde(rename = "Lte")]
2993 #[serde(skip_serializing_if = "Option::is_none")]
2994 pub lte: Option<f64>,
2995}
2996
2997#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
2999pub struct PortRange {
3000 #[serde(rename = "Begin")]
3002 #[serde(skip_serializing_if = "Option::is_none")]
3003 pub begin: Option<i64>,
3004 #[serde(rename = "End")]
3006 #[serde(skip_serializing_if = "Option::is_none")]
3007 pub end: Option<i64>,
3008}
3009
3010#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3012pub struct ProcessDetails {
3013 #[serde(rename = "LaunchedAt")]
3015 #[serde(skip_serializing_if = "Option::is_none")]
3016 pub launched_at: Option<String>,
3017 #[serde(rename = "Name")]
3019 #[serde(skip_serializing_if = "Option::is_none")]
3020 pub name: Option<String>,
3021 #[serde(rename = "ParentPid")]
3023 #[serde(skip_serializing_if = "Option::is_none")]
3024 pub parent_pid: Option<i64>,
3025 #[serde(rename = "Path")]
3027 #[serde(skip_serializing_if = "Option::is_none")]
3028 pub path: Option<String>,
3029 #[serde(rename = "Pid")]
3031 #[serde(skip_serializing_if = "Option::is_none")]
3032 pub pid: Option<i64>,
3033 #[serde(rename = "TerminatedAt")]
3035 #[serde(skip_serializing_if = "Option::is_none")]
3036 pub terminated_at: Option<String>,
3037}
3038
3039#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3041#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3042pub struct Product {
3043 #[serde(rename = "ActivationUrl")]
3045 #[serde(skip_serializing_if = "Option::is_none")]
3046 pub activation_url: Option<String>,
3047 #[serde(rename = "Categories")]
3049 #[serde(skip_serializing_if = "Option::is_none")]
3050 pub categories: Option<Vec<String>>,
3051 #[serde(rename = "CompanyName")]
3053 #[serde(skip_serializing_if = "Option::is_none")]
3054 pub company_name: Option<String>,
3055 #[serde(rename = "Description")]
3057 #[serde(skip_serializing_if = "Option::is_none")]
3058 pub description: Option<String>,
3059 #[serde(rename = "IntegrationTypes")]
3061 #[serde(skip_serializing_if = "Option::is_none")]
3062 pub integration_types: Option<Vec<String>>,
3063 #[serde(rename = "MarketplaceUrl")]
3065 #[serde(skip_serializing_if = "Option::is_none")]
3066 pub marketplace_url: Option<String>,
3067 #[serde(rename = "ProductArn")]
3069 pub product_arn: String,
3070 #[serde(rename = "ProductName")]
3072 #[serde(skip_serializing_if = "Option::is_none")]
3073 pub product_name: Option<String>,
3074 #[serde(rename = "ProductSubscriptionResourcePolicy")]
3076 #[serde(skip_serializing_if = "Option::is_none")]
3077 pub product_subscription_resource_policy: Option<String>,
3078}
3079
3080#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3082pub struct Recommendation {
3083 #[serde(rename = "Text")]
3085 #[serde(skip_serializing_if = "Option::is_none")]
3086 pub text: Option<String>,
3087 #[serde(rename = "Url")]
3089 #[serde(skip_serializing_if = "Option::is_none")]
3090 pub url: Option<String>,
3091}
3092
3093#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3095pub struct RelatedFinding {
3096 #[serde(rename = "Id")]
3098 pub id: String,
3099 #[serde(rename = "ProductArn")]
3101 pub product_arn: String,
3102}
3103
3104#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3106pub struct Remediation {
3107 #[serde(rename = "Recommendation")]
3109 #[serde(skip_serializing_if = "Option::is_none")]
3110 pub recommendation: Option<Recommendation>,
3111}
3112
3113#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3115pub struct Resource {
3116 #[serde(rename = "Details")]
3118 #[serde(skip_serializing_if = "Option::is_none")]
3119 pub details: Option<ResourceDetails>,
3120 #[serde(rename = "Id")]
3122 pub id: String,
3123 #[serde(rename = "Partition")]
3125 #[serde(skip_serializing_if = "Option::is_none")]
3126 pub partition: Option<String>,
3127 #[serde(rename = "Region")]
3129 #[serde(skip_serializing_if = "Option::is_none")]
3130 pub region: Option<String>,
3131 #[serde(rename = "Tags")]
3133 #[serde(skip_serializing_if = "Option::is_none")]
3134 pub tags: Option<::std::collections::HashMap<String, String>>,
3135 #[serde(rename = "Type")]
3137 pub type_: String,
3138}
3139
3140#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3142pub struct ResourceDetails {
3143 #[serde(rename = "AwsAutoScalingAutoScalingGroup")]
3145 #[serde(skip_serializing_if = "Option::is_none")]
3146 pub aws_auto_scaling_auto_scaling_group: Option<AwsAutoScalingAutoScalingGroupDetails>,
3147 #[serde(rename = "AwsCloudFrontDistribution")]
3149 #[serde(skip_serializing_if = "Option::is_none")]
3150 pub aws_cloud_front_distribution: Option<AwsCloudFrontDistributionDetails>,
3151 #[serde(rename = "AwsCodeBuildProject")]
3153 #[serde(skip_serializing_if = "Option::is_none")]
3154 pub aws_code_build_project: Option<AwsCodeBuildProjectDetails>,
3155 #[serde(rename = "AwsEc2Instance")]
3157 #[serde(skip_serializing_if = "Option::is_none")]
3158 pub aws_ec_2_instance: Option<AwsEc2InstanceDetails>,
3159 #[serde(rename = "AwsEc2NetworkInterface")]
3161 #[serde(skip_serializing_if = "Option::is_none")]
3162 pub aws_ec_2_network_interface: Option<AwsEc2NetworkInterfaceDetails>,
3163 #[serde(rename = "AwsEc2SecurityGroup")]
3165 #[serde(skip_serializing_if = "Option::is_none")]
3166 pub aws_ec_2_security_group: Option<AwsEc2SecurityGroupDetails>,
3167 #[serde(rename = "AwsEc2Volume")]
3169 #[serde(skip_serializing_if = "Option::is_none")]
3170 pub aws_ec_2_volume: Option<AwsEc2VolumeDetails>,
3171 #[serde(rename = "AwsEc2Vpc")]
3173 #[serde(skip_serializing_if = "Option::is_none")]
3174 pub aws_ec_2_vpc: Option<AwsEc2VpcDetails>,
3175 #[serde(rename = "AwsElasticsearchDomain")]
3177 #[serde(skip_serializing_if = "Option::is_none")]
3178 pub aws_elasticsearch_domain: Option<AwsElasticsearchDomainDetails>,
3179 #[serde(rename = "AwsElbv2LoadBalancer")]
3181 #[serde(skip_serializing_if = "Option::is_none")]
3182 pub aws_elbv_2_load_balancer: Option<AwsElbv2LoadBalancerDetails>,
3183 #[serde(rename = "AwsIamAccessKey")]
3185 #[serde(skip_serializing_if = "Option::is_none")]
3186 pub aws_iam_access_key: Option<AwsIamAccessKeyDetails>,
3187 #[serde(rename = "AwsIamRole")]
3189 #[serde(skip_serializing_if = "Option::is_none")]
3190 pub aws_iam_role: Option<AwsIamRoleDetails>,
3191 #[serde(rename = "AwsKmsKey")]
3193 #[serde(skip_serializing_if = "Option::is_none")]
3194 pub aws_kms_key: Option<AwsKmsKeyDetails>,
3195 #[serde(rename = "AwsLambdaFunction")]
3197 #[serde(skip_serializing_if = "Option::is_none")]
3198 pub aws_lambda_function: Option<AwsLambdaFunctionDetails>,
3199 #[serde(rename = "AwsLambdaLayerVersion")]
3201 #[serde(skip_serializing_if = "Option::is_none")]
3202 pub aws_lambda_layer_version: Option<AwsLambdaLayerVersionDetails>,
3203 #[serde(rename = "AwsRdsDbInstance")]
3205 #[serde(skip_serializing_if = "Option::is_none")]
3206 pub aws_rds_db_instance: Option<AwsRdsDbInstanceDetails>,
3207 #[serde(rename = "AwsS3Bucket")]
3209 #[serde(skip_serializing_if = "Option::is_none")]
3210 pub aws_s3_bucket: Option<AwsS3BucketDetails>,
3211 #[serde(rename = "AwsS3Object")]
3213 #[serde(skip_serializing_if = "Option::is_none")]
3214 pub aws_s3_object: Option<AwsS3ObjectDetails>,
3215 #[serde(rename = "AwsSnsTopic")]
3217 #[serde(skip_serializing_if = "Option::is_none")]
3218 pub aws_sns_topic: Option<AwsSnsTopicDetails>,
3219 #[serde(rename = "AwsSqsQueue")]
3221 #[serde(skip_serializing_if = "Option::is_none")]
3222 pub aws_sqs_queue: Option<AwsSqsQueueDetails>,
3223 #[serde(rename = "AwsWafWebAcl")]
3225 #[serde(skip_serializing_if = "Option::is_none")]
3226 pub aws_waf_web_acl: Option<AwsWafWebAclDetails>,
3227 #[serde(rename = "Container")]
3229 #[serde(skip_serializing_if = "Option::is_none")]
3230 pub container: Option<ContainerDetails>,
3231 #[serde(rename = "Other")]
3233 #[serde(skip_serializing_if = "Option::is_none")]
3234 pub other: Option<::std::collections::HashMap<String, String>>,
3235}
3236
3237#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3239#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3240pub struct SecurityHubResult {
3241 #[serde(rename = "AccountId")]
3243 #[serde(skip_serializing_if = "Option::is_none")]
3244 pub account_id: Option<String>,
3245 #[serde(rename = "ProcessingResult")]
3247 #[serde(skip_serializing_if = "Option::is_none")]
3248 pub processing_result: Option<String>,
3249}
3250
3251#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3253pub struct Severity {
3254 #[serde(rename = "Label")]
3256 #[serde(skip_serializing_if = "Option::is_none")]
3257 pub label: Option<String>,
3258 #[serde(rename = "Normalized")]
3260 #[serde(skip_serializing_if = "Option::is_none")]
3261 pub normalized: Option<i64>,
3262 #[serde(rename = "Original")]
3264 #[serde(skip_serializing_if = "Option::is_none")]
3265 pub original: Option<String>,
3266 #[serde(rename = "Product")]
3268 #[serde(skip_serializing_if = "Option::is_none")]
3269 pub product: Option<f64>,
3270}
3271
3272#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3274#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3275pub struct SeverityUpdate {
3276 #[serde(rename = "Label")]
3278 #[serde(skip_serializing_if = "Option::is_none")]
3279 pub label: Option<String>,
3280 #[serde(rename = "Normalized")]
3282 #[serde(skip_serializing_if = "Option::is_none")]
3283 pub normalized: Option<i64>,
3284 #[serde(rename = "Product")]
3286 #[serde(skip_serializing_if = "Option::is_none")]
3287 pub product: Option<f64>,
3288}
3289
3290#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3292pub struct SoftwarePackage {
3293 #[serde(rename = "Architecture")]
3295 #[serde(skip_serializing_if = "Option::is_none")]
3296 pub architecture: Option<String>,
3297 #[serde(rename = "Epoch")]
3299 #[serde(skip_serializing_if = "Option::is_none")]
3300 pub epoch: Option<String>,
3301 #[serde(rename = "Name")]
3303 #[serde(skip_serializing_if = "Option::is_none")]
3304 pub name: Option<String>,
3305 #[serde(rename = "Release")]
3307 #[serde(skip_serializing_if = "Option::is_none")]
3308 pub release: Option<String>,
3309 #[serde(rename = "Version")]
3311 #[serde(skip_serializing_if = "Option::is_none")]
3312 pub version: Option<String>,
3313}
3314
3315#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3317#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3318pub struct SortCriterion {
3319 #[serde(rename = "Field")]
3321 #[serde(skip_serializing_if = "Option::is_none")]
3322 pub field: Option<String>,
3323 #[serde(rename = "SortOrder")]
3325 #[serde(skip_serializing_if = "Option::is_none")]
3326 pub sort_order: Option<String>,
3327}
3328
3329#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3331#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3332pub struct Standard {
3333 #[serde(rename = "Description")]
3335 #[serde(skip_serializing_if = "Option::is_none")]
3336 pub description: Option<String>,
3337 #[serde(rename = "EnabledByDefault")]
3339 #[serde(skip_serializing_if = "Option::is_none")]
3340 pub enabled_by_default: Option<bool>,
3341 #[serde(rename = "Name")]
3343 #[serde(skip_serializing_if = "Option::is_none")]
3344 pub name: Option<String>,
3345 #[serde(rename = "StandardsArn")]
3347 #[serde(skip_serializing_if = "Option::is_none")]
3348 pub standards_arn: Option<String>,
3349}
3350
3351#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3353#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3354pub struct StandardsControl {
3355 #[serde(rename = "ControlId")]
3357 #[serde(skip_serializing_if = "Option::is_none")]
3358 pub control_id: Option<String>,
3359 #[serde(rename = "ControlStatus")]
3361 #[serde(skip_serializing_if = "Option::is_none")]
3362 pub control_status: Option<String>,
3363 #[serde(rename = "ControlStatusUpdatedAt")]
3365 #[serde(skip_serializing_if = "Option::is_none")]
3366 pub control_status_updated_at: Option<f64>,
3367 #[serde(rename = "Description")]
3369 #[serde(skip_serializing_if = "Option::is_none")]
3370 pub description: Option<String>,
3371 #[serde(rename = "DisabledReason")]
3373 #[serde(skip_serializing_if = "Option::is_none")]
3374 pub disabled_reason: Option<String>,
3375 #[serde(rename = "RelatedRequirements")]
3377 #[serde(skip_serializing_if = "Option::is_none")]
3378 pub related_requirements: Option<Vec<String>>,
3379 #[serde(rename = "RemediationUrl")]
3381 #[serde(skip_serializing_if = "Option::is_none")]
3382 pub remediation_url: Option<String>,
3383 #[serde(rename = "SeverityRating")]
3385 #[serde(skip_serializing_if = "Option::is_none")]
3386 pub severity_rating: Option<String>,
3387 #[serde(rename = "StandardsControlArn")]
3389 #[serde(skip_serializing_if = "Option::is_none")]
3390 pub standards_control_arn: Option<String>,
3391 #[serde(rename = "Title")]
3393 #[serde(skip_serializing_if = "Option::is_none")]
3394 pub title: Option<String>,
3395}
3396
3397#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3399#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3400pub struct StandardsSubscription {
3401 #[serde(rename = "StandardsArn")]
3403 pub standards_arn: String,
3404 #[serde(rename = "StandardsInput")]
3406 pub standards_input: ::std::collections::HashMap<String, String>,
3407 #[serde(rename = "StandardsStatus")]
3409 pub standards_status: String,
3410 #[serde(rename = "StandardsSubscriptionArn")]
3412 pub standards_subscription_arn: String,
3413}
3414
3415#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3417#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3418pub struct StandardsSubscriptionRequest {
3419 #[serde(rename = "StandardsArn")]
3421 pub standards_arn: String,
3422 #[serde(rename = "StandardsInput")]
3424 #[serde(skip_serializing_if = "Option::is_none")]
3425 pub standards_input: Option<::std::collections::HashMap<String, String>>,
3426}
3427
3428#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3430pub struct StatusReason {
3431 #[serde(rename = "Description")]
3433 #[serde(skip_serializing_if = "Option::is_none")]
3434 pub description: Option<String>,
3435 #[serde(rename = "ReasonCode")]
3437 pub reason_code: String,
3438}
3439
3440#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3442pub struct StringFilter {
3443 #[serde(rename = "Comparison")]
3445 #[serde(skip_serializing_if = "Option::is_none")]
3446 pub comparison: Option<String>,
3447 #[serde(rename = "Value")]
3449 #[serde(skip_serializing_if = "Option::is_none")]
3450 pub value: Option<String>,
3451}
3452
3453#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3454#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3455pub struct TagResourceRequest {
3456 #[serde(rename = "ResourceArn")]
3458 pub resource_arn: String,
3459 #[serde(rename = "Tags")]
3461 pub tags: ::std::collections::HashMap<String, String>,
3462}
3463
3464#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3465#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3466pub struct TagResourceResponse {}
3467
3468#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3470pub struct ThreatIntelIndicator {
3471 #[serde(rename = "Category")]
3473 #[serde(skip_serializing_if = "Option::is_none")]
3474 pub category: Option<String>,
3475 #[serde(rename = "LastObservedAt")]
3477 #[serde(skip_serializing_if = "Option::is_none")]
3478 pub last_observed_at: Option<String>,
3479 #[serde(rename = "Source")]
3481 #[serde(skip_serializing_if = "Option::is_none")]
3482 pub source: Option<String>,
3483 #[serde(rename = "SourceUrl")]
3485 #[serde(skip_serializing_if = "Option::is_none")]
3486 pub source_url: Option<String>,
3487 #[serde(rename = "Type")]
3489 #[serde(skip_serializing_if = "Option::is_none")]
3490 pub type_: Option<String>,
3491 #[serde(rename = "Value")]
3493 #[serde(skip_serializing_if = "Option::is_none")]
3494 pub value: Option<String>,
3495}
3496
3497#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3498#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3499pub struct UntagResourceRequest {
3500 #[serde(rename = "ResourceArn")]
3502 pub resource_arn: String,
3503 #[serde(rename = "TagKeys")]
3505 pub tag_keys: Vec<String>,
3506}
3507
3508#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3509#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3510pub struct UntagResourceResponse {}
3511
3512#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3513#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3514pub struct UpdateActionTargetRequest {
3515 #[serde(rename = "ActionTargetArn")]
3517 pub action_target_arn: String,
3518 #[serde(rename = "Description")]
3520 #[serde(skip_serializing_if = "Option::is_none")]
3521 pub description: Option<String>,
3522 #[serde(rename = "Name")]
3524 #[serde(skip_serializing_if = "Option::is_none")]
3525 pub name: Option<String>,
3526}
3527
3528#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3529#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3530pub struct UpdateActionTargetResponse {}
3531
3532#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3533#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3534pub struct UpdateFindingsRequest {
3535 #[serde(rename = "Filters")]
3537 pub filters: AwsSecurityFindingFilters,
3538 #[serde(rename = "Note")]
3540 #[serde(skip_serializing_if = "Option::is_none")]
3541 pub note: Option<NoteUpdate>,
3542 #[serde(rename = "RecordState")]
3544 #[serde(skip_serializing_if = "Option::is_none")]
3545 pub record_state: Option<String>,
3546}
3547
3548#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3549#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3550pub struct UpdateFindingsResponse {}
3551
3552#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3553#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3554pub struct UpdateInsightRequest {
3555 #[serde(rename = "Filters")]
3557 #[serde(skip_serializing_if = "Option::is_none")]
3558 pub filters: Option<AwsSecurityFindingFilters>,
3559 #[serde(rename = "GroupByAttribute")]
3561 #[serde(skip_serializing_if = "Option::is_none")]
3562 pub group_by_attribute: Option<String>,
3563 #[serde(rename = "InsightArn")]
3565 pub insight_arn: String,
3566 #[serde(rename = "Name")]
3568 #[serde(skip_serializing_if = "Option::is_none")]
3569 pub name: Option<String>,
3570}
3571
3572#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3573#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3574pub struct UpdateInsightResponse {}
3575
3576#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3577#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3578pub struct UpdateStandardsControlRequest {
3579 #[serde(rename = "ControlStatus")]
3581 #[serde(skip_serializing_if = "Option::is_none")]
3582 pub control_status: Option<String>,
3583 #[serde(rename = "DisabledReason")]
3585 #[serde(skip_serializing_if = "Option::is_none")]
3586 pub disabled_reason: Option<String>,
3587 #[serde(rename = "StandardsControlArn")]
3589 pub standards_control_arn: String,
3590}
3591
3592#[derive(Clone, Debug, Default, Deserialize, PartialEq)]
3593#[cfg_attr(any(test, feature = "serialize_structs"), derive(Serialize))]
3594pub struct UpdateStandardsControlResponse {}
3595
3596#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3598pub struct Vulnerability {
3599 #[serde(rename = "Cvss")]
3601 #[serde(skip_serializing_if = "Option::is_none")]
3602 pub cvss: Option<Vec<Cvss>>,
3603 #[serde(rename = "Id")]
3605 pub id: String,
3606 #[serde(rename = "ReferenceUrls")]
3608 #[serde(skip_serializing_if = "Option::is_none")]
3609 pub reference_urls: Option<Vec<String>>,
3610 #[serde(rename = "RelatedVulnerabilities")]
3612 #[serde(skip_serializing_if = "Option::is_none")]
3613 pub related_vulnerabilities: Option<Vec<String>>,
3614 #[serde(rename = "Vendor")]
3616 #[serde(skip_serializing_if = "Option::is_none")]
3617 pub vendor: Option<VulnerabilityVendor>,
3618 #[serde(rename = "VulnerablePackages")]
3620 #[serde(skip_serializing_if = "Option::is_none")]
3621 pub vulnerable_packages: Option<Vec<SoftwarePackage>>,
3622}
3623
3624#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3626pub struct VulnerabilityVendor {
3627 #[serde(rename = "Name")]
3629 pub name: String,
3630 #[serde(rename = "Url")]
3632 #[serde(skip_serializing_if = "Option::is_none")]
3633 pub url: Option<String>,
3634 #[serde(rename = "VendorCreatedAt")]
3636 #[serde(skip_serializing_if = "Option::is_none")]
3637 pub vendor_created_at: Option<String>,
3638 #[serde(rename = "VendorSeverity")]
3640 #[serde(skip_serializing_if = "Option::is_none")]
3641 pub vendor_severity: Option<String>,
3642 #[serde(rename = "VendorUpdatedAt")]
3644 #[serde(skip_serializing_if = "Option::is_none")]
3645 pub vendor_updated_at: Option<String>,
3646}
3647
3648#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3650pub struct WafAction {
3651 #[serde(rename = "Type")]
3653 #[serde(skip_serializing_if = "Option::is_none")]
3654 pub type_: Option<String>,
3655}
3656
3657#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3659pub struct WafExcludedRule {
3660 #[serde(rename = "RuleId")]
3662 #[serde(skip_serializing_if = "Option::is_none")]
3663 pub rule_id: Option<String>,
3664}
3665
3666#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3668pub struct WafOverrideAction {
3669 #[serde(rename = "Type")]
3671 #[serde(skip_serializing_if = "Option::is_none")]
3672 pub type_: Option<String>,
3673}
3674
3675#[derive(Clone, Debug, Default, Deserialize, PartialEq, Serialize)]
3677pub struct Workflow {
3678 #[serde(rename = "Status")]
3680 #[serde(skip_serializing_if = "Option::is_none")]
3681 pub status: Option<String>,
3682}
3683
3684#[derive(Clone, Debug, Default, PartialEq, Serialize)]
3686#[cfg_attr(feature = "deserialize_structs", derive(Deserialize))]
3687pub struct WorkflowUpdate {
3688 #[serde(rename = "Status")]
3690 #[serde(skip_serializing_if = "Option::is_none")]
3691 pub status: Option<String>,
3692}
3693
3694#[derive(Debug, PartialEq)]
3696pub enum AcceptInvitationError {
3697 Internal(String),
3699 InvalidAccess(String),
3701 InvalidInput(String),
3703 LimitExceeded(String),
3705 ResourceNotFound(String),
3707}
3708
3709impl AcceptInvitationError {
3710 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<AcceptInvitationError> {
3711 if let Some(err) = proto::json::Error::parse_rest(&res) {
3712 match err.typ.as_str() {
3713 "InternalException" => {
3714 return RusotoError::Service(AcceptInvitationError::Internal(err.msg))
3715 }
3716 "InvalidAccessException" => {
3717 return RusotoError::Service(AcceptInvitationError::InvalidAccess(err.msg))
3718 }
3719 "InvalidInputException" => {
3720 return RusotoError::Service(AcceptInvitationError::InvalidInput(err.msg))
3721 }
3722 "LimitExceededException" => {
3723 return RusotoError::Service(AcceptInvitationError::LimitExceeded(err.msg))
3724 }
3725 "ResourceNotFoundException" => {
3726 return RusotoError::Service(AcceptInvitationError::ResourceNotFound(err.msg))
3727 }
3728 "ValidationException" => return RusotoError::Validation(err.msg),
3729 _ => {}
3730 }
3731 }
3732 RusotoError::Unknown(res)
3733 }
3734}
3735impl fmt::Display for AcceptInvitationError {
3736 #[allow(unused_variables)]
3737 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3738 match *self {
3739 AcceptInvitationError::Internal(ref cause) => write!(f, "{}", cause),
3740 AcceptInvitationError::InvalidAccess(ref cause) => write!(f, "{}", cause),
3741 AcceptInvitationError::InvalidInput(ref cause) => write!(f, "{}", cause),
3742 AcceptInvitationError::LimitExceeded(ref cause) => write!(f, "{}", cause),
3743 AcceptInvitationError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
3744 }
3745 }
3746}
3747impl Error for AcceptInvitationError {}
3748#[derive(Debug, PartialEq)]
3750pub enum BatchDisableStandardsError {
3751 Internal(String),
3753 InvalidAccess(String),
3755 InvalidInput(String),
3757 LimitExceeded(String),
3759}
3760
3761impl BatchDisableStandardsError {
3762 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<BatchDisableStandardsError> {
3763 if let Some(err) = proto::json::Error::parse_rest(&res) {
3764 match err.typ.as_str() {
3765 "InternalException" => {
3766 return RusotoError::Service(BatchDisableStandardsError::Internal(err.msg))
3767 }
3768 "InvalidAccessException" => {
3769 return RusotoError::Service(BatchDisableStandardsError::InvalidAccess(err.msg))
3770 }
3771 "InvalidInputException" => {
3772 return RusotoError::Service(BatchDisableStandardsError::InvalidInput(err.msg))
3773 }
3774 "LimitExceededException" => {
3775 return RusotoError::Service(BatchDisableStandardsError::LimitExceeded(err.msg))
3776 }
3777 "ValidationException" => return RusotoError::Validation(err.msg),
3778 _ => {}
3779 }
3780 }
3781 RusotoError::Unknown(res)
3782 }
3783}
3784impl fmt::Display for BatchDisableStandardsError {
3785 #[allow(unused_variables)]
3786 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3787 match *self {
3788 BatchDisableStandardsError::Internal(ref cause) => write!(f, "{}", cause),
3789 BatchDisableStandardsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
3790 BatchDisableStandardsError::InvalidInput(ref cause) => write!(f, "{}", cause),
3791 BatchDisableStandardsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
3792 }
3793 }
3794}
3795impl Error for BatchDisableStandardsError {}
3796#[derive(Debug, PartialEq)]
3798pub enum BatchEnableStandardsError {
3799 Internal(String),
3801 InvalidAccess(String),
3803 InvalidInput(String),
3805 LimitExceeded(String),
3807}
3808
3809impl BatchEnableStandardsError {
3810 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<BatchEnableStandardsError> {
3811 if let Some(err) = proto::json::Error::parse_rest(&res) {
3812 match err.typ.as_str() {
3813 "InternalException" => {
3814 return RusotoError::Service(BatchEnableStandardsError::Internal(err.msg))
3815 }
3816 "InvalidAccessException" => {
3817 return RusotoError::Service(BatchEnableStandardsError::InvalidAccess(err.msg))
3818 }
3819 "InvalidInputException" => {
3820 return RusotoError::Service(BatchEnableStandardsError::InvalidInput(err.msg))
3821 }
3822 "LimitExceededException" => {
3823 return RusotoError::Service(BatchEnableStandardsError::LimitExceeded(err.msg))
3824 }
3825 "ValidationException" => return RusotoError::Validation(err.msg),
3826 _ => {}
3827 }
3828 }
3829 RusotoError::Unknown(res)
3830 }
3831}
3832impl fmt::Display for BatchEnableStandardsError {
3833 #[allow(unused_variables)]
3834 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3835 match *self {
3836 BatchEnableStandardsError::Internal(ref cause) => write!(f, "{}", cause),
3837 BatchEnableStandardsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
3838 BatchEnableStandardsError::InvalidInput(ref cause) => write!(f, "{}", cause),
3839 BatchEnableStandardsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
3840 }
3841 }
3842}
3843impl Error for BatchEnableStandardsError {}
3844#[derive(Debug, PartialEq)]
3846pub enum BatchImportFindingsError {
3847 Internal(String),
3849 InvalidAccess(String),
3851 InvalidInput(String),
3853 LimitExceeded(String),
3855}
3856
3857impl BatchImportFindingsError {
3858 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<BatchImportFindingsError> {
3859 if let Some(err) = proto::json::Error::parse_rest(&res) {
3860 match err.typ.as_str() {
3861 "InternalException" => {
3862 return RusotoError::Service(BatchImportFindingsError::Internal(err.msg))
3863 }
3864 "InvalidAccessException" => {
3865 return RusotoError::Service(BatchImportFindingsError::InvalidAccess(err.msg))
3866 }
3867 "InvalidInputException" => {
3868 return RusotoError::Service(BatchImportFindingsError::InvalidInput(err.msg))
3869 }
3870 "LimitExceededException" => {
3871 return RusotoError::Service(BatchImportFindingsError::LimitExceeded(err.msg))
3872 }
3873 "ValidationException" => return RusotoError::Validation(err.msg),
3874 _ => {}
3875 }
3876 }
3877 RusotoError::Unknown(res)
3878 }
3879}
3880impl fmt::Display for BatchImportFindingsError {
3881 #[allow(unused_variables)]
3882 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3883 match *self {
3884 BatchImportFindingsError::Internal(ref cause) => write!(f, "{}", cause),
3885 BatchImportFindingsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
3886 BatchImportFindingsError::InvalidInput(ref cause) => write!(f, "{}", cause),
3887 BatchImportFindingsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
3888 }
3889 }
3890}
3891impl Error for BatchImportFindingsError {}
3892#[derive(Debug, PartialEq)]
3894pub enum BatchUpdateFindingsError {
3895 Internal(String),
3897 InvalidAccess(String),
3899 InvalidInput(String),
3901 LimitExceeded(String),
3903}
3904
3905impl BatchUpdateFindingsError {
3906 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<BatchUpdateFindingsError> {
3907 if let Some(err) = proto::json::Error::parse_rest(&res) {
3908 match err.typ.as_str() {
3909 "InternalException" => {
3910 return RusotoError::Service(BatchUpdateFindingsError::Internal(err.msg))
3911 }
3912 "InvalidAccessException" => {
3913 return RusotoError::Service(BatchUpdateFindingsError::InvalidAccess(err.msg))
3914 }
3915 "InvalidInputException" => {
3916 return RusotoError::Service(BatchUpdateFindingsError::InvalidInput(err.msg))
3917 }
3918 "LimitExceededException" => {
3919 return RusotoError::Service(BatchUpdateFindingsError::LimitExceeded(err.msg))
3920 }
3921 "ValidationException" => return RusotoError::Validation(err.msg),
3922 _ => {}
3923 }
3924 }
3925 RusotoError::Unknown(res)
3926 }
3927}
3928impl fmt::Display for BatchUpdateFindingsError {
3929 #[allow(unused_variables)]
3930 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3931 match *self {
3932 BatchUpdateFindingsError::Internal(ref cause) => write!(f, "{}", cause),
3933 BatchUpdateFindingsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
3934 BatchUpdateFindingsError::InvalidInput(ref cause) => write!(f, "{}", cause),
3935 BatchUpdateFindingsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
3936 }
3937 }
3938}
3939impl Error for BatchUpdateFindingsError {}
3940#[derive(Debug, PartialEq)]
3942pub enum CreateActionTargetError {
3943 Internal(String),
3945 InvalidAccess(String),
3947 InvalidInput(String),
3949 LimitExceeded(String),
3951 ResourceConflict(String),
3953}
3954
3955impl CreateActionTargetError {
3956 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateActionTargetError> {
3957 if let Some(err) = proto::json::Error::parse_rest(&res) {
3958 match err.typ.as_str() {
3959 "InternalException" => {
3960 return RusotoError::Service(CreateActionTargetError::Internal(err.msg))
3961 }
3962 "InvalidAccessException" => {
3963 return RusotoError::Service(CreateActionTargetError::InvalidAccess(err.msg))
3964 }
3965 "InvalidInputException" => {
3966 return RusotoError::Service(CreateActionTargetError::InvalidInput(err.msg))
3967 }
3968 "LimitExceededException" => {
3969 return RusotoError::Service(CreateActionTargetError::LimitExceeded(err.msg))
3970 }
3971 "ResourceConflictException" => {
3972 return RusotoError::Service(CreateActionTargetError::ResourceConflict(err.msg))
3973 }
3974 "ValidationException" => return RusotoError::Validation(err.msg),
3975 _ => {}
3976 }
3977 }
3978 RusotoError::Unknown(res)
3979 }
3980}
3981impl fmt::Display for CreateActionTargetError {
3982 #[allow(unused_variables)]
3983 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
3984 match *self {
3985 CreateActionTargetError::Internal(ref cause) => write!(f, "{}", cause),
3986 CreateActionTargetError::InvalidAccess(ref cause) => write!(f, "{}", cause),
3987 CreateActionTargetError::InvalidInput(ref cause) => write!(f, "{}", cause),
3988 CreateActionTargetError::LimitExceeded(ref cause) => write!(f, "{}", cause),
3989 CreateActionTargetError::ResourceConflict(ref cause) => write!(f, "{}", cause),
3990 }
3991 }
3992}
3993impl Error for CreateActionTargetError {}
3994#[derive(Debug, PartialEq)]
3996pub enum CreateInsightError {
3997 Internal(String),
3999 InvalidAccess(String),
4001 InvalidInput(String),
4003 LimitExceeded(String),
4005 ResourceConflict(String),
4007}
4008
4009impl CreateInsightError {
4010 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateInsightError> {
4011 if let Some(err) = proto::json::Error::parse_rest(&res) {
4012 match err.typ.as_str() {
4013 "InternalException" => {
4014 return RusotoError::Service(CreateInsightError::Internal(err.msg))
4015 }
4016 "InvalidAccessException" => {
4017 return RusotoError::Service(CreateInsightError::InvalidAccess(err.msg))
4018 }
4019 "InvalidInputException" => {
4020 return RusotoError::Service(CreateInsightError::InvalidInput(err.msg))
4021 }
4022 "LimitExceededException" => {
4023 return RusotoError::Service(CreateInsightError::LimitExceeded(err.msg))
4024 }
4025 "ResourceConflictException" => {
4026 return RusotoError::Service(CreateInsightError::ResourceConflict(err.msg))
4027 }
4028 "ValidationException" => return RusotoError::Validation(err.msg),
4029 _ => {}
4030 }
4031 }
4032 RusotoError::Unknown(res)
4033 }
4034}
4035impl fmt::Display for CreateInsightError {
4036 #[allow(unused_variables)]
4037 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4038 match *self {
4039 CreateInsightError::Internal(ref cause) => write!(f, "{}", cause),
4040 CreateInsightError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4041 CreateInsightError::InvalidInput(ref cause) => write!(f, "{}", cause),
4042 CreateInsightError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4043 CreateInsightError::ResourceConflict(ref cause) => write!(f, "{}", cause),
4044 }
4045 }
4046}
4047impl Error for CreateInsightError {}
4048#[derive(Debug, PartialEq)]
4050pub enum CreateMembersError {
4051 Internal(String),
4053 InvalidAccess(String),
4055 InvalidInput(String),
4057 LimitExceeded(String),
4059 ResourceConflict(String),
4061}
4062
4063impl CreateMembersError {
4064 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<CreateMembersError> {
4065 if let Some(err) = proto::json::Error::parse_rest(&res) {
4066 match err.typ.as_str() {
4067 "InternalException" => {
4068 return RusotoError::Service(CreateMembersError::Internal(err.msg))
4069 }
4070 "InvalidAccessException" => {
4071 return RusotoError::Service(CreateMembersError::InvalidAccess(err.msg))
4072 }
4073 "InvalidInputException" => {
4074 return RusotoError::Service(CreateMembersError::InvalidInput(err.msg))
4075 }
4076 "LimitExceededException" => {
4077 return RusotoError::Service(CreateMembersError::LimitExceeded(err.msg))
4078 }
4079 "ResourceConflictException" => {
4080 return RusotoError::Service(CreateMembersError::ResourceConflict(err.msg))
4081 }
4082 "ValidationException" => return RusotoError::Validation(err.msg),
4083 _ => {}
4084 }
4085 }
4086 RusotoError::Unknown(res)
4087 }
4088}
4089impl fmt::Display for CreateMembersError {
4090 #[allow(unused_variables)]
4091 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4092 match *self {
4093 CreateMembersError::Internal(ref cause) => write!(f, "{}", cause),
4094 CreateMembersError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4095 CreateMembersError::InvalidInput(ref cause) => write!(f, "{}", cause),
4096 CreateMembersError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4097 CreateMembersError::ResourceConflict(ref cause) => write!(f, "{}", cause),
4098 }
4099 }
4100}
4101impl Error for CreateMembersError {}
4102#[derive(Debug, PartialEq)]
4104pub enum DeclineInvitationsError {
4105 Internal(String),
4107 InvalidAccess(String),
4109 InvalidInput(String),
4111 ResourceNotFound(String),
4113}
4114
4115impl DeclineInvitationsError {
4116 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeclineInvitationsError> {
4117 if let Some(err) = proto::json::Error::parse_rest(&res) {
4118 match err.typ.as_str() {
4119 "InternalException" => {
4120 return RusotoError::Service(DeclineInvitationsError::Internal(err.msg))
4121 }
4122 "InvalidAccessException" => {
4123 return RusotoError::Service(DeclineInvitationsError::InvalidAccess(err.msg))
4124 }
4125 "InvalidInputException" => {
4126 return RusotoError::Service(DeclineInvitationsError::InvalidInput(err.msg))
4127 }
4128 "ResourceNotFoundException" => {
4129 return RusotoError::Service(DeclineInvitationsError::ResourceNotFound(err.msg))
4130 }
4131 "ValidationException" => return RusotoError::Validation(err.msg),
4132 _ => {}
4133 }
4134 }
4135 RusotoError::Unknown(res)
4136 }
4137}
4138impl fmt::Display for DeclineInvitationsError {
4139 #[allow(unused_variables)]
4140 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4141 match *self {
4142 DeclineInvitationsError::Internal(ref cause) => write!(f, "{}", cause),
4143 DeclineInvitationsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4144 DeclineInvitationsError::InvalidInput(ref cause) => write!(f, "{}", cause),
4145 DeclineInvitationsError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4146 }
4147 }
4148}
4149impl Error for DeclineInvitationsError {}
4150#[derive(Debug, PartialEq)]
4152pub enum DeleteActionTargetError {
4153 Internal(String),
4155 InvalidAccess(String),
4157 InvalidInput(String),
4159 ResourceNotFound(String),
4161}
4162
4163impl DeleteActionTargetError {
4164 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteActionTargetError> {
4165 if let Some(err) = proto::json::Error::parse_rest(&res) {
4166 match err.typ.as_str() {
4167 "InternalException" => {
4168 return RusotoError::Service(DeleteActionTargetError::Internal(err.msg))
4169 }
4170 "InvalidAccessException" => {
4171 return RusotoError::Service(DeleteActionTargetError::InvalidAccess(err.msg))
4172 }
4173 "InvalidInputException" => {
4174 return RusotoError::Service(DeleteActionTargetError::InvalidInput(err.msg))
4175 }
4176 "ResourceNotFoundException" => {
4177 return RusotoError::Service(DeleteActionTargetError::ResourceNotFound(err.msg))
4178 }
4179 "ValidationException" => return RusotoError::Validation(err.msg),
4180 _ => {}
4181 }
4182 }
4183 RusotoError::Unknown(res)
4184 }
4185}
4186impl fmt::Display for DeleteActionTargetError {
4187 #[allow(unused_variables)]
4188 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4189 match *self {
4190 DeleteActionTargetError::Internal(ref cause) => write!(f, "{}", cause),
4191 DeleteActionTargetError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4192 DeleteActionTargetError::InvalidInput(ref cause) => write!(f, "{}", cause),
4193 DeleteActionTargetError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4194 }
4195 }
4196}
4197impl Error for DeleteActionTargetError {}
4198#[derive(Debug, PartialEq)]
4200pub enum DeleteInsightError {
4201 Internal(String),
4203 InvalidAccess(String),
4205 InvalidInput(String),
4207 LimitExceeded(String),
4209 ResourceNotFound(String),
4211}
4212
4213impl DeleteInsightError {
4214 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteInsightError> {
4215 if let Some(err) = proto::json::Error::parse_rest(&res) {
4216 match err.typ.as_str() {
4217 "InternalException" => {
4218 return RusotoError::Service(DeleteInsightError::Internal(err.msg))
4219 }
4220 "InvalidAccessException" => {
4221 return RusotoError::Service(DeleteInsightError::InvalidAccess(err.msg))
4222 }
4223 "InvalidInputException" => {
4224 return RusotoError::Service(DeleteInsightError::InvalidInput(err.msg))
4225 }
4226 "LimitExceededException" => {
4227 return RusotoError::Service(DeleteInsightError::LimitExceeded(err.msg))
4228 }
4229 "ResourceNotFoundException" => {
4230 return RusotoError::Service(DeleteInsightError::ResourceNotFound(err.msg))
4231 }
4232 "ValidationException" => return RusotoError::Validation(err.msg),
4233 _ => {}
4234 }
4235 }
4236 RusotoError::Unknown(res)
4237 }
4238}
4239impl fmt::Display for DeleteInsightError {
4240 #[allow(unused_variables)]
4241 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4242 match *self {
4243 DeleteInsightError::Internal(ref cause) => write!(f, "{}", cause),
4244 DeleteInsightError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4245 DeleteInsightError::InvalidInput(ref cause) => write!(f, "{}", cause),
4246 DeleteInsightError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4247 DeleteInsightError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4248 }
4249 }
4250}
4251impl Error for DeleteInsightError {}
4252#[derive(Debug, PartialEq)]
4254pub enum DeleteInvitationsError {
4255 Internal(String),
4257 InvalidAccess(String),
4259 InvalidInput(String),
4261 LimitExceeded(String),
4263 ResourceNotFound(String),
4265}
4266
4267impl DeleteInvitationsError {
4268 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteInvitationsError> {
4269 if let Some(err) = proto::json::Error::parse_rest(&res) {
4270 match err.typ.as_str() {
4271 "InternalException" => {
4272 return RusotoError::Service(DeleteInvitationsError::Internal(err.msg))
4273 }
4274 "InvalidAccessException" => {
4275 return RusotoError::Service(DeleteInvitationsError::InvalidAccess(err.msg))
4276 }
4277 "InvalidInputException" => {
4278 return RusotoError::Service(DeleteInvitationsError::InvalidInput(err.msg))
4279 }
4280 "LimitExceededException" => {
4281 return RusotoError::Service(DeleteInvitationsError::LimitExceeded(err.msg))
4282 }
4283 "ResourceNotFoundException" => {
4284 return RusotoError::Service(DeleteInvitationsError::ResourceNotFound(err.msg))
4285 }
4286 "ValidationException" => return RusotoError::Validation(err.msg),
4287 _ => {}
4288 }
4289 }
4290 RusotoError::Unknown(res)
4291 }
4292}
4293impl fmt::Display for DeleteInvitationsError {
4294 #[allow(unused_variables)]
4295 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4296 match *self {
4297 DeleteInvitationsError::Internal(ref cause) => write!(f, "{}", cause),
4298 DeleteInvitationsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4299 DeleteInvitationsError::InvalidInput(ref cause) => write!(f, "{}", cause),
4300 DeleteInvitationsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4301 DeleteInvitationsError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4302 }
4303 }
4304}
4305impl Error for DeleteInvitationsError {}
4306#[derive(Debug, PartialEq)]
4308pub enum DeleteMembersError {
4309 Internal(String),
4311 InvalidAccess(String),
4313 InvalidInput(String),
4315 LimitExceeded(String),
4317 ResourceNotFound(String),
4319}
4320
4321impl DeleteMembersError {
4322 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DeleteMembersError> {
4323 if let Some(err) = proto::json::Error::parse_rest(&res) {
4324 match err.typ.as_str() {
4325 "InternalException" => {
4326 return RusotoError::Service(DeleteMembersError::Internal(err.msg))
4327 }
4328 "InvalidAccessException" => {
4329 return RusotoError::Service(DeleteMembersError::InvalidAccess(err.msg))
4330 }
4331 "InvalidInputException" => {
4332 return RusotoError::Service(DeleteMembersError::InvalidInput(err.msg))
4333 }
4334 "LimitExceededException" => {
4335 return RusotoError::Service(DeleteMembersError::LimitExceeded(err.msg))
4336 }
4337 "ResourceNotFoundException" => {
4338 return RusotoError::Service(DeleteMembersError::ResourceNotFound(err.msg))
4339 }
4340 "ValidationException" => return RusotoError::Validation(err.msg),
4341 _ => {}
4342 }
4343 }
4344 RusotoError::Unknown(res)
4345 }
4346}
4347impl fmt::Display for DeleteMembersError {
4348 #[allow(unused_variables)]
4349 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4350 match *self {
4351 DeleteMembersError::Internal(ref cause) => write!(f, "{}", cause),
4352 DeleteMembersError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4353 DeleteMembersError::InvalidInput(ref cause) => write!(f, "{}", cause),
4354 DeleteMembersError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4355 DeleteMembersError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4356 }
4357 }
4358}
4359impl Error for DeleteMembersError {}
4360#[derive(Debug, PartialEq)]
4362pub enum DescribeActionTargetsError {
4363 Internal(String),
4365 InvalidAccess(String),
4367 InvalidInput(String),
4369 ResourceNotFound(String),
4371}
4372
4373impl DescribeActionTargetsError {
4374 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeActionTargetsError> {
4375 if let Some(err) = proto::json::Error::parse_rest(&res) {
4376 match err.typ.as_str() {
4377 "InternalException" => {
4378 return RusotoError::Service(DescribeActionTargetsError::Internal(err.msg))
4379 }
4380 "InvalidAccessException" => {
4381 return RusotoError::Service(DescribeActionTargetsError::InvalidAccess(err.msg))
4382 }
4383 "InvalidInputException" => {
4384 return RusotoError::Service(DescribeActionTargetsError::InvalidInput(err.msg))
4385 }
4386 "ResourceNotFoundException" => {
4387 return RusotoError::Service(DescribeActionTargetsError::ResourceNotFound(
4388 err.msg,
4389 ))
4390 }
4391 "ValidationException" => return RusotoError::Validation(err.msg),
4392 _ => {}
4393 }
4394 }
4395 RusotoError::Unknown(res)
4396 }
4397}
4398impl fmt::Display for DescribeActionTargetsError {
4399 #[allow(unused_variables)]
4400 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4401 match *self {
4402 DescribeActionTargetsError::Internal(ref cause) => write!(f, "{}", cause),
4403 DescribeActionTargetsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4404 DescribeActionTargetsError::InvalidInput(ref cause) => write!(f, "{}", cause),
4405 DescribeActionTargetsError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4406 }
4407 }
4408}
4409impl Error for DescribeActionTargetsError {}
4410#[derive(Debug, PartialEq)]
4412pub enum DescribeHubError {
4413 Internal(String),
4415 InvalidAccess(String),
4417 InvalidInput(String),
4419 LimitExceeded(String),
4421 ResourceNotFound(String),
4423}
4424
4425impl DescribeHubError {
4426 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeHubError> {
4427 if let Some(err) = proto::json::Error::parse_rest(&res) {
4428 match err.typ.as_str() {
4429 "InternalException" => {
4430 return RusotoError::Service(DescribeHubError::Internal(err.msg))
4431 }
4432 "InvalidAccessException" => {
4433 return RusotoError::Service(DescribeHubError::InvalidAccess(err.msg))
4434 }
4435 "InvalidInputException" => {
4436 return RusotoError::Service(DescribeHubError::InvalidInput(err.msg))
4437 }
4438 "LimitExceededException" => {
4439 return RusotoError::Service(DescribeHubError::LimitExceeded(err.msg))
4440 }
4441 "ResourceNotFoundException" => {
4442 return RusotoError::Service(DescribeHubError::ResourceNotFound(err.msg))
4443 }
4444 "ValidationException" => return RusotoError::Validation(err.msg),
4445 _ => {}
4446 }
4447 }
4448 RusotoError::Unknown(res)
4449 }
4450}
4451impl fmt::Display for DescribeHubError {
4452 #[allow(unused_variables)]
4453 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4454 match *self {
4455 DescribeHubError::Internal(ref cause) => write!(f, "{}", cause),
4456 DescribeHubError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4457 DescribeHubError::InvalidInput(ref cause) => write!(f, "{}", cause),
4458 DescribeHubError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4459 DescribeHubError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4460 }
4461 }
4462}
4463impl Error for DescribeHubError {}
4464#[derive(Debug, PartialEq)]
4466pub enum DescribeProductsError {
4467 Internal(String),
4469 InvalidAccess(String),
4471 InvalidInput(String),
4473 LimitExceeded(String),
4475}
4476
4477impl DescribeProductsError {
4478 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeProductsError> {
4479 if let Some(err) = proto::json::Error::parse_rest(&res) {
4480 match err.typ.as_str() {
4481 "InternalException" => {
4482 return RusotoError::Service(DescribeProductsError::Internal(err.msg))
4483 }
4484 "InvalidAccessException" => {
4485 return RusotoError::Service(DescribeProductsError::InvalidAccess(err.msg))
4486 }
4487 "InvalidInputException" => {
4488 return RusotoError::Service(DescribeProductsError::InvalidInput(err.msg))
4489 }
4490 "LimitExceededException" => {
4491 return RusotoError::Service(DescribeProductsError::LimitExceeded(err.msg))
4492 }
4493 "ValidationException" => return RusotoError::Validation(err.msg),
4494 _ => {}
4495 }
4496 }
4497 RusotoError::Unknown(res)
4498 }
4499}
4500impl fmt::Display for DescribeProductsError {
4501 #[allow(unused_variables)]
4502 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4503 match *self {
4504 DescribeProductsError::Internal(ref cause) => write!(f, "{}", cause),
4505 DescribeProductsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4506 DescribeProductsError::InvalidInput(ref cause) => write!(f, "{}", cause),
4507 DescribeProductsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4508 }
4509 }
4510}
4511impl Error for DescribeProductsError {}
4512#[derive(Debug, PartialEq)]
4514pub enum DescribeStandardsError {
4515 Internal(String),
4517 InvalidAccess(String),
4519 InvalidInput(String),
4521}
4522
4523impl DescribeStandardsError {
4524 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeStandardsError> {
4525 if let Some(err) = proto::json::Error::parse_rest(&res) {
4526 match err.typ.as_str() {
4527 "InternalException" => {
4528 return RusotoError::Service(DescribeStandardsError::Internal(err.msg))
4529 }
4530 "InvalidAccessException" => {
4531 return RusotoError::Service(DescribeStandardsError::InvalidAccess(err.msg))
4532 }
4533 "InvalidInputException" => {
4534 return RusotoError::Service(DescribeStandardsError::InvalidInput(err.msg))
4535 }
4536 "ValidationException" => return RusotoError::Validation(err.msg),
4537 _ => {}
4538 }
4539 }
4540 RusotoError::Unknown(res)
4541 }
4542}
4543impl fmt::Display for DescribeStandardsError {
4544 #[allow(unused_variables)]
4545 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4546 match *self {
4547 DescribeStandardsError::Internal(ref cause) => write!(f, "{}", cause),
4548 DescribeStandardsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4549 DescribeStandardsError::InvalidInput(ref cause) => write!(f, "{}", cause),
4550 }
4551 }
4552}
4553impl Error for DescribeStandardsError {}
4554#[derive(Debug, PartialEq)]
4556pub enum DescribeStandardsControlsError {
4557 Internal(String),
4559 InvalidAccess(String),
4561 InvalidInput(String),
4563 ResourceNotFound(String),
4565}
4566
4567impl DescribeStandardsControlsError {
4568 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DescribeStandardsControlsError> {
4569 if let Some(err) = proto::json::Error::parse_rest(&res) {
4570 match err.typ.as_str() {
4571 "InternalException" => {
4572 return RusotoError::Service(DescribeStandardsControlsError::Internal(err.msg))
4573 }
4574 "InvalidAccessException" => {
4575 return RusotoError::Service(DescribeStandardsControlsError::InvalidAccess(
4576 err.msg,
4577 ))
4578 }
4579 "InvalidInputException" => {
4580 return RusotoError::Service(DescribeStandardsControlsError::InvalidInput(
4581 err.msg,
4582 ))
4583 }
4584 "ResourceNotFoundException" => {
4585 return RusotoError::Service(DescribeStandardsControlsError::ResourceNotFound(
4586 err.msg,
4587 ))
4588 }
4589 "ValidationException" => return RusotoError::Validation(err.msg),
4590 _ => {}
4591 }
4592 }
4593 RusotoError::Unknown(res)
4594 }
4595}
4596impl fmt::Display for DescribeStandardsControlsError {
4597 #[allow(unused_variables)]
4598 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4599 match *self {
4600 DescribeStandardsControlsError::Internal(ref cause) => write!(f, "{}", cause),
4601 DescribeStandardsControlsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4602 DescribeStandardsControlsError::InvalidInput(ref cause) => write!(f, "{}", cause),
4603 DescribeStandardsControlsError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4604 }
4605 }
4606}
4607impl Error for DescribeStandardsControlsError {}
4608#[derive(Debug, PartialEq)]
4610pub enum DisableImportFindingsForProductError {
4611 Internal(String),
4613 InvalidAccess(String),
4615 InvalidInput(String),
4617 LimitExceeded(String),
4619 ResourceNotFound(String),
4621}
4622
4623impl DisableImportFindingsForProductError {
4624 pub fn from_response(
4625 res: BufferedHttpResponse,
4626 ) -> RusotoError<DisableImportFindingsForProductError> {
4627 if let Some(err) = proto::json::Error::parse_rest(&res) {
4628 match err.typ.as_str() {
4629 "InternalException" => {
4630 return RusotoError::Service(DisableImportFindingsForProductError::Internal(
4631 err.msg,
4632 ))
4633 }
4634 "InvalidAccessException" => {
4635 return RusotoError::Service(
4636 DisableImportFindingsForProductError::InvalidAccess(err.msg),
4637 )
4638 }
4639 "InvalidInputException" => {
4640 return RusotoError::Service(
4641 DisableImportFindingsForProductError::InvalidInput(err.msg),
4642 )
4643 }
4644 "LimitExceededException" => {
4645 return RusotoError::Service(
4646 DisableImportFindingsForProductError::LimitExceeded(err.msg),
4647 )
4648 }
4649 "ResourceNotFoundException" => {
4650 return RusotoError::Service(
4651 DisableImportFindingsForProductError::ResourceNotFound(err.msg),
4652 )
4653 }
4654 "ValidationException" => return RusotoError::Validation(err.msg),
4655 _ => {}
4656 }
4657 }
4658 RusotoError::Unknown(res)
4659 }
4660}
4661impl fmt::Display for DisableImportFindingsForProductError {
4662 #[allow(unused_variables)]
4663 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4664 match *self {
4665 DisableImportFindingsForProductError::Internal(ref cause) => write!(f, "{}", cause),
4666 DisableImportFindingsForProductError::InvalidAccess(ref cause) => {
4667 write!(f, "{}", cause)
4668 }
4669 DisableImportFindingsForProductError::InvalidInput(ref cause) => write!(f, "{}", cause),
4670 DisableImportFindingsForProductError::LimitExceeded(ref cause) => {
4671 write!(f, "{}", cause)
4672 }
4673 DisableImportFindingsForProductError::ResourceNotFound(ref cause) => {
4674 write!(f, "{}", cause)
4675 }
4676 }
4677 }
4678}
4679impl Error for DisableImportFindingsForProductError {}
4680#[derive(Debug, PartialEq)]
4682pub enum DisableSecurityHubError {
4683 Internal(String),
4685 InvalidAccess(String),
4687 LimitExceeded(String),
4689 ResourceNotFound(String),
4691}
4692
4693impl DisableSecurityHubError {
4694 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DisableSecurityHubError> {
4695 if let Some(err) = proto::json::Error::parse_rest(&res) {
4696 match err.typ.as_str() {
4697 "InternalException" => {
4698 return RusotoError::Service(DisableSecurityHubError::Internal(err.msg))
4699 }
4700 "InvalidAccessException" => {
4701 return RusotoError::Service(DisableSecurityHubError::InvalidAccess(err.msg))
4702 }
4703 "LimitExceededException" => {
4704 return RusotoError::Service(DisableSecurityHubError::LimitExceeded(err.msg))
4705 }
4706 "ResourceNotFoundException" => {
4707 return RusotoError::Service(DisableSecurityHubError::ResourceNotFound(err.msg))
4708 }
4709 "ValidationException" => return RusotoError::Validation(err.msg),
4710 _ => {}
4711 }
4712 }
4713 RusotoError::Unknown(res)
4714 }
4715}
4716impl fmt::Display for DisableSecurityHubError {
4717 #[allow(unused_variables)]
4718 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4719 match *self {
4720 DisableSecurityHubError::Internal(ref cause) => write!(f, "{}", cause),
4721 DisableSecurityHubError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4722 DisableSecurityHubError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4723 DisableSecurityHubError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4724 }
4725 }
4726}
4727impl Error for DisableSecurityHubError {}
4728#[derive(Debug, PartialEq)]
4730pub enum DisassociateFromMasterAccountError {
4731 Internal(String),
4733 InvalidAccess(String),
4735 InvalidInput(String),
4737 LimitExceeded(String),
4739 ResourceNotFound(String),
4741}
4742
4743impl DisassociateFromMasterAccountError {
4744 pub fn from_response(
4745 res: BufferedHttpResponse,
4746 ) -> RusotoError<DisassociateFromMasterAccountError> {
4747 if let Some(err) = proto::json::Error::parse_rest(&res) {
4748 match err.typ.as_str() {
4749 "InternalException" => {
4750 return RusotoError::Service(DisassociateFromMasterAccountError::Internal(
4751 err.msg,
4752 ))
4753 }
4754 "InvalidAccessException" => {
4755 return RusotoError::Service(DisassociateFromMasterAccountError::InvalidAccess(
4756 err.msg,
4757 ))
4758 }
4759 "InvalidInputException" => {
4760 return RusotoError::Service(DisassociateFromMasterAccountError::InvalidInput(
4761 err.msg,
4762 ))
4763 }
4764 "LimitExceededException" => {
4765 return RusotoError::Service(DisassociateFromMasterAccountError::LimitExceeded(
4766 err.msg,
4767 ))
4768 }
4769 "ResourceNotFoundException" => {
4770 return RusotoError::Service(
4771 DisassociateFromMasterAccountError::ResourceNotFound(err.msg),
4772 )
4773 }
4774 "ValidationException" => return RusotoError::Validation(err.msg),
4775 _ => {}
4776 }
4777 }
4778 RusotoError::Unknown(res)
4779 }
4780}
4781impl fmt::Display for DisassociateFromMasterAccountError {
4782 #[allow(unused_variables)]
4783 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4784 match *self {
4785 DisassociateFromMasterAccountError::Internal(ref cause) => write!(f, "{}", cause),
4786 DisassociateFromMasterAccountError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4787 DisassociateFromMasterAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
4788 DisassociateFromMasterAccountError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4789 DisassociateFromMasterAccountError::ResourceNotFound(ref cause) => {
4790 write!(f, "{}", cause)
4791 }
4792 }
4793 }
4794}
4795impl Error for DisassociateFromMasterAccountError {}
4796#[derive(Debug, PartialEq)]
4798pub enum DisassociateMembersError {
4799 Internal(String),
4801 InvalidAccess(String),
4803 InvalidInput(String),
4805 LimitExceeded(String),
4807 ResourceNotFound(String),
4809}
4810
4811impl DisassociateMembersError {
4812 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<DisassociateMembersError> {
4813 if let Some(err) = proto::json::Error::parse_rest(&res) {
4814 match err.typ.as_str() {
4815 "InternalException" => {
4816 return RusotoError::Service(DisassociateMembersError::Internal(err.msg))
4817 }
4818 "InvalidAccessException" => {
4819 return RusotoError::Service(DisassociateMembersError::InvalidAccess(err.msg))
4820 }
4821 "InvalidInputException" => {
4822 return RusotoError::Service(DisassociateMembersError::InvalidInput(err.msg))
4823 }
4824 "LimitExceededException" => {
4825 return RusotoError::Service(DisassociateMembersError::LimitExceeded(err.msg))
4826 }
4827 "ResourceNotFoundException" => {
4828 return RusotoError::Service(DisassociateMembersError::ResourceNotFound(
4829 err.msg,
4830 ))
4831 }
4832 "ValidationException" => return RusotoError::Validation(err.msg),
4833 _ => {}
4834 }
4835 }
4836 RusotoError::Unknown(res)
4837 }
4838}
4839impl fmt::Display for DisassociateMembersError {
4840 #[allow(unused_variables)]
4841 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4842 match *self {
4843 DisassociateMembersError::Internal(ref cause) => write!(f, "{}", cause),
4844 DisassociateMembersError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4845 DisassociateMembersError::InvalidInput(ref cause) => write!(f, "{}", cause),
4846 DisassociateMembersError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4847 DisassociateMembersError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
4848 }
4849 }
4850}
4851impl Error for DisassociateMembersError {}
4852#[derive(Debug, PartialEq)]
4854pub enum EnableImportFindingsForProductError {
4855 Internal(String),
4857 InvalidAccess(String),
4859 InvalidInput(String),
4861 LimitExceeded(String),
4863 ResourceConflict(String),
4865}
4866
4867impl EnableImportFindingsForProductError {
4868 pub fn from_response(
4869 res: BufferedHttpResponse,
4870 ) -> RusotoError<EnableImportFindingsForProductError> {
4871 if let Some(err) = proto::json::Error::parse_rest(&res) {
4872 match err.typ.as_str() {
4873 "InternalException" => {
4874 return RusotoError::Service(EnableImportFindingsForProductError::Internal(
4875 err.msg,
4876 ))
4877 }
4878 "InvalidAccessException" => {
4879 return RusotoError::Service(
4880 EnableImportFindingsForProductError::InvalidAccess(err.msg),
4881 )
4882 }
4883 "InvalidInputException" => {
4884 return RusotoError::Service(EnableImportFindingsForProductError::InvalidInput(
4885 err.msg,
4886 ))
4887 }
4888 "LimitExceededException" => {
4889 return RusotoError::Service(
4890 EnableImportFindingsForProductError::LimitExceeded(err.msg),
4891 )
4892 }
4893 "ResourceConflictException" => {
4894 return RusotoError::Service(
4895 EnableImportFindingsForProductError::ResourceConflict(err.msg),
4896 )
4897 }
4898 "ValidationException" => return RusotoError::Validation(err.msg),
4899 _ => {}
4900 }
4901 }
4902 RusotoError::Unknown(res)
4903 }
4904}
4905impl fmt::Display for EnableImportFindingsForProductError {
4906 #[allow(unused_variables)]
4907 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4908 match *self {
4909 EnableImportFindingsForProductError::Internal(ref cause) => write!(f, "{}", cause),
4910 EnableImportFindingsForProductError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4911 EnableImportFindingsForProductError::InvalidInput(ref cause) => write!(f, "{}", cause),
4912 EnableImportFindingsForProductError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4913 EnableImportFindingsForProductError::ResourceConflict(ref cause) => {
4914 write!(f, "{}", cause)
4915 }
4916 }
4917 }
4918}
4919impl Error for EnableImportFindingsForProductError {}
4920#[derive(Debug, PartialEq)]
4922pub enum EnableSecurityHubError {
4923 AccessDenied(String),
4925 Internal(String),
4927 InvalidAccess(String),
4929 LimitExceeded(String),
4931 ResourceConflict(String),
4933}
4934
4935impl EnableSecurityHubError {
4936 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<EnableSecurityHubError> {
4937 if let Some(err) = proto::json::Error::parse_rest(&res) {
4938 match err.typ.as_str() {
4939 "AccessDeniedException" => {
4940 return RusotoError::Service(EnableSecurityHubError::AccessDenied(err.msg))
4941 }
4942 "InternalException" => {
4943 return RusotoError::Service(EnableSecurityHubError::Internal(err.msg))
4944 }
4945 "InvalidAccessException" => {
4946 return RusotoError::Service(EnableSecurityHubError::InvalidAccess(err.msg))
4947 }
4948 "LimitExceededException" => {
4949 return RusotoError::Service(EnableSecurityHubError::LimitExceeded(err.msg))
4950 }
4951 "ResourceConflictException" => {
4952 return RusotoError::Service(EnableSecurityHubError::ResourceConflict(err.msg))
4953 }
4954 "ValidationException" => return RusotoError::Validation(err.msg),
4955 _ => {}
4956 }
4957 }
4958 RusotoError::Unknown(res)
4959 }
4960}
4961impl fmt::Display for EnableSecurityHubError {
4962 #[allow(unused_variables)]
4963 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
4964 match *self {
4965 EnableSecurityHubError::AccessDenied(ref cause) => write!(f, "{}", cause),
4966 EnableSecurityHubError::Internal(ref cause) => write!(f, "{}", cause),
4967 EnableSecurityHubError::InvalidAccess(ref cause) => write!(f, "{}", cause),
4968 EnableSecurityHubError::LimitExceeded(ref cause) => write!(f, "{}", cause),
4969 EnableSecurityHubError::ResourceConflict(ref cause) => write!(f, "{}", cause),
4970 }
4971 }
4972}
4973impl Error for EnableSecurityHubError {}
4974#[derive(Debug, PartialEq)]
4976pub enum GetEnabledStandardsError {
4977 Internal(String),
4979 InvalidAccess(String),
4981 InvalidInput(String),
4983 LimitExceeded(String),
4985}
4986
4987impl GetEnabledStandardsError {
4988 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetEnabledStandardsError> {
4989 if let Some(err) = proto::json::Error::parse_rest(&res) {
4990 match err.typ.as_str() {
4991 "InternalException" => {
4992 return RusotoError::Service(GetEnabledStandardsError::Internal(err.msg))
4993 }
4994 "InvalidAccessException" => {
4995 return RusotoError::Service(GetEnabledStandardsError::InvalidAccess(err.msg))
4996 }
4997 "InvalidInputException" => {
4998 return RusotoError::Service(GetEnabledStandardsError::InvalidInput(err.msg))
4999 }
5000 "LimitExceededException" => {
5001 return RusotoError::Service(GetEnabledStandardsError::LimitExceeded(err.msg))
5002 }
5003 "ValidationException" => return RusotoError::Validation(err.msg),
5004 _ => {}
5005 }
5006 }
5007 RusotoError::Unknown(res)
5008 }
5009}
5010impl fmt::Display for GetEnabledStandardsError {
5011 #[allow(unused_variables)]
5012 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5013 match *self {
5014 GetEnabledStandardsError::Internal(ref cause) => write!(f, "{}", cause),
5015 GetEnabledStandardsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5016 GetEnabledStandardsError::InvalidInput(ref cause) => write!(f, "{}", cause),
5017 GetEnabledStandardsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5018 }
5019 }
5020}
5021impl Error for GetEnabledStandardsError {}
5022#[derive(Debug, PartialEq)]
5024pub enum GetFindingsError {
5025 Internal(String),
5027 InvalidAccess(String),
5029 InvalidInput(String),
5031 LimitExceeded(String),
5033}
5034
5035impl GetFindingsError {
5036 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetFindingsError> {
5037 if let Some(err) = proto::json::Error::parse_rest(&res) {
5038 match err.typ.as_str() {
5039 "InternalException" => {
5040 return RusotoError::Service(GetFindingsError::Internal(err.msg))
5041 }
5042 "InvalidAccessException" => {
5043 return RusotoError::Service(GetFindingsError::InvalidAccess(err.msg))
5044 }
5045 "InvalidInputException" => {
5046 return RusotoError::Service(GetFindingsError::InvalidInput(err.msg))
5047 }
5048 "LimitExceededException" => {
5049 return RusotoError::Service(GetFindingsError::LimitExceeded(err.msg))
5050 }
5051 "ValidationException" => return RusotoError::Validation(err.msg),
5052 _ => {}
5053 }
5054 }
5055 RusotoError::Unknown(res)
5056 }
5057}
5058impl fmt::Display for GetFindingsError {
5059 #[allow(unused_variables)]
5060 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5061 match *self {
5062 GetFindingsError::Internal(ref cause) => write!(f, "{}", cause),
5063 GetFindingsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5064 GetFindingsError::InvalidInput(ref cause) => write!(f, "{}", cause),
5065 GetFindingsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5066 }
5067 }
5068}
5069impl Error for GetFindingsError {}
5070#[derive(Debug, PartialEq)]
5072pub enum GetInsightResultsError {
5073 Internal(String),
5075 InvalidAccess(String),
5077 InvalidInput(String),
5079 LimitExceeded(String),
5081 ResourceNotFound(String),
5083}
5084
5085impl GetInsightResultsError {
5086 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetInsightResultsError> {
5087 if let Some(err) = proto::json::Error::parse_rest(&res) {
5088 match err.typ.as_str() {
5089 "InternalException" => {
5090 return RusotoError::Service(GetInsightResultsError::Internal(err.msg))
5091 }
5092 "InvalidAccessException" => {
5093 return RusotoError::Service(GetInsightResultsError::InvalidAccess(err.msg))
5094 }
5095 "InvalidInputException" => {
5096 return RusotoError::Service(GetInsightResultsError::InvalidInput(err.msg))
5097 }
5098 "LimitExceededException" => {
5099 return RusotoError::Service(GetInsightResultsError::LimitExceeded(err.msg))
5100 }
5101 "ResourceNotFoundException" => {
5102 return RusotoError::Service(GetInsightResultsError::ResourceNotFound(err.msg))
5103 }
5104 "ValidationException" => return RusotoError::Validation(err.msg),
5105 _ => {}
5106 }
5107 }
5108 RusotoError::Unknown(res)
5109 }
5110}
5111impl fmt::Display for GetInsightResultsError {
5112 #[allow(unused_variables)]
5113 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5114 match *self {
5115 GetInsightResultsError::Internal(ref cause) => write!(f, "{}", cause),
5116 GetInsightResultsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5117 GetInsightResultsError::InvalidInput(ref cause) => write!(f, "{}", cause),
5118 GetInsightResultsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5119 GetInsightResultsError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5120 }
5121 }
5122}
5123impl Error for GetInsightResultsError {}
5124#[derive(Debug, PartialEq)]
5126pub enum GetInsightsError {
5127 Internal(String),
5129 InvalidAccess(String),
5131 InvalidInput(String),
5133 LimitExceeded(String),
5135 ResourceNotFound(String),
5137}
5138
5139impl GetInsightsError {
5140 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetInsightsError> {
5141 if let Some(err) = proto::json::Error::parse_rest(&res) {
5142 match err.typ.as_str() {
5143 "InternalException" => {
5144 return RusotoError::Service(GetInsightsError::Internal(err.msg))
5145 }
5146 "InvalidAccessException" => {
5147 return RusotoError::Service(GetInsightsError::InvalidAccess(err.msg))
5148 }
5149 "InvalidInputException" => {
5150 return RusotoError::Service(GetInsightsError::InvalidInput(err.msg))
5151 }
5152 "LimitExceededException" => {
5153 return RusotoError::Service(GetInsightsError::LimitExceeded(err.msg))
5154 }
5155 "ResourceNotFoundException" => {
5156 return RusotoError::Service(GetInsightsError::ResourceNotFound(err.msg))
5157 }
5158 "ValidationException" => return RusotoError::Validation(err.msg),
5159 _ => {}
5160 }
5161 }
5162 RusotoError::Unknown(res)
5163 }
5164}
5165impl fmt::Display for GetInsightsError {
5166 #[allow(unused_variables)]
5167 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5168 match *self {
5169 GetInsightsError::Internal(ref cause) => write!(f, "{}", cause),
5170 GetInsightsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5171 GetInsightsError::InvalidInput(ref cause) => write!(f, "{}", cause),
5172 GetInsightsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5173 GetInsightsError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5174 }
5175 }
5176}
5177impl Error for GetInsightsError {}
5178#[derive(Debug, PartialEq)]
5180pub enum GetInvitationsCountError {
5181 Internal(String),
5183 InvalidAccess(String),
5185 InvalidInput(String),
5187 LimitExceeded(String),
5189}
5190
5191impl GetInvitationsCountError {
5192 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetInvitationsCountError> {
5193 if let Some(err) = proto::json::Error::parse_rest(&res) {
5194 match err.typ.as_str() {
5195 "InternalException" => {
5196 return RusotoError::Service(GetInvitationsCountError::Internal(err.msg))
5197 }
5198 "InvalidAccessException" => {
5199 return RusotoError::Service(GetInvitationsCountError::InvalidAccess(err.msg))
5200 }
5201 "InvalidInputException" => {
5202 return RusotoError::Service(GetInvitationsCountError::InvalidInput(err.msg))
5203 }
5204 "LimitExceededException" => {
5205 return RusotoError::Service(GetInvitationsCountError::LimitExceeded(err.msg))
5206 }
5207 "ValidationException" => return RusotoError::Validation(err.msg),
5208 _ => {}
5209 }
5210 }
5211 RusotoError::Unknown(res)
5212 }
5213}
5214impl fmt::Display for GetInvitationsCountError {
5215 #[allow(unused_variables)]
5216 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5217 match *self {
5218 GetInvitationsCountError::Internal(ref cause) => write!(f, "{}", cause),
5219 GetInvitationsCountError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5220 GetInvitationsCountError::InvalidInput(ref cause) => write!(f, "{}", cause),
5221 GetInvitationsCountError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5222 }
5223 }
5224}
5225impl Error for GetInvitationsCountError {}
5226#[derive(Debug, PartialEq)]
5228pub enum GetMasterAccountError {
5229 Internal(String),
5231 InvalidAccess(String),
5233 InvalidInput(String),
5235 LimitExceeded(String),
5237 ResourceNotFound(String),
5239}
5240
5241impl GetMasterAccountError {
5242 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetMasterAccountError> {
5243 if let Some(err) = proto::json::Error::parse_rest(&res) {
5244 match err.typ.as_str() {
5245 "InternalException" => {
5246 return RusotoError::Service(GetMasterAccountError::Internal(err.msg))
5247 }
5248 "InvalidAccessException" => {
5249 return RusotoError::Service(GetMasterAccountError::InvalidAccess(err.msg))
5250 }
5251 "InvalidInputException" => {
5252 return RusotoError::Service(GetMasterAccountError::InvalidInput(err.msg))
5253 }
5254 "LimitExceededException" => {
5255 return RusotoError::Service(GetMasterAccountError::LimitExceeded(err.msg))
5256 }
5257 "ResourceNotFoundException" => {
5258 return RusotoError::Service(GetMasterAccountError::ResourceNotFound(err.msg))
5259 }
5260 "ValidationException" => return RusotoError::Validation(err.msg),
5261 _ => {}
5262 }
5263 }
5264 RusotoError::Unknown(res)
5265 }
5266}
5267impl fmt::Display for GetMasterAccountError {
5268 #[allow(unused_variables)]
5269 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5270 match *self {
5271 GetMasterAccountError::Internal(ref cause) => write!(f, "{}", cause),
5272 GetMasterAccountError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5273 GetMasterAccountError::InvalidInput(ref cause) => write!(f, "{}", cause),
5274 GetMasterAccountError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5275 GetMasterAccountError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5276 }
5277 }
5278}
5279impl Error for GetMasterAccountError {}
5280#[derive(Debug, PartialEq)]
5282pub enum GetMembersError {
5283 Internal(String),
5285 InvalidAccess(String),
5287 InvalidInput(String),
5289 LimitExceeded(String),
5291 ResourceNotFound(String),
5293}
5294
5295impl GetMembersError {
5296 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<GetMembersError> {
5297 if let Some(err) = proto::json::Error::parse_rest(&res) {
5298 match err.typ.as_str() {
5299 "InternalException" => {
5300 return RusotoError::Service(GetMembersError::Internal(err.msg))
5301 }
5302 "InvalidAccessException" => {
5303 return RusotoError::Service(GetMembersError::InvalidAccess(err.msg))
5304 }
5305 "InvalidInputException" => {
5306 return RusotoError::Service(GetMembersError::InvalidInput(err.msg))
5307 }
5308 "LimitExceededException" => {
5309 return RusotoError::Service(GetMembersError::LimitExceeded(err.msg))
5310 }
5311 "ResourceNotFoundException" => {
5312 return RusotoError::Service(GetMembersError::ResourceNotFound(err.msg))
5313 }
5314 "ValidationException" => return RusotoError::Validation(err.msg),
5315 _ => {}
5316 }
5317 }
5318 RusotoError::Unknown(res)
5319 }
5320}
5321impl fmt::Display for GetMembersError {
5322 #[allow(unused_variables)]
5323 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5324 match *self {
5325 GetMembersError::Internal(ref cause) => write!(f, "{}", cause),
5326 GetMembersError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5327 GetMembersError::InvalidInput(ref cause) => write!(f, "{}", cause),
5328 GetMembersError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5329 GetMembersError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5330 }
5331 }
5332}
5333impl Error for GetMembersError {}
5334#[derive(Debug, PartialEq)]
5336pub enum InviteMembersError {
5337 Internal(String),
5339 InvalidAccess(String),
5341 InvalidInput(String),
5343 LimitExceeded(String),
5345 ResourceNotFound(String),
5347}
5348
5349impl InviteMembersError {
5350 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<InviteMembersError> {
5351 if let Some(err) = proto::json::Error::parse_rest(&res) {
5352 match err.typ.as_str() {
5353 "InternalException" => {
5354 return RusotoError::Service(InviteMembersError::Internal(err.msg))
5355 }
5356 "InvalidAccessException" => {
5357 return RusotoError::Service(InviteMembersError::InvalidAccess(err.msg))
5358 }
5359 "InvalidInputException" => {
5360 return RusotoError::Service(InviteMembersError::InvalidInput(err.msg))
5361 }
5362 "LimitExceededException" => {
5363 return RusotoError::Service(InviteMembersError::LimitExceeded(err.msg))
5364 }
5365 "ResourceNotFoundException" => {
5366 return RusotoError::Service(InviteMembersError::ResourceNotFound(err.msg))
5367 }
5368 "ValidationException" => return RusotoError::Validation(err.msg),
5369 _ => {}
5370 }
5371 }
5372 RusotoError::Unknown(res)
5373 }
5374}
5375impl fmt::Display for InviteMembersError {
5376 #[allow(unused_variables)]
5377 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5378 match *self {
5379 InviteMembersError::Internal(ref cause) => write!(f, "{}", cause),
5380 InviteMembersError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5381 InviteMembersError::InvalidInput(ref cause) => write!(f, "{}", cause),
5382 InviteMembersError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5383 InviteMembersError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5384 }
5385 }
5386}
5387impl Error for InviteMembersError {}
5388#[derive(Debug, PartialEq)]
5390pub enum ListEnabledProductsForImportError {
5391 Internal(String),
5393 InvalidAccess(String),
5395 LimitExceeded(String),
5397}
5398
5399impl ListEnabledProductsForImportError {
5400 pub fn from_response(
5401 res: BufferedHttpResponse,
5402 ) -> RusotoError<ListEnabledProductsForImportError> {
5403 if let Some(err) = proto::json::Error::parse_rest(&res) {
5404 match err.typ.as_str() {
5405 "InternalException" => {
5406 return RusotoError::Service(ListEnabledProductsForImportError::Internal(
5407 err.msg,
5408 ))
5409 }
5410 "InvalidAccessException" => {
5411 return RusotoError::Service(ListEnabledProductsForImportError::InvalidAccess(
5412 err.msg,
5413 ))
5414 }
5415 "LimitExceededException" => {
5416 return RusotoError::Service(ListEnabledProductsForImportError::LimitExceeded(
5417 err.msg,
5418 ))
5419 }
5420 "ValidationException" => return RusotoError::Validation(err.msg),
5421 _ => {}
5422 }
5423 }
5424 RusotoError::Unknown(res)
5425 }
5426}
5427impl fmt::Display for ListEnabledProductsForImportError {
5428 #[allow(unused_variables)]
5429 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5430 match *self {
5431 ListEnabledProductsForImportError::Internal(ref cause) => write!(f, "{}", cause),
5432 ListEnabledProductsForImportError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5433 ListEnabledProductsForImportError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5434 }
5435 }
5436}
5437impl Error for ListEnabledProductsForImportError {}
5438#[derive(Debug, PartialEq)]
5440pub enum ListInvitationsError {
5441 Internal(String),
5443 InvalidAccess(String),
5445 InvalidInput(String),
5447 LimitExceeded(String),
5449}
5450
5451impl ListInvitationsError {
5452 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListInvitationsError> {
5453 if let Some(err) = proto::json::Error::parse_rest(&res) {
5454 match err.typ.as_str() {
5455 "InternalException" => {
5456 return RusotoError::Service(ListInvitationsError::Internal(err.msg))
5457 }
5458 "InvalidAccessException" => {
5459 return RusotoError::Service(ListInvitationsError::InvalidAccess(err.msg))
5460 }
5461 "InvalidInputException" => {
5462 return RusotoError::Service(ListInvitationsError::InvalidInput(err.msg))
5463 }
5464 "LimitExceededException" => {
5465 return RusotoError::Service(ListInvitationsError::LimitExceeded(err.msg))
5466 }
5467 "ValidationException" => return RusotoError::Validation(err.msg),
5468 _ => {}
5469 }
5470 }
5471 RusotoError::Unknown(res)
5472 }
5473}
5474impl fmt::Display for ListInvitationsError {
5475 #[allow(unused_variables)]
5476 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5477 match *self {
5478 ListInvitationsError::Internal(ref cause) => write!(f, "{}", cause),
5479 ListInvitationsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5480 ListInvitationsError::InvalidInput(ref cause) => write!(f, "{}", cause),
5481 ListInvitationsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5482 }
5483 }
5484}
5485impl Error for ListInvitationsError {}
5486#[derive(Debug, PartialEq)]
5488pub enum ListMembersError {
5489 Internal(String),
5491 InvalidAccess(String),
5493 InvalidInput(String),
5495 LimitExceeded(String),
5497}
5498
5499impl ListMembersError {
5500 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListMembersError> {
5501 if let Some(err) = proto::json::Error::parse_rest(&res) {
5502 match err.typ.as_str() {
5503 "InternalException" => {
5504 return RusotoError::Service(ListMembersError::Internal(err.msg))
5505 }
5506 "InvalidAccessException" => {
5507 return RusotoError::Service(ListMembersError::InvalidAccess(err.msg))
5508 }
5509 "InvalidInputException" => {
5510 return RusotoError::Service(ListMembersError::InvalidInput(err.msg))
5511 }
5512 "LimitExceededException" => {
5513 return RusotoError::Service(ListMembersError::LimitExceeded(err.msg))
5514 }
5515 "ValidationException" => return RusotoError::Validation(err.msg),
5516 _ => {}
5517 }
5518 }
5519 RusotoError::Unknown(res)
5520 }
5521}
5522impl fmt::Display for ListMembersError {
5523 #[allow(unused_variables)]
5524 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5525 match *self {
5526 ListMembersError::Internal(ref cause) => write!(f, "{}", cause),
5527 ListMembersError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5528 ListMembersError::InvalidInput(ref cause) => write!(f, "{}", cause),
5529 ListMembersError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5530 }
5531 }
5532}
5533impl Error for ListMembersError {}
5534#[derive(Debug, PartialEq)]
5536pub enum ListTagsForResourceError {
5537 Internal(String),
5539 InvalidInput(String),
5541 ResourceNotFound(String),
5543}
5544
5545impl ListTagsForResourceError {
5546 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<ListTagsForResourceError> {
5547 if let Some(err) = proto::json::Error::parse_rest(&res) {
5548 match err.typ.as_str() {
5549 "InternalException" => {
5550 return RusotoError::Service(ListTagsForResourceError::Internal(err.msg))
5551 }
5552 "InvalidInputException" => {
5553 return RusotoError::Service(ListTagsForResourceError::InvalidInput(err.msg))
5554 }
5555 "ResourceNotFoundException" => {
5556 return RusotoError::Service(ListTagsForResourceError::ResourceNotFound(
5557 err.msg,
5558 ))
5559 }
5560 "ValidationException" => return RusotoError::Validation(err.msg),
5561 _ => {}
5562 }
5563 }
5564 RusotoError::Unknown(res)
5565 }
5566}
5567impl fmt::Display for ListTagsForResourceError {
5568 #[allow(unused_variables)]
5569 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5570 match *self {
5571 ListTagsForResourceError::Internal(ref cause) => write!(f, "{}", cause),
5572 ListTagsForResourceError::InvalidInput(ref cause) => write!(f, "{}", cause),
5573 ListTagsForResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5574 }
5575 }
5576}
5577impl Error for ListTagsForResourceError {}
5578#[derive(Debug, PartialEq)]
5580pub enum TagResourceError {
5581 Internal(String),
5583 InvalidInput(String),
5585 ResourceNotFound(String),
5587}
5588
5589impl TagResourceError {
5590 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<TagResourceError> {
5591 if let Some(err) = proto::json::Error::parse_rest(&res) {
5592 match err.typ.as_str() {
5593 "InternalException" => {
5594 return RusotoError::Service(TagResourceError::Internal(err.msg))
5595 }
5596 "InvalidInputException" => {
5597 return RusotoError::Service(TagResourceError::InvalidInput(err.msg))
5598 }
5599 "ResourceNotFoundException" => {
5600 return RusotoError::Service(TagResourceError::ResourceNotFound(err.msg))
5601 }
5602 "ValidationException" => return RusotoError::Validation(err.msg),
5603 _ => {}
5604 }
5605 }
5606 RusotoError::Unknown(res)
5607 }
5608}
5609impl fmt::Display for TagResourceError {
5610 #[allow(unused_variables)]
5611 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5612 match *self {
5613 TagResourceError::Internal(ref cause) => write!(f, "{}", cause),
5614 TagResourceError::InvalidInput(ref cause) => write!(f, "{}", cause),
5615 TagResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5616 }
5617 }
5618}
5619impl Error for TagResourceError {}
5620#[derive(Debug, PartialEq)]
5622pub enum UntagResourceError {
5623 Internal(String),
5625 InvalidInput(String),
5627 ResourceNotFound(String),
5629}
5630
5631impl UntagResourceError {
5632 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UntagResourceError> {
5633 if let Some(err) = proto::json::Error::parse_rest(&res) {
5634 match err.typ.as_str() {
5635 "InternalException" => {
5636 return RusotoError::Service(UntagResourceError::Internal(err.msg))
5637 }
5638 "InvalidInputException" => {
5639 return RusotoError::Service(UntagResourceError::InvalidInput(err.msg))
5640 }
5641 "ResourceNotFoundException" => {
5642 return RusotoError::Service(UntagResourceError::ResourceNotFound(err.msg))
5643 }
5644 "ValidationException" => return RusotoError::Validation(err.msg),
5645 _ => {}
5646 }
5647 }
5648 RusotoError::Unknown(res)
5649 }
5650}
5651impl fmt::Display for UntagResourceError {
5652 #[allow(unused_variables)]
5653 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5654 match *self {
5655 UntagResourceError::Internal(ref cause) => write!(f, "{}", cause),
5656 UntagResourceError::InvalidInput(ref cause) => write!(f, "{}", cause),
5657 UntagResourceError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5658 }
5659 }
5660}
5661impl Error for UntagResourceError {}
5662#[derive(Debug, PartialEq)]
5664pub enum UpdateActionTargetError {
5665 Internal(String),
5667 InvalidAccess(String),
5669 InvalidInput(String),
5671 ResourceNotFound(String),
5673}
5674
5675impl UpdateActionTargetError {
5676 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdateActionTargetError> {
5677 if let Some(err) = proto::json::Error::parse_rest(&res) {
5678 match err.typ.as_str() {
5679 "InternalException" => {
5680 return RusotoError::Service(UpdateActionTargetError::Internal(err.msg))
5681 }
5682 "InvalidAccessException" => {
5683 return RusotoError::Service(UpdateActionTargetError::InvalidAccess(err.msg))
5684 }
5685 "InvalidInputException" => {
5686 return RusotoError::Service(UpdateActionTargetError::InvalidInput(err.msg))
5687 }
5688 "ResourceNotFoundException" => {
5689 return RusotoError::Service(UpdateActionTargetError::ResourceNotFound(err.msg))
5690 }
5691 "ValidationException" => return RusotoError::Validation(err.msg),
5692 _ => {}
5693 }
5694 }
5695 RusotoError::Unknown(res)
5696 }
5697}
5698impl fmt::Display for UpdateActionTargetError {
5699 #[allow(unused_variables)]
5700 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5701 match *self {
5702 UpdateActionTargetError::Internal(ref cause) => write!(f, "{}", cause),
5703 UpdateActionTargetError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5704 UpdateActionTargetError::InvalidInput(ref cause) => write!(f, "{}", cause),
5705 UpdateActionTargetError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5706 }
5707 }
5708}
5709impl Error for UpdateActionTargetError {}
5710#[derive(Debug, PartialEq)]
5712pub enum UpdateFindingsError {
5713 Internal(String),
5715 InvalidAccess(String),
5717 InvalidInput(String),
5719 LimitExceeded(String),
5721 ResourceNotFound(String),
5723}
5724
5725impl UpdateFindingsError {
5726 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdateFindingsError> {
5727 if let Some(err) = proto::json::Error::parse_rest(&res) {
5728 match err.typ.as_str() {
5729 "InternalException" => {
5730 return RusotoError::Service(UpdateFindingsError::Internal(err.msg))
5731 }
5732 "InvalidAccessException" => {
5733 return RusotoError::Service(UpdateFindingsError::InvalidAccess(err.msg))
5734 }
5735 "InvalidInputException" => {
5736 return RusotoError::Service(UpdateFindingsError::InvalidInput(err.msg))
5737 }
5738 "LimitExceededException" => {
5739 return RusotoError::Service(UpdateFindingsError::LimitExceeded(err.msg))
5740 }
5741 "ResourceNotFoundException" => {
5742 return RusotoError::Service(UpdateFindingsError::ResourceNotFound(err.msg))
5743 }
5744 "ValidationException" => return RusotoError::Validation(err.msg),
5745 _ => {}
5746 }
5747 }
5748 RusotoError::Unknown(res)
5749 }
5750}
5751impl fmt::Display for UpdateFindingsError {
5752 #[allow(unused_variables)]
5753 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5754 match *self {
5755 UpdateFindingsError::Internal(ref cause) => write!(f, "{}", cause),
5756 UpdateFindingsError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5757 UpdateFindingsError::InvalidInput(ref cause) => write!(f, "{}", cause),
5758 UpdateFindingsError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5759 UpdateFindingsError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5760 }
5761 }
5762}
5763impl Error for UpdateFindingsError {}
5764#[derive(Debug, PartialEq)]
5766pub enum UpdateInsightError {
5767 Internal(String),
5769 InvalidAccess(String),
5771 InvalidInput(String),
5773 LimitExceeded(String),
5775 ResourceNotFound(String),
5777}
5778
5779impl UpdateInsightError {
5780 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdateInsightError> {
5781 if let Some(err) = proto::json::Error::parse_rest(&res) {
5782 match err.typ.as_str() {
5783 "InternalException" => {
5784 return RusotoError::Service(UpdateInsightError::Internal(err.msg))
5785 }
5786 "InvalidAccessException" => {
5787 return RusotoError::Service(UpdateInsightError::InvalidAccess(err.msg))
5788 }
5789 "InvalidInputException" => {
5790 return RusotoError::Service(UpdateInsightError::InvalidInput(err.msg))
5791 }
5792 "LimitExceededException" => {
5793 return RusotoError::Service(UpdateInsightError::LimitExceeded(err.msg))
5794 }
5795 "ResourceNotFoundException" => {
5796 return RusotoError::Service(UpdateInsightError::ResourceNotFound(err.msg))
5797 }
5798 "ValidationException" => return RusotoError::Validation(err.msg),
5799 _ => {}
5800 }
5801 }
5802 RusotoError::Unknown(res)
5803 }
5804}
5805impl fmt::Display for UpdateInsightError {
5806 #[allow(unused_variables)]
5807 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5808 match *self {
5809 UpdateInsightError::Internal(ref cause) => write!(f, "{}", cause),
5810 UpdateInsightError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5811 UpdateInsightError::InvalidInput(ref cause) => write!(f, "{}", cause),
5812 UpdateInsightError::LimitExceeded(ref cause) => write!(f, "{}", cause),
5813 UpdateInsightError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5814 }
5815 }
5816}
5817impl Error for UpdateInsightError {}
5818#[derive(Debug, PartialEq)]
5820pub enum UpdateStandardsControlError {
5821 Internal(String),
5823 InvalidAccess(String),
5825 InvalidInput(String),
5827 ResourceNotFound(String),
5829}
5830
5831impl UpdateStandardsControlError {
5832 pub fn from_response(res: BufferedHttpResponse) -> RusotoError<UpdateStandardsControlError> {
5833 if let Some(err) = proto::json::Error::parse_rest(&res) {
5834 match err.typ.as_str() {
5835 "InternalException" => {
5836 return RusotoError::Service(UpdateStandardsControlError::Internal(err.msg))
5837 }
5838 "InvalidAccessException" => {
5839 return RusotoError::Service(UpdateStandardsControlError::InvalidAccess(
5840 err.msg,
5841 ))
5842 }
5843 "InvalidInputException" => {
5844 return RusotoError::Service(UpdateStandardsControlError::InvalidInput(err.msg))
5845 }
5846 "ResourceNotFoundException" => {
5847 return RusotoError::Service(UpdateStandardsControlError::ResourceNotFound(
5848 err.msg,
5849 ))
5850 }
5851 "ValidationException" => return RusotoError::Validation(err.msg),
5852 _ => {}
5853 }
5854 }
5855 RusotoError::Unknown(res)
5856 }
5857}
5858impl fmt::Display for UpdateStandardsControlError {
5859 #[allow(unused_variables)]
5860 fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result {
5861 match *self {
5862 UpdateStandardsControlError::Internal(ref cause) => write!(f, "{}", cause),
5863 UpdateStandardsControlError::InvalidAccess(ref cause) => write!(f, "{}", cause),
5864 UpdateStandardsControlError::InvalidInput(ref cause) => write!(f, "{}", cause),
5865 UpdateStandardsControlError::ResourceNotFound(ref cause) => write!(f, "{}", cause),
5866 }
5867 }
5868}
5869impl Error for UpdateStandardsControlError {}
5870#[async_trait]
5872pub trait SecurityHub {
5873 async fn accept_invitation(
5875 &self,
5876 input: AcceptInvitationRequest,
5877 ) -> Result<AcceptInvitationResponse, RusotoError<AcceptInvitationError>>;
5878
5879 async fn batch_disable_standards(
5881 &self,
5882 input: BatchDisableStandardsRequest,
5883 ) -> Result<BatchDisableStandardsResponse, RusotoError<BatchDisableStandardsError>>;
5884
5885 async fn batch_enable_standards(
5887 &self,
5888 input: BatchEnableStandardsRequest,
5889 ) -> Result<BatchEnableStandardsResponse, RusotoError<BatchEnableStandardsError>>;
5890
5891 async fn batch_import_findings(
5893 &self,
5894 input: BatchImportFindingsRequest,
5895 ) -> Result<BatchImportFindingsResponse, RusotoError<BatchImportFindingsError>>;
5896
5897 async fn batch_update_findings(
5899 &self,
5900 input: BatchUpdateFindingsRequest,
5901 ) -> Result<BatchUpdateFindingsResponse, RusotoError<BatchUpdateFindingsError>>;
5902
5903 async fn create_action_target(
5905 &self,
5906 input: CreateActionTargetRequest,
5907 ) -> Result<CreateActionTargetResponse, RusotoError<CreateActionTargetError>>;
5908
5909 async fn create_insight(
5911 &self,
5912 input: CreateInsightRequest,
5913 ) -> Result<CreateInsightResponse, RusotoError<CreateInsightError>>;
5914
5915 async fn create_members(
5917 &self,
5918 input: CreateMembersRequest,
5919 ) -> Result<CreateMembersResponse, RusotoError<CreateMembersError>>;
5920
5921 async fn decline_invitations(
5923 &self,
5924 input: DeclineInvitationsRequest,
5925 ) -> Result<DeclineInvitationsResponse, RusotoError<DeclineInvitationsError>>;
5926
5927 async fn delete_action_target(
5929 &self,
5930 input: DeleteActionTargetRequest,
5931 ) -> Result<DeleteActionTargetResponse, RusotoError<DeleteActionTargetError>>;
5932
5933 async fn delete_insight(
5935 &self,
5936 input: DeleteInsightRequest,
5937 ) -> Result<DeleteInsightResponse, RusotoError<DeleteInsightError>>;
5938
5939 async fn delete_invitations(
5941 &self,
5942 input: DeleteInvitationsRequest,
5943 ) -> Result<DeleteInvitationsResponse, RusotoError<DeleteInvitationsError>>;
5944
5945 async fn delete_members(
5947 &self,
5948 input: DeleteMembersRequest,
5949 ) -> Result<DeleteMembersResponse, RusotoError<DeleteMembersError>>;
5950
5951 async fn describe_action_targets(
5953 &self,
5954 input: DescribeActionTargetsRequest,
5955 ) -> Result<DescribeActionTargetsResponse, RusotoError<DescribeActionTargetsError>>;
5956
5957 async fn describe_hub(
5959 &self,
5960 input: DescribeHubRequest,
5961 ) -> Result<DescribeHubResponse, RusotoError<DescribeHubError>>;
5962
5963 async fn describe_products(
5965 &self,
5966 input: DescribeProductsRequest,
5967 ) -> Result<DescribeProductsResponse, RusotoError<DescribeProductsError>>;
5968
5969 async fn describe_standards(
5971 &self,
5972 input: DescribeStandardsRequest,
5973 ) -> Result<DescribeStandardsResponse, RusotoError<DescribeStandardsError>>;
5974
5975 async fn describe_standards_controls(
5977 &self,
5978 input: DescribeStandardsControlsRequest,
5979 ) -> Result<DescribeStandardsControlsResponse, RusotoError<DescribeStandardsControlsError>>;
5980
5981 async fn disable_import_findings_for_product(
5983 &self,
5984 input: DisableImportFindingsForProductRequest,
5985 ) -> Result<
5986 DisableImportFindingsForProductResponse,
5987 RusotoError<DisableImportFindingsForProductError>,
5988 >;
5989
5990 async fn disable_security_hub(
5992 &self,
5993 ) -> Result<DisableSecurityHubResponse, RusotoError<DisableSecurityHubError>>;
5994
5995 async fn disassociate_from_master_account(
5997 &self,
5998 ) -> Result<
5999 DisassociateFromMasterAccountResponse,
6000 RusotoError<DisassociateFromMasterAccountError>,
6001 >;
6002
6003 async fn disassociate_members(
6005 &self,
6006 input: DisassociateMembersRequest,
6007 ) -> Result<DisassociateMembersResponse, RusotoError<DisassociateMembersError>>;
6008
6009 async fn enable_import_findings_for_product(
6011 &self,
6012 input: EnableImportFindingsForProductRequest,
6013 ) -> Result<
6014 EnableImportFindingsForProductResponse,
6015 RusotoError<EnableImportFindingsForProductError>,
6016 >;
6017
6018 async fn enable_security_hub(
6020 &self,
6021 input: EnableSecurityHubRequest,
6022 ) -> Result<EnableSecurityHubResponse, RusotoError<EnableSecurityHubError>>;
6023
6024 async fn get_enabled_standards(
6026 &self,
6027 input: GetEnabledStandardsRequest,
6028 ) -> Result<GetEnabledStandardsResponse, RusotoError<GetEnabledStandardsError>>;
6029
6030 async fn get_findings(
6032 &self,
6033 input: GetFindingsRequest,
6034 ) -> Result<GetFindingsResponse, RusotoError<GetFindingsError>>;
6035
6036 async fn get_insight_results(
6038 &self,
6039 input: GetInsightResultsRequest,
6040 ) -> Result<GetInsightResultsResponse, RusotoError<GetInsightResultsError>>;
6041
6042 async fn get_insights(
6044 &self,
6045 input: GetInsightsRequest,
6046 ) -> Result<GetInsightsResponse, RusotoError<GetInsightsError>>;
6047
6048 async fn get_invitations_count(
6050 &self,
6051 ) -> Result<GetInvitationsCountResponse, RusotoError<GetInvitationsCountError>>;
6052
6053 async fn get_master_account(
6055 &self,
6056 ) -> Result<GetMasterAccountResponse, RusotoError<GetMasterAccountError>>;
6057
6058 async fn get_members(
6060 &self,
6061 input: GetMembersRequest,
6062 ) -> Result<GetMembersResponse, RusotoError<GetMembersError>>;
6063
6064 async fn invite_members(
6066 &self,
6067 input: InviteMembersRequest,
6068 ) -> Result<InviteMembersResponse, RusotoError<InviteMembersError>>;
6069
6070 async fn list_enabled_products_for_import(
6072 &self,
6073 input: ListEnabledProductsForImportRequest,
6074 ) -> Result<ListEnabledProductsForImportResponse, RusotoError<ListEnabledProductsForImportError>>;
6075
6076 async fn list_invitations(
6078 &self,
6079 input: ListInvitationsRequest,
6080 ) -> Result<ListInvitationsResponse, RusotoError<ListInvitationsError>>;
6081
6082 async fn list_members(
6084 &self,
6085 input: ListMembersRequest,
6086 ) -> Result<ListMembersResponse, RusotoError<ListMembersError>>;
6087
6088 async fn list_tags_for_resource(
6090 &self,
6091 input: ListTagsForResourceRequest,
6092 ) -> Result<ListTagsForResourceResponse, RusotoError<ListTagsForResourceError>>;
6093
6094 async fn tag_resource(
6096 &self,
6097 input: TagResourceRequest,
6098 ) -> Result<TagResourceResponse, RusotoError<TagResourceError>>;
6099
6100 async fn untag_resource(
6102 &self,
6103 input: UntagResourceRequest,
6104 ) -> Result<UntagResourceResponse, RusotoError<UntagResourceError>>;
6105
6106 async fn update_action_target(
6108 &self,
6109 input: UpdateActionTargetRequest,
6110 ) -> Result<UpdateActionTargetResponse, RusotoError<UpdateActionTargetError>>;
6111
6112 async fn update_findings(
6114 &self,
6115 input: UpdateFindingsRequest,
6116 ) -> Result<UpdateFindingsResponse, RusotoError<UpdateFindingsError>>;
6117
6118 async fn update_insight(
6120 &self,
6121 input: UpdateInsightRequest,
6122 ) -> Result<UpdateInsightResponse, RusotoError<UpdateInsightError>>;
6123
6124 async fn update_standards_control(
6126 &self,
6127 input: UpdateStandardsControlRequest,
6128 ) -> Result<UpdateStandardsControlResponse, RusotoError<UpdateStandardsControlError>>;
6129}
6130#[derive(Clone)]
6132pub struct SecurityHubClient {
6133 client: Client,
6134 region: region::Region,
6135}
6136
6137impl SecurityHubClient {
6138 pub fn new(region: region::Region) -> SecurityHubClient {
6142 SecurityHubClient {
6143 client: Client::shared(),
6144 region,
6145 }
6146 }
6147
6148 pub fn new_with<P, D>(
6149 request_dispatcher: D,
6150 credentials_provider: P,
6151 region: region::Region,
6152 ) -> SecurityHubClient
6153 where
6154 P: ProvideAwsCredentials + Send + Sync + 'static,
6155 D: DispatchSignedRequest + Send + Sync + 'static,
6156 {
6157 SecurityHubClient {
6158 client: Client::new_with(credentials_provider, request_dispatcher),
6159 region,
6160 }
6161 }
6162
6163 pub fn new_with_client(client: Client, region: region::Region) -> SecurityHubClient {
6164 SecurityHubClient { client, region }
6165 }
6166}
6167
6168#[async_trait]
6169impl SecurityHub for SecurityHubClient {
6170 #[allow(unused_mut)]
6172 async fn accept_invitation(
6173 &self,
6174 input: AcceptInvitationRequest,
6175 ) -> Result<AcceptInvitationResponse, RusotoError<AcceptInvitationError>> {
6176 let request_uri = "/master";
6177
6178 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6179 request.set_content_type("application/x-amz-json-1.1".to_owned());
6180
6181 let encoded = Some(serde_json::to_vec(&input).unwrap());
6182 request.set_payload(encoded);
6183
6184 let mut response = self
6185 .client
6186 .sign_and_dispatch(request)
6187 .await
6188 .map_err(RusotoError::from)?;
6189 if response.status.is_success() {
6190 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6191 let result = proto::json::ResponsePayload::new(&response)
6192 .deserialize::<AcceptInvitationResponse, _>()?;
6193
6194 Ok(result)
6195 } else {
6196 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6197 Err(AcceptInvitationError::from_response(response))
6198 }
6199 }
6200
6201 #[allow(unused_mut)]
6203 async fn batch_disable_standards(
6204 &self,
6205 input: BatchDisableStandardsRequest,
6206 ) -> Result<BatchDisableStandardsResponse, RusotoError<BatchDisableStandardsError>> {
6207 let request_uri = "/standards/deregister";
6208
6209 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6210 request.set_content_type("application/x-amz-json-1.1".to_owned());
6211
6212 let encoded = Some(serde_json::to_vec(&input).unwrap());
6213 request.set_payload(encoded);
6214
6215 let mut response = self
6216 .client
6217 .sign_and_dispatch(request)
6218 .await
6219 .map_err(RusotoError::from)?;
6220 if response.status.is_success() {
6221 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6222 let result = proto::json::ResponsePayload::new(&response)
6223 .deserialize::<BatchDisableStandardsResponse, _>()?;
6224
6225 Ok(result)
6226 } else {
6227 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6228 Err(BatchDisableStandardsError::from_response(response))
6229 }
6230 }
6231
6232 #[allow(unused_mut)]
6234 async fn batch_enable_standards(
6235 &self,
6236 input: BatchEnableStandardsRequest,
6237 ) -> Result<BatchEnableStandardsResponse, RusotoError<BatchEnableStandardsError>> {
6238 let request_uri = "/standards/register";
6239
6240 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6241 request.set_content_type("application/x-amz-json-1.1".to_owned());
6242
6243 let encoded = Some(serde_json::to_vec(&input).unwrap());
6244 request.set_payload(encoded);
6245
6246 let mut response = self
6247 .client
6248 .sign_and_dispatch(request)
6249 .await
6250 .map_err(RusotoError::from)?;
6251 if response.status.is_success() {
6252 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6253 let result = proto::json::ResponsePayload::new(&response)
6254 .deserialize::<BatchEnableStandardsResponse, _>()?;
6255
6256 Ok(result)
6257 } else {
6258 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6259 Err(BatchEnableStandardsError::from_response(response))
6260 }
6261 }
6262
6263 #[allow(unused_mut)]
6265 async fn batch_import_findings(
6266 &self,
6267 input: BatchImportFindingsRequest,
6268 ) -> Result<BatchImportFindingsResponse, RusotoError<BatchImportFindingsError>> {
6269 let request_uri = "/findings/import";
6270
6271 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6272 request.set_content_type("application/x-amz-json-1.1".to_owned());
6273
6274 let encoded = Some(serde_json::to_vec(&input).unwrap());
6275 request.set_payload(encoded);
6276
6277 let mut response = self
6278 .client
6279 .sign_and_dispatch(request)
6280 .await
6281 .map_err(RusotoError::from)?;
6282 if response.status.is_success() {
6283 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6284 let result = proto::json::ResponsePayload::new(&response)
6285 .deserialize::<BatchImportFindingsResponse, _>()?;
6286
6287 Ok(result)
6288 } else {
6289 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6290 Err(BatchImportFindingsError::from_response(response))
6291 }
6292 }
6293
6294 #[allow(unused_mut)]
6296 async fn batch_update_findings(
6297 &self,
6298 input: BatchUpdateFindingsRequest,
6299 ) -> Result<BatchUpdateFindingsResponse, RusotoError<BatchUpdateFindingsError>> {
6300 let request_uri = "/findings/batchupdate";
6301
6302 let mut request = SignedRequest::new("PATCH", "securityhub", &self.region, &request_uri);
6303 request.set_content_type("application/x-amz-json-1.1".to_owned());
6304
6305 let encoded = Some(serde_json::to_vec(&input).unwrap());
6306 request.set_payload(encoded);
6307
6308 let mut response = self
6309 .client
6310 .sign_and_dispatch(request)
6311 .await
6312 .map_err(RusotoError::from)?;
6313 if response.status.is_success() {
6314 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6315 let result = proto::json::ResponsePayload::new(&response)
6316 .deserialize::<BatchUpdateFindingsResponse, _>()?;
6317
6318 Ok(result)
6319 } else {
6320 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6321 Err(BatchUpdateFindingsError::from_response(response))
6322 }
6323 }
6324
6325 #[allow(unused_mut)]
6327 async fn create_action_target(
6328 &self,
6329 input: CreateActionTargetRequest,
6330 ) -> Result<CreateActionTargetResponse, RusotoError<CreateActionTargetError>> {
6331 let request_uri = "/actionTargets";
6332
6333 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6334 request.set_content_type("application/x-amz-json-1.1".to_owned());
6335
6336 let encoded = Some(serde_json::to_vec(&input).unwrap());
6337 request.set_payload(encoded);
6338
6339 let mut response = self
6340 .client
6341 .sign_and_dispatch(request)
6342 .await
6343 .map_err(RusotoError::from)?;
6344 if response.status.is_success() {
6345 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6346 let result = proto::json::ResponsePayload::new(&response)
6347 .deserialize::<CreateActionTargetResponse, _>()?;
6348
6349 Ok(result)
6350 } else {
6351 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6352 Err(CreateActionTargetError::from_response(response))
6353 }
6354 }
6355
6356 #[allow(unused_mut)]
6358 async fn create_insight(
6359 &self,
6360 input: CreateInsightRequest,
6361 ) -> Result<CreateInsightResponse, RusotoError<CreateInsightError>> {
6362 let request_uri = "/insights";
6363
6364 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6365 request.set_content_type("application/x-amz-json-1.1".to_owned());
6366
6367 let encoded = Some(serde_json::to_vec(&input).unwrap());
6368 request.set_payload(encoded);
6369
6370 let mut response = self
6371 .client
6372 .sign_and_dispatch(request)
6373 .await
6374 .map_err(RusotoError::from)?;
6375 if response.status.is_success() {
6376 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6377 let result = proto::json::ResponsePayload::new(&response)
6378 .deserialize::<CreateInsightResponse, _>()?;
6379
6380 Ok(result)
6381 } else {
6382 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6383 Err(CreateInsightError::from_response(response))
6384 }
6385 }
6386
6387 #[allow(unused_mut)]
6389 async fn create_members(
6390 &self,
6391 input: CreateMembersRequest,
6392 ) -> Result<CreateMembersResponse, RusotoError<CreateMembersError>> {
6393 let request_uri = "/members";
6394
6395 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6396 request.set_content_type("application/x-amz-json-1.1".to_owned());
6397
6398 let encoded = Some(serde_json::to_vec(&input).unwrap());
6399 request.set_payload(encoded);
6400
6401 let mut response = self
6402 .client
6403 .sign_and_dispatch(request)
6404 .await
6405 .map_err(RusotoError::from)?;
6406 if response.status.is_success() {
6407 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6408 let result = proto::json::ResponsePayload::new(&response)
6409 .deserialize::<CreateMembersResponse, _>()?;
6410
6411 Ok(result)
6412 } else {
6413 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6414 Err(CreateMembersError::from_response(response))
6415 }
6416 }
6417
6418 #[allow(unused_mut)]
6420 async fn decline_invitations(
6421 &self,
6422 input: DeclineInvitationsRequest,
6423 ) -> Result<DeclineInvitationsResponse, RusotoError<DeclineInvitationsError>> {
6424 let request_uri = "/invitations/decline";
6425
6426 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6427 request.set_content_type("application/x-amz-json-1.1".to_owned());
6428
6429 let encoded = Some(serde_json::to_vec(&input).unwrap());
6430 request.set_payload(encoded);
6431
6432 let mut response = self
6433 .client
6434 .sign_and_dispatch(request)
6435 .await
6436 .map_err(RusotoError::from)?;
6437 if response.status.is_success() {
6438 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6439 let result = proto::json::ResponsePayload::new(&response)
6440 .deserialize::<DeclineInvitationsResponse, _>()?;
6441
6442 Ok(result)
6443 } else {
6444 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6445 Err(DeclineInvitationsError::from_response(response))
6446 }
6447 }
6448
6449 #[allow(unused_mut)]
6451 async fn delete_action_target(
6452 &self,
6453 input: DeleteActionTargetRequest,
6454 ) -> Result<DeleteActionTargetResponse, RusotoError<DeleteActionTargetError>> {
6455 let request_uri = format!(
6456 "/actionTargets/{action_target_arn}",
6457 action_target_arn = input.action_target_arn
6458 );
6459
6460 let mut request = SignedRequest::new("DELETE", "securityhub", &self.region, &request_uri);
6461 request.set_content_type("application/x-amz-json-1.1".to_owned());
6462
6463 let mut response = self
6464 .client
6465 .sign_and_dispatch(request)
6466 .await
6467 .map_err(RusotoError::from)?;
6468 if response.status.is_success() {
6469 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6470 let result = proto::json::ResponsePayload::new(&response)
6471 .deserialize::<DeleteActionTargetResponse, _>()?;
6472
6473 Ok(result)
6474 } else {
6475 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6476 Err(DeleteActionTargetError::from_response(response))
6477 }
6478 }
6479
6480 #[allow(unused_mut)]
6482 async fn delete_insight(
6483 &self,
6484 input: DeleteInsightRequest,
6485 ) -> Result<DeleteInsightResponse, RusotoError<DeleteInsightError>> {
6486 let request_uri = format!("/insights/{insight_arn}", insight_arn = input.insight_arn);
6487
6488 let mut request = SignedRequest::new("DELETE", "securityhub", &self.region, &request_uri);
6489 request.set_content_type("application/x-amz-json-1.1".to_owned());
6490
6491 let mut response = self
6492 .client
6493 .sign_and_dispatch(request)
6494 .await
6495 .map_err(RusotoError::from)?;
6496 if response.status.is_success() {
6497 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6498 let result = proto::json::ResponsePayload::new(&response)
6499 .deserialize::<DeleteInsightResponse, _>()?;
6500
6501 Ok(result)
6502 } else {
6503 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6504 Err(DeleteInsightError::from_response(response))
6505 }
6506 }
6507
6508 #[allow(unused_mut)]
6510 async fn delete_invitations(
6511 &self,
6512 input: DeleteInvitationsRequest,
6513 ) -> Result<DeleteInvitationsResponse, RusotoError<DeleteInvitationsError>> {
6514 let request_uri = "/invitations/delete";
6515
6516 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6517 request.set_content_type("application/x-amz-json-1.1".to_owned());
6518
6519 let encoded = Some(serde_json::to_vec(&input).unwrap());
6520 request.set_payload(encoded);
6521
6522 let mut response = self
6523 .client
6524 .sign_and_dispatch(request)
6525 .await
6526 .map_err(RusotoError::from)?;
6527 if response.status.is_success() {
6528 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6529 let result = proto::json::ResponsePayload::new(&response)
6530 .deserialize::<DeleteInvitationsResponse, _>()?;
6531
6532 Ok(result)
6533 } else {
6534 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6535 Err(DeleteInvitationsError::from_response(response))
6536 }
6537 }
6538
6539 #[allow(unused_mut)]
6541 async fn delete_members(
6542 &self,
6543 input: DeleteMembersRequest,
6544 ) -> Result<DeleteMembersResponse, RusotoError<DeleteMembersError>> {
6545 let request_uri = "/members/delete";
6546
6547 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6548 request.set_content_type("application/x-amz-json-1.1".to_owned());
6549
6550 let encoded = Some(serde_json::to_vec(&input).unwrap());
6551 request.set_payload(encoded);
6552
6553 let mut response = self
6554 .client
6555 .sign_and_dispatch(request)
6556 .await
6557 .map_err(RusotoError::from)?;
6558 if response.status.is_success() {
6559 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6560 let result = proto::json::ResponsePayload::new(&response)
6561 .deserialize::<DeleteMembersResponse, _>()?;
6562
6563 Ok(result)
6564 } else {
6565 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6566 Err(DeleteMembersError::from_response(response))
6567 }
6568 }
6569
6570 #[allow(unused_mut)]
6572 async fn describe_action_targets(
6573 &self,
6574 input: DescribeActionTargetsRequest,
6575 ) -> Result<DescribeActionTargetsResponse, RusotoError<DescribeActionTargetsError>> {
6576 let request_uri = "/actionTargets/get";
6577
6578 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6579 request.set_content_type("application/x-amz-json-1.1".to_owned());
6580
6581 let encoded = Some(serde_json::to_vec(&input).unwrap());
6582 request.set_payload(encoded);
6583
6584 let mut response = self
6585 .client
6586 .sign_and_dispatch(request)
6587 .await
6588 .map_err(RusotoError::from)?;
6589 if response.status.is_success() {
6590 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6591 let result = proto::json::ResponsePayload::new(&response)
6592 .deserialize::<DescribeActionTargetsResponse, _>()?;
6593
6594 Ok(result)
6595 } else {
6596 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6597 Err(DescribeActionTargetsError::from_response(response))
6598 }
6599 }
6600
6601 #[allow(unused_mut)]
6603 async fn describe_hub(
6604 &self,
6605 input: DescribeHubRequest,
6606 ) -> Result<DescribeHubResponse, RusotoError<DescribeHubError>> {
6607 let request_uri = "/accounts";
6608
6609 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
6610 request.set_content_type("application/x-amz-json-1.1".to_owned());
6611
6612 let mut params = Params::new();
6613 if let Some(ref x) = input.hub_arn {
6614 params.put("HubArn", x);
6615 }
6616 request.set_params(params);
6617
6618 let mut response = self
6619 .client
6620 .sign_and_dispatch(request)
6621 .await
6622 .map_err(RusotoError::from)?;
6623 if response.status.is_success() {
6624 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6625 let result = proto::json::ResponsePayload::new(&response)
6626 .deserialize::<DescribeHubResponse, _>()?;
6627
6628 Ok(result)
6629 } else {
6630 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6631 Err(DescribeHubError::from_response(response))
6632 }
6633 }
6634
6635 #[allow(unused_mut)]
6637 async fn describe_products(
6638 &self,
6639 input: DescribeProductsRequest,
6640 ) -> Result<DescribeProductsResponse, RusotoError<DescribeProductsError>> {
6641 let request_uri = "/products";
6642
6643 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
6644 request.set_content_type("application/x-amz-json-1.1".to_owned());
6645
6646 let mut params = Params::new();
6647 if let Some(ref x) = input.max_results {
6648 params.put("MaxResults", x);
6649 }
6650 if let Some(ref x) = input.next_token {
6651 params.put("NextToken", x);
6652 }
6653 request.set_params(params);
6654
6655 let mut response = self
6656 .client
6657 .sign_and_dispatch(request)
6658 .await
6659 .map_err(RusotoError::from)?;
6660 if response.status.is_success() {
6661 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6662 let result = proto::json::ResponsePayload::new(&response)
6663 .deserialize::<DescribeProductsResponse, _>()?;
6664
6665 Ok(result)
6666 } else {
6667 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6668 Err(DescribeProductsError::from_response(response))
6669 }
6670 }
6671
6672 #[allow(unused_mut)]
6674 async fn describe_standards(
6675 &self,
6676 input: DescribeStandardsRequest,
6677 ) -> Result<DescribeStandardsResponse, RusotoError<DescribeStandardsError>> {
6678 let request_uri = "/standards";
6679
6680 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
6681 request.set_content_type("application/x-amz-json-1.1".to_owned());
6682
6683 let mut params = Params::new();
6684 if let Some(ref x) = input.max_results {
6685 params.put("MaxResults", x);
6686 }
6687 if let Some(ref x) = input.next_token {
6688 params.put("NextToken", x);
6689 }
6690 request.set_params(params);
6691
6692 let mut response = self
6693 .client
6694 .sign_and_dispatch(request)
6695 .await
6696 .map_err(RusotoError::from)?;
6697 if response.status.is_success() {
6698 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6699 let result = proto::json::ResponsePayload::new(&response)
6700 .deserialize::<DescribeStandardsResponse, _>()?;
6701
6702 Ok(result)
6703 } else {
6704 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6705 Err(DescribeStandardsError::from_response(response))
6706 }
6707 }
6708
6709 #[allow(unused_mut)]
6711 async fn describe_standards_controls(
6712 &self,
6713 input: DescribeStandardsControlsRequest,
6714 ) -> Result<DescribeStandardsControlsResponse, RusotoError<DescribeStandardsControlsError>>
6715 {
6716 let request_uri = format!(
6717 "/standards/controls/{standards_subscription_arn}",
6718 standards_subscription_arn = input.standards_subscription_arn
6719 );
6720
6721 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
6722 request.set_content_type("application/x-amz-json-1.1".to_owned());
6723
6724 let mut params = Params::new();
6725 if let Some(ref x) = input.max_results {
6726 params.put("MaxResults", x);
6727 }
6728 if let Some(ref x) = input.next_token {
6729 params.put("NextToken", x);
6730 }
6731 request.set_params(params);
6732
6733 let mut response = self
6734 .client
6735 .sign_and_dispatch(request)
6736 .await
6737 .map_err(RusotoError::from)?;
6738 if response.status.is_success() {
6739 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6740 let result = proto::json::ResponsePayload::new(&response)
6741 .deserialize::<DescribeStandardsControlsResponse, _>()?;
6742
6743 Ok(result)
6744 } else {
6745 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6746 Err(DescribeStandardsControlsError::from_response(response))
6747 }
6748 }
6749
6750 #[allow(unused_mut)]
6752 async fn disable_import_findings_for_product(
6753 &self,
6754 input: DisableImportFindingsForProductRequest,
6755 ) -> Result<
6756 DisableImportFindingsForProductResponse,
6757 RusotoError<DisableImportFindingsForProductError>,
6758 > {
6759 let request_uri = format!(
6760 "/productSubscriptions/{product_subscription_arn}",
6761 product_subscription_arn = input.product_subscription_arn
6762 );
6763
6764 let mut request = SignedRequest::new("DELETE", "securityhub", &self.region, &request_uri);
6765 request.set_content_type("application/x-amz-json-1.1".to_owned());
6766
6767 let mut response = self
6768 .client
6769 .sign_and_dispatch(request)
6770 .await
6771 .map_err(RusotoError::from)?;
6772 if response.status.is_success() {
6773 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6774 let result = proto::json::ResponsePayload::new(&response)
6775 .deserialize::<DisableImportFindingsForProductResponse, _>()?;
6776
6777 Ok(result)
6778 } else {
6779 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6780 Err(DisableImportFindingsForProductError::from_response(
6781 response,
6782 ))
6783 }
6784 }
6785
6786 #[allow(unused_mut)]
6788 async fn disable_security_hub(
6789 &self,
6790 ) -> Result<DisableSecurityHubResponse, RusotoError<DisableSecurityHubError>> {
6791 let request_uri = "/accounts";
6792
6793 let mut request = SignedRequest::new("DELETE", "securityhub", &self.region, &request_uri);
6794 request.set_content_type("application/x-amz-json-1.1".to_owned());
6795
6796 let mut response = self
6797 .client
6798 .sign_and_dispatch(request)
6799 .await
6800 .map_err(RusotoError::from)?;
6801 if response.status.is_success() {
6802 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6803 let result = proto::json::ResponsePayload::new(&response)
6804 .deserialize::<DisableSecurityHubResponse, _>()?;
6805
6806 Ok(result)
6807 } else {
6808 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6809 Err(DisableSecurityHubError::from_response(response))
6810 }
6811 }
6812
6813 #[allow(unused_mut)]
6815 async fn disassociate_from_master_account(
6816 &self,
6817 ) -> Result<
6818 DisassociateFromMasterAccountResponse,
6819 RusotoError<DisassociateFromMasterAccountError>,
6820 > {
6821 let request_uri = "/master/disassociate";
6822
6823 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6824 request.set_content_type("application/x-amz-json-1.1".to_owned());
6825
6826 let mut response = self
6827 .client
6828 .sign_and_dispatch(request)
6829 .await
6830 .map_err(RusotoError::from)?;
6831 if response.status.is_success() {
6832 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6833 let result = proto::json::ResponsePayload::new(&response)
6834 .deserialize::<DisassociateFromMasterAccountResponse, _>()?;
6835
6836 Ok(result)
6837 } else {
6838 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6839 Err(DisassociateFromMasterAccountError::from_response(response))
6840 }
6841 }
6842
6843 #[allow(unused_mut)]
6845 async fn disassociate_members(
6846 &self,
6847 input: DisassociateMembersRequest,
6848 ) -> Result<DisassociateMembersResponse, RusotoError<DisassociateMembersError>> {
6849 let request_uri = "/members/disassociate";
6850
6851 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6852 request.set_content_type("application/x-amz-json-1.1".to_owned());
6853
6854 let encoded = Some(serde_json::to_vec(&input).unwrap());
6855 request.set_payload(encoded);
6856
6857 let mut response = self
6858 .client
6859 .sign_and_dispatch(request)
6860 .await
6861 .map_err(RusotoError::from)?;
6862 if response.status.is_success() {
6863 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6864 let result = proto::json::ResponsePayload::new(&response)
6865 .deserialize::<DisassociateMembersResponse, _>()?;
6866
6867 Ok(result)
6868 } else {
6869 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6870 Err(DisassociateMembersError::from_response(response))
6871 }
6872 }
6873
6874 #[allow(unused_mut)]
6876 async fn enable_import_findings_for_product(
6877 &self,
6878 input: EnableImportFindingsForProductRequest,
6879 ) -> Result<
6880 EnableImportFindingsForProductResponse,
6881 RusotoError<EnableImportFindingsForProductError>,
6882 > {
6883 let request_uri = "/productSubscriptions";
6884
6885 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6886 request.set_content_type("application/x-amz-json-1.1".to_owned());
6887
6888 let encoded = Some(serde_json::to_vec(&input).unwrap());
6889 request.set_payload(encoded);
6890
6891 let mut response = self
6892 .client
6893 .sign_and_dispatch(request)
6894 .await
6895 .map_err(RusotoError::from)?;
6896 if response.status.is_success() {
6897 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6898 let result = proto::json::ResponsePayload::new(&response)
6899 .deserialize::<EnableImportFindingsForProductResponse, _>()?;
6900
6901 Ok(result)
6902 } else {
6903 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6904 Err(EnableImportFindingsForProductError::from_response(response))
6905 }
6906 }
6907
6908 #[allow(unused_mut)]
6910 async fn enable_security_hub(
6911 &self,
6912 input: EnableSecurityHubRequest,
6913 ) -> Result<EnableSecurityHubResponse, RusotoError<EnableSecurityHubError>> {
6914 let request_uri = "/accounts";
6915
6916 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6917 request.set_content_type("application/x-amz-json-1.1".to_owned());
6918
6919 let encoded = Some(serde_json::to_vec(&input).unwrap());
6920 request.set_payload(encoded);
6921
6922 let mut response = self
6923 .client
6924 .sign_and_dispatch(request)
6925 .await
6926 .map_err(RusotoError::from)?;
6927 if response.status.is_success() {
6928 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6929 let result = proto::json::ResponsePayload::new(&response)
6930 .deserialize::<EnableSecurityHubResponse, _>()?;
6931
6932 Ok(result)
6933 } else {
6934 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6935 Err(EnableSecurityHubError::from_response(response))
6936 }
6937 }
6938
6939 #[allow(unused_mut)]
6941 async fn get_enabled_standards(
6942 &self,
6943 input: GetEnabledStandardsRequest,
6944 ) -> Result<GetEnabledStandardsResponse, RusotoError<GetEnabledStandardsError>> {
6945 let request_uri = "/standards/get";
6946
6947 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6948 request.set_content_type("application/x-amz-json-1.1".to_owned());
6949
6950 let encoded = Some(serde_json::to_vec(&input).unwrap());
6951 request.set_payload(encoded);
6952
6953 let mut response = self
6954 .client
6955 .sign_and_dispatch(request)
6956 .await
6957 .map_err(RusotoError::from)?;
6958 if response.status.is_success() {
6959 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6960 let result = proto::json::ResponsePayload::new(&response)
6961 .deserialize::<GetEnabledStandardsResponse, _>()?;
6962
6963 Ok(result)
6964 } else {
6965 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6966 Err(GetEnabledStandardsError::from_response(response))
6967 }
6968 }
6969
6970 #[allow(unused_mut)]
6972 async fn get_findings(
6973 &self,
6974 input: GetFindingsRequest,
6975 ) -> Result<GetFindingsResponse, RusotoError<GetFindingsError>> {
6976 let request_uri = "/findings";
6977
6978 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
6979 request.set_content_type("application/x-amz-json-1.1".to_owned());
6980
6981 let encoded = Some(serde_json::to_vec(&input).unwrap());
6982 request.set_payload(encoded);
6983
6984 let mut response = self
6985 .client
6986 .sign_and_dispatch(request)
6987 .await
6988 .map_err(RusotoError::from)?;
6989 if response.status.is_success() {
6990 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6991 let result = proto::json::ResponsePayload::new(&response)
6992 .deserialize::<GetFindingsResponse, _>()?;
6993
6994 Ok(result)
6995 } else {
6996 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
6997 Err(GetFindingsError::from_response(response))
6998 }
6999 }
7000
7001 #[allow(unused_mut)]
7003 async fn get_insight_results(
7004 &self,
7005 input: GetInsightResultsRequest,
7006 ) -> Result<GetInsightResultsResponse, RusotoError<GetInsightResultsError>> {
7007 let request_uri = format!(
7008 "/insights/results/{insight_arn}",
7009 insight_arn = input.insight_arn
7010 );
7011
7012 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
7013 request.set_content_type("application/x-amz-json-1.1".to_owned());
7014
7015 let mut response = self
7016 .client
7017 .sign_and_dispatch(request)
7018 .await
7019 .map_err(RusotoError::from)?;
7020 if response.status.is_success() {
7021 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7022 let result = proto::json::ResponsePayload::new(&response)
7023 .deserialize::<GetInsightResultsResponse, _>()?;
7024
7025 Ok(result)
7026 } else {
7027 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7028 Err(GetInsightResultsError::from_response(response))
7029 }
7030 }
7031
7032 #[allow(unused_mut)]
7034 async fn get_insights(
7035 &self,
7036 input: GetInsightsRequest,
7037 ) -> Result<GetInsightsResponse, RusotoError<GetInsightsError>> {
7038 let request_uri = "/insights/get";
7039
7040 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
7041 request.set_content_type("application/x-amz-json-1.1".to_owned());
7042
7043 let encoded = Some(serde_json::to_vec(&input).unwrap());
7044 request.set_payload(encoded);
7045
7046 let mut response = self
7047 .client
7048 .sign_and_dispatch(request)
7049 .await
7050 .map_err(RusotoError::from)?;
7051 if response.status.is_success() {
7052 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7053 let result = proto::json::ResponsePayload::new(&response)
7054 .deserialize::<GetInsightsResponse, _>()?;
7055
7056 Ok(result)
7057 } else {
7058 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7059 Err(GetInsightsError::from_response(response))
7060 }
7061 }
7062
7063 #[allow(unused_mut)]
7065 async fn get_invitations_count(
7066 &self,
7067 ) -> Result<GetInvitationsCountResponse, RusotoError<GetInvitationsCountError>> {
7068 let request_uri = "/invitations/count";
7069
7070 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
7071 request.set_content_type("application/x-amz-json-1.1".to_owned());
7072
7073 let mut response = self
7074 .client
7075 .sign_and_dispatch(request)
7076 .await
7077 .map_err(RusotoError::from)?;
7078 if response.status.is_success() {
7079 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7080 let result = proto::json::ResponsePayload::new(&response)
7081 .deserialize::<GetInvitationsCountResponse, _>()?;
7082
7083 Ok(result)
7084 } else {
7085 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7086 Err(GetInvitationsCountError::from_response(response))
7087 }
7088 }
7089
7090 #[allow(unused_mut)]
7092 async fn get_master_account(
7093 &self,
7094 ) -> Result<GetMasterAccountResponse, RusotoError<GetMasterAccountError>> {
7095 let request_uri = "/master";
7096
7097 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
7098 request.set_content_type("application/x-amz-json-1.1".to_owned());
7099
7100 let mut response = self
7101 .client
7102 .sign_and_dispatch(request)
7103 .await
7104 .map_err(RusotoError::from)?;
7105 if response.status.is_success() {
7106 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7107 let result = proto::json::ResponsePayload::new(&response)
7108 .deserialize::<GetMasterAccountResponse, _>()?;
7109
7110 Ok(result)
7111 } else {
7112 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7113 Err(GetMasterAccountError::from_response(response))
7114 }
7115 }
7116
7117 #[allow(unused_mut)]
7119 async fn get_members(
7120 &self,
7121 input: GetMembersRequest,
7122 ) -> Result<GetMembersResponse, RusotoError<GetMembersError>> {
7123 let request_uri = "/members/get";
7124
7125 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
7126 request.set_content_type("application/x-amz-json-1.1".to_owned());
7127
7128 let encoded = Some(serde_json::to_vec(&input).unwrap());
7129 request.set_payload(encoded);
7130
7131 let mut response = self
7132 .client
7133 .sign_and_dispatch(request)
7134 .await
7135 .map_err(RusotoError::from)?;
7136 if response.status.is_success() {
7137 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7138 let result = proto::json::ResponsePayload::new(&response)
7139 .deserialize::<GetMembersResponse, _>()?;
7140
7141 Ok(result)
7142 } else {
7143 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7144 Err(GetMembersError::from_response(response))
7145 }
7146 }
7147
7148 #[allow(unused_mut)]
7150 async fn invite_members(
7151 &self,
7152 input: InviteMembersRequest,
7153 ) -> Result<InviteMembersResponse, RusotoError<InviteMembersError>> {
7154 let request_uri = "/members/invite";
7155
7156 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
7157 request.set_content_type("application/x-amz-json-1.1".to_owned());
7158
7159 let encoded = Some(serde_json::to_vec(&input).unwrap());
7160 request.set_payload(encoded);
7161
7162 let mut response = self
7163 .client
7164 .sign_and_dispatch(request)
7165 .await
7166 .map_err(RusotoError::from)?;
7167 if response.status.is_success() {
7168 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7169 let result = proto::json::ResponsePayload::new(&response)
7170 .deserialize::<InviteMembersResponse, _>()?;
7171
7172 Ok(result)
7173 } else {
7174 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7175 Err(InviteMembersError::from_response(response))
7176 }
7177 }
7178
7179 #[allow(unused_mut)]
7181 async fn list_enabled_products_for_import(
7182 &self,
7183 input: ListEnabledProductsForImportRequest,
7184 ) -> Result<ListEnabledProductsForImportResponse, RusotoError<ListEnabledProductsForImportError>>
7185 {
7186 let request_uri = "/productSubscriptions";
7187
7188 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
7189 request.set_content_type("application/x-amz-json-1.1".to_owned());
7190
7191 let mut params = Params::new();
7192 if let Some(ref x) = input.max_results {
7193 params.put("MaxResults", x);
7194 }
7195 if let Some(ref x) = input.next_token {
7196 params.put("NextToken", x);
7197 }
7198 request.set_params(params);
7199
7200 let mut response = self
7201 .client
7202 .sign_and_dispatch(request)
7203 .await
7204 .map_err(RusotoError::from)?;
7205 if response.status.is_success() {
7206 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7207 let result = proto::json::ResponsePayload::new(&response)
7208 .deserialize::<ListEnabledProductsForImportResponse, _>()?;
7209
7210 Ok(result)
7211 } else {
7212 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7213 Err(ListEnabledProductsForImportError::from_response(response))
7214 }
7215 }
7216
7217 #[allow(unused_mut)]
7219 async fn list_invitations(
7220 &self,
7221 input: ListInvitationsRequest,
7222 ) -> Result<ListInvitationsResponse, RusotoError<ListInvitationsError>> {
7223 let request_uri = "/invitations";
7224
7225 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
7226 request.set_content_type("application/x-amz-json-1.1".to_owned());
7227
7228 let mut params = Params::new();
7229 if let Some(ref x) = input.max_results {
7230 params.put("MaxResults", x);
7231 }
7232 if let Some(ref x) = input.next_token {
7233 params.put("NextToken", x);
7234 }
7235 request.set_params(params);
7236
7237 let mut response = self
7238 .client
7239 .sign_and_dispatch(request)
7240 .await
7241 .map_err(RusotoError::from)?;
7242 if response.status.is_success() {
7243 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7244 let result = proto::json::ResponsePayload::new(&response)
7245 .deserialize::<ListInvitationsResponse, _>()?;
7246
7247 Ok(result)
7248 } else {
7249 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7250 Err(ListInvitationsError::from_response(response))
7251 }
7252 }
7253
7254 #[allow(unused_mut)]
7256 async fn list_members(
7257 &self,
7258 input: ListMembersRequest,
7259 ) -> Result<ListMembersResponse, RusotoError<ListMembersError>> {
7260 let request_uri = "/members";
7261
7262 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
7263 request.set_content_type("application/x-amz-json-1.1".to_owned());
7264
7265 let mut params = Params::new();
7266 if let Some(ref x) = input.max_results {
7267 params.put("MaxResults", x);
7268 }
7269 if let Some(ref x) = input.next_token {
7270 params.put("NextToken", x);
7271 }
7272 if let Some(ref x) = input.only_associated {
7273 params.put("OnlyAssociated", x);
7274 }
7275 request.set_params(params);
7276
7277 let mut response = self
7278 .client
7279 .sign_and_dispatch(request)
7280 .await
7281 .map_err(RusotoError::from)?;
7282 if response.status.is_success() {
7283 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7284 let result = proto::json::ResponsePayload::new(&response)
7285 .deserialize::<ListMembersResponse, _>()?;
7286
7287 Ok(result)
7288 } else {
7289 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7290 Err(ListMembersError::from_response(response))
7291 }
7292 }
7293
7294 #[allow(unused_mut)]
7296 async fn list_tags_for_resource(
7297 &self,
7298 input: ListTagsForResourceRequest,
7299 ) -> Result<ListTagsForResourceResponse, RusotoError<ListTagsForResourceError>> {
7300 let request_uri = format!("/tags/{resource_arn}", resource_arn = input.resource_arn);
7301
7302 let mut request = SignedRequest::new("GET", "securityhub", &self.region, &request_uri);
7303 request.set_content_type("application/x-amz-json-1.1".to_owned());
7304
7305 let mut response = self
7306 .client
7307 .sign_and_dispatch(request)
7308 .await
7309 .map_err(RusotoError::from)?;
7310 if response.status.is_success() {
7311 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7312 let result = proto::json::ResponsePayload::new(&response)
7313 .deserialize::<ListTagsForResourceResponse, _>()?;
7314
7315 Ok(result)
7316 } else {
7317 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7318 Err(ListTagsForResourceError::from_response(response))
7319 }
7320 }
7321
7322 #[allow(unused_mut)]
7324 async fn tag_resource(
7325 &self,
7326 input: TagResourceRequest,
7327 ) -> Result<TagResourceResponse, RusotoError<TagResourceError>> {
7328 let request_uri = format!("/tags/{resource_arn}", resource_arn = input.resource_arn);
7329
7330 let mut request = SignedRequest::new("POST", "securityhub", &self.region, &request_uri);
7331 request.set_content_type("application/x-amz-json-1.1".to_owned());
7332
7333 let encoded = Some(serde_json::to_vec(&input).unwrap());
7334 request.set_payload(encoded);
7335
7336 let mut response = self
7337 .client
7338 .sign_and_dispatch(request)
7339 .await
7340 .map_err(RusotoError::from)?;
7341 if response.status.is_success() {
7342 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7343 let result = proto::json::ResponsePayload::new(&response)
7344 .deserialize::<TagResourceResponse, _>()?;
7345
7346 Ok(result)
7347 } else {
7348 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7349 Err(TagResourceError::from_response(response))
7350 }
7351 }
7352
7353 #[allow(unused_mut)]
7355 async fn untag_resource(
7356 &self,
7357 input: UntagResourceRequest,
7358 ) -> Result<UntagResourceResponse, RusotoError<UntagResourceError>> {
7359 let request_uri = format!("/tags/{resource_arn}", resource_arn = input.resource_arn);
7360
7361 let mut request = SignedRequest::new("DELETE", "securityhub", &self.region, &request_uri);
7362 request.set_content_type("application/x-amz-json-1.1".to_owned());
7363
7364 let mut params = Params::new();
7365 for item in input.tag_keys.iter() {
7366 params.put("tagKeys", item);
7367 }
7368 request.set_params(params);
7369
7370 let mut response = self
7371 .client
7372 .sign_and_dispatch(request)
7373 .await
7374 .map_err(RusotoError::from)?;
7375 if response.status.is_success() {
7376 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7377 let result = proto::json::ResponsePayload::new(&response)
7378 .deserialize::<UntagResourceResponse, _>()?;
7379
7380 Ok(result)
7381 } else {
7382 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7383 Err(UntagResourceError::from_response(response))
7384 }
7385 }
7386
7387 #[allow(unused_mut)]
7389 async fn update_action_target(
7390 &self,
7391 input: UpdateActionTargetRequest,
7392 ) -> Result<UpdateActionTargetResponse, RusotoError<UpdateActionTargetError>> {
7393 let request_uri = format!(
7394 "/actionTargets/{action_target_arn}",
7395 action_target_arn = input.action_target_arn
7396 );
7397
7398 let mut request = SignedRequest::new("PATCH", "securityhub", &self.region, &request_uri);
7399 request.set_content_type("application/x-amz-json-1.1".to_owned());
7400
7401 let encoded = Some(serde_json::to_vec(&input).unwrap());
7402 request.set_payload(encoded);
7403
7404 let mut response = self
7405 .client
7406 .sign_and_dispatch(request)
7407 .await
7408 .map_err(RusotoError::from)?;
7409 if response.status.is_success() {
7410 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7411 let result = proto::json::ResponsePayload::new(&response)
7412 .deserialize::<UpdateActionTargetResponse, _>()?;
7413
7414 Ok(result)
7415 } else {
7416 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7417 Err(UpdateActionTargetError::from_response(response))
7418 }
7419 }
7420
7421 #[allow(unused_mut)]
7423 async fn update_findings(
7424 &self,
7425 input: UpdateFindingsRequest,
7426 ) -> Result<UpdateFindingsResponse, RusotoError<UpdateFindingsError>> {
7427 let request_uri = "/findings";
7428
7429 let mut request = SignedRequest::new("PATCH", "securityhub", &self.region, &request_uri);
7430 request.set_content_type("application/x-amz-json-1.1".to_owned());
7431
7432 let encoded = Some(serde_json::to_vec(&input).unwrap());
7433 request.set_payload(encoded);
7434
7435 let mut response = self
7436 .client
7437 .sign_and_dispatch(request)
7438 .await
7439 .map_err(RusotoError::from)?;
7440 if response.status.is_success() {
7441 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7442 let result = proto::json::ResponsePayload::new(&response)
7443 .deserialize::<UpdateFindingsResponse, _>()?;
7444
7445 Ok(result)
7446 } else {
7447 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7448 Err(UpdateFindingsError::from_response(response))
7449 }
7450 }
7451
7452 #[allow(unused_mut)]
7454 async fn update_insight(
7455 &self,
7456 input: UpdateInsightRequest,
7457 ) -> Result<UpdateInsightResponse, RusotoError<UpdateInsightError>> {
7458 let request_uri = format!("/insights/{insight_arn}", insight_arn = input.insight_arn);
7459
7460 let mut request = SignedRequest::new("PATCH", "securityhub", &self.region, &request_uri);
7461 request.set_content_type("application/x-amz-json-1.1".to_owned());
7462
7463 let encoded = Some(serde_json::to_vec(&input).unwrap());
7464 request.set_payload(encoded);
7465
7466 let mut response = self
7467 .client
7468 .sign_and_dispatch(request)
7469 .await
7470 .map_err(RusotoError::from)?;
7471 if response.status.is_success() {
7472 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7473 let result = proto::json::ResponsePayload::new(&response)
7474 .deserialize::<UpdateInsightResponse, _>()?;
7475
7476 Ok(result)
7477 } else {
7478 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7479 Err(UpdateInsightError::from_response(response))
7480 }
7481 }
7482
7483 #[allow(unused_mut)]
7485 async fn update_standards_control(
7486 &self,
7487 input: UpdateStandardsControlRequest,
7488 ) -> Result<UpdateStandardsControlResponse, RusotoError<UpdateStandardsControlError>> {
7489 let request_uri = format!(
7490 "/standards/control/{standards_control_arn}",
7491 standards_control_arn = input.standards_control_arn
7492 );
7493
7494 let mut request = SignedRequest::new("PATCH", "securityhub", &self.region, &request_uri);
7495 request.set_content_type("application/x-amz-json-1.1".to_owned());
7496
7497 let encoded = Some(serde_json::to_vec(&input).unwrap());
7498 request.set_payload(encoded);
7499
7500 let mut response = self
7501 .client
7502 .sign_and_dispatch(request)
7503 .await
7504 .map_err(RusotoError::from)?;
7505 if response.status.is_success() {
7506 let mut response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7507 let result = proto::json::ResponsePayload::new(&response)
7508 .deserialize::<UpdateStandardsControlResponse, _>()?;
7509
7510 Ok(result)
7511 } else {
7512 let response = response.buffer().await.map_err(RusotoError::HttpDispatch)?;
7513 Err(UpdateStandardsControlError::from_response(response))
7514 }
7515 }
7516}