blib/lib/Paws/ACM.pm untested

filter: Statementstmt 0.0% 0 / 80 Branchbran 0.0% 0 / 4 Conditioncond n/a MC/DCmcdc n/a Subroutinesub 0.0% 0 / 23 Podpod 0.0% 0 / 22 totaltotal 0.0% 0 / 129 CC 3 SCAR 11.6
CC
3
Cov
0%
ListAllCertificates
12.0
service
2.0
signing_name
2.0
CRAP 3.2
1 package Paws::ACM;
2 use Moose;
3 sub service { 'acm' }
4 sub signing_name { 'acm' }
5 sub version { '2015-12-08' }
6 sub target_prefix { 'CertificateManager' }
7 sub json_version { "1.1" }
8 has max_attempts => (is => 'ro', isa => 'Int', default => 5);
9 has retry => (is => 'ro', isa => 'HashRef', default => sub {
10 { base => 'rand', type => 'exponential', growth_factor => 2 }
11 });
12 has retriables => (is => 'ro', isa => 'ArrayRef', default => sub { [
13 ] });
14  
15 with 'Paws::API::Caller', 'Paws::API::EndpointResolver', 'Paws::Net::V4Signature', 'Paws::Net::JsonCaller';
16  
17
18 sub AddTagsToCertificate {
19 my $self = shift;
20 my $call_object = $self->new_with_coercions('Paws::ACM::AddTagsToCertificate', @_);
21 return $self->caller->do_call($self, $call_object);
22 }
23 sub DeleteCertificate {
24 my $self = shift;
25 my $call_object = $self->new_with_coercions('Paws::ACM::DeleteCertificate', @_);
26 return $self->caller->do_call($self, $call_object);
27 }
28 sub DescribeCertificate {
29 my $self = shift;
30 my $call_object = $self->new_with_coercions('Paws::ACM::DescribeCertificate', @_);
31 return $self->caller->do_call($self, $call_object);
32 }
33 sub ExportCertificate {
34 my $self = shift;
35 my $call_object = $self->new_with_coercions('Paws::ACM::ExportCertificate', @_);
36 return $self->caller->do_call($self, $call_object);
37 }
38 sub GetAccountConfiguration {
39 my $self = shift;
40 my $call_object = $self->new_with_coercions('Paws::ACM::GetAccountConfiguration', @_);
41 return $self->caller->do_call($self, $call_object);
42 }
43 sub GetCertificate {
44 my $self = shift;
45 my $call_object = $self->new_with_coercions('Paws::ACM::GetCertificate', @_);
46 return $self->caller->do_call($self, $call_object);
47 }
48 sub ImportCertificate {
49 my $self = shift;
50 my $call_object = $self->new_with_coercions('Paws::ACM::ImportCertificate', @_);
51 return $self->caller->do_call($self, $call_object);
52 }
53 sub ListCertificates {
54 my $self = shift;
55 my $call_object = $self->new_with_coercions('Paws::ACM::ListCertificates', @_);
56 return $self->caller->do_call($self, $call_object);
57 }
58 sub ListTagsForCertificate {
59 my $self = shift;
60 my $call_object = $self->new_with_coercions('Paws::ACM::ListTagsForCertificate', @_);
61 return $self->caller->do_call($self, $call_object);
62 }
63 sub PutAccountConfiguration {
64 my $self = shift;
65 my $call_object = $self->new_with_coercions('Paws::ACM::PutAccountConfiguration', @_);
66 return $self->caller->do_call($self, $call_object);
67 }
68 sub RemoveTagsFromCertificate {
69 my $self = shift;
70 my $call_object = $self->new_with_coercions('Paws::ACM::RemoveTagsFromCertificate', @_);
71 return $self->caller->do_call($self, $call_object);
72 }
73 sub RenewCertificate {
74 my $self = shift;
75 my $call_object = $self->new_with_coercions('Paws::ACM::RenewCertificate', @_);
76 return $self->caller->do_call($self, $call_object);
77 }
78 sub RequestCertificate {
79 my $self = shift;
80 my $call_object = $self->new_with_coercions('Paws::ACM::RequestCertificate', @_);
81 return $self->caller->do_call($self, $call_object);
82 }
83 sub ResendValidationEmail {
84 my $self = shift;
85 my $call_object = $self->new_with_coercions('Paws::ACM::ResendValidationEmail', @_);
86 return $self->caller->do_call($self, $call_object);
87 }
88 sub UpdateCertificateOptions {
89 my $self = shift;
90 my $call_object = $self->new_with_coercions('Paws::ACM::UpdateCertificateOptions', @_);
91 return $self->caller->do_call($self, $call_object);
92 }
93
94 sub ListAllCertificates {
95 my $self = shift;
96  
97 my $callback = shift @_ if (ref($_[0]) eq 'CODE');
98 my $result = $self->ListCertificates(@_);
99 my $next_result = $result;
100  
101 if (not defined $callback) {
102 while ($next_result->NextToken) {
103 $next_result = $self->ListCertificates(@_, NextToken => $next_result->NextToken);
104 push @{ $result->CertificateSummaryList }, @{ $next_result->CertificateSummaryList };
105 }
106 return $result;
107 } else {
108 while ($result->NextToken) {
109 $callback->($_ => 'CertificateSummaryList') foreach (@{ $result->CertificateSummaryList });
110 $result = $self->ListCertificates(@_, NextToken => $result->NextToken);
111 }
112 $callback->($_ => 'CertificateSummaryList') foreach (@{ $result->CertificateSummaryList });
113 }
114  
115 return undef
116 }
117  
118  
119 sub operations { qw/AddTagsToCertificate DeleteCertificate DescribeCertificate ExportCertificate GetAccountConfiguration GetCertificate ImportCertificate ListCertificates ListTagsForCertificate PutAccountConfiguration RemoveTagsFromCertificate RenewCertificate RequestCertificate ResendValidationEmail UpdateCertificateOptions / }
120  
121 1;
122  
123 ### main pod documentation begin ###
124  
125 =head1 NAME
126  
127 Paws::ACM - Perl Interface to AWS AWS Certificate Manager
128  
129 =head1 SYNOPSIS
130  
131 use Paws;
132  
133 my $obj = Paws->service('ACM');
134 my $res = $obj->Method(
135 Arg1 => $val1,
136 Arg2 => [ 'V1', 'V2' ],
137 # if Arg3 is an object, the HashRef will be used as arguments to the constructor
138 # of the arguments type
139 Arg3 => { Att1 => 'Val1' },
140 # if Arg4 is an array of objects, the HashRefs will be passed as arguments to
141 # the constructor of the arguments type
142 Arg4 => [ { Att1 => 'Val1' }, { Att1 => 'Val2' } ],
143 );
144  
145 =head1 DESCRIPTION
146  
147 AWS Certificate Manager
148  
149 You can use AWS Certificate Manager (ACM) to manage SSL/TLS
150 certificates for your AWS-based websites and applications. For more
151 information about using ACM, see the AWS Certificate Manager User Guide
152 (https://docs.aws.amazon.com/acm/latest/userguide/).
153  
154 For the AWS API documentation, see L<https://docs.aws.amazon.com/goto/WebAPI/acm-2015-12-08>
155  
156  
157 =head1 METHODS
158  
159 =head2 AddTagsToCertificate
160  
161 =over
162  
163 =item CertificateArn => Str
164  
165 =item Tags => ArrayRef[L<Paws::ACM::Tag>]
166  
167  
168 =back
169  
170 Each argument is described in detail in: L<Paws::ACM::AddTagsToCertificate>
171  
172 Returns: nothing
173  
174 Adds one or more tags to an ACM certificate. Tags are labels that you
175 can use to identify and organize your AWS resources. Each tag consists
176 of a C<key> and an optional C<value>. You specify the certificate on
177 input by its Amazon Resource Name (ARN). You specify the tag by using a
178 key-value pair.
179  
180 You can apply a tag to just one certificate if you want to identify a
181 specific characteristic of that certificate, or you can apply the same
182 tag to multiple certificates if you want to filter for a common
183 relationship among those certificates. Similarly, you can apply the
184 same tag to multiple resources if you want to specify a relationship
185 among those resources. For example, you can add the same tag to an ACM
186 certificate and an Elastic Load Balancing load balancer to indicate
187 that they are both used by the same website. For more information, see
188 Tagging ACM certificates
189 (https://docs.aws.amazon.com/acm/latest/userguide/tags.html).
190  
191 To remove one or more tags, use the RemoveTagsFromCertificate action.
192 To view all of the tags that have been applied to the certificate, use
193 the ListTagsForCertificate action.
194  
195  
196 =head2 DeleteCertificate
197  
198 =over
199  
200 =item CertificateArn => Str
201  
202  
203 =back
204  
205 Each argument is described in detail in: L<Paws::ACM::DeleteCertificate>
206  
207 Returns: nothing
208  
209 Deletes a certificate and its associated private key. If this action
210 succeeds, the certificate no longer appears in the list that can be
211 displayed by calling the ListCertificates action or be retrieved by
212 calling the GetCertificate action. The certificate will not be
213 available for use by AWS services integrated with ACM.
214  
215 You cannot delete an ACM certificate that is being used by another AWS
216 service. To delete a certificate that is in use, the certificate
217 association must first be removed.
218  
219  
220 =head2 DescribeCertificate
221  
222 =over
223  
224 =item CertificateArn => Str
225  
226  
227 =back
228  
229 Each argument is described in detail in: L<Paws::ACM::DescribeCertificate>
230  
231 Returns: a L<Paws::ACM::DescribeCertificateResponse> instance
232  
233 Returns detailed metadata about the specified ACM certificate.
234  
235  
236 =head2 ExportCertificate
237  
238 =over
239  
240 =item CertificateArn => Str
241  
242 =item Passphrase => Str
243  
244  
245 =back
246  
247 Each argument is described in detail in: L<Paws::ACM::ExportCertificate>
248  
249 Returns: a L<Paws::ACM::ExportCertificateResponse> instance
250  
251 Exports a private certificate issued by a private certificate authority
252 (CA) for use anywhere. The exported file contains the certificate, the
253 certificate chain, and the encrypted private 2048-bit RSA key
254 associated with the public key that is embedded in the certificate. For
255 security, you must assign a passphrase for the private key when
256 exporting it.
257  
258 For information about exporting and formatting a certificate using the
259 ACM console or CLI, see Export a Private Certificate
260 (https://docs.aws.amazon.com/acm/latest/userguide/gs-acm-export-private.html).
261  
262  
263 =head2 GetAccountConfiguration
264  
265 =over
266  
267 =item =>
268  
269  
270 =back
271  
272 Each argument is described in detail in: L<Paws::ACM::GetAccountConfiguration>
273  
274 Returns: a L<Paws::ACM::GetAccountConfigurationResponse> instance
275  
276 Returns the account configuration options associated with an AWS
277 account.
278  
279  
280 =head2 GetCertificate
281  
282 =over
283  
284 =item CertificateArn => Str
285  
286  
287 =back
288  
289 Each argument is described in detail in: L<Paws::ACM::GetCertificate>
290  
291 Returns: a L<Paws::ACM::GetCertificateResponse> instance
292  
293 Retrieves an Amazon-issued certificate and its certificate chain. The
294 chain consists of the certificate of the issuing CA and the
295 intermediate certificates of any other subordinate CAs. All of the
296 certificates are base64 encoded. You can use OpenSSL
297 (https://wiki.openssl.org/index.php/Command_Line_Utilities) to decode
298 the certificates and inspect individual fields.
299  
300  
301 =head2 ImportCertificate
302  
303 =over
304  
305 =item Certificate => Str
306  
307 =item PrivateKey => Str
308  
309 =item [CertificateArn => Str]
310  
311 =item [CertificateChain => Str]
312  
313 =item [Tags => ArrayRef[L<Paws::ACM::Tag>]]
314  
315  
316 =back
317  
318 Each argument is described in detail in: L<Paws::ACM::ImportCertificate>
319  
320 Returns: a L<Paws::ACM::ImportCertificateResponse> instance
321  
322 Imports a certificate into AWS Certificate Manager (ACM) to use with
323 services that are integrated with ACM. Note that integrated services
324 (https://docs.aws.amazon.com/acm/latest/userguide/acm-services.html)
325 allow only certificate types and keys they support to be associated
326 with their resources. Further, their support differs depending on
327 whether the certificate is imported into IAM or into ACM. For more
328 information, see the documentation for each service. For more
329 information about importing certificates into ACM, see Importing
330 Certificates
331 (https://docs.aws.amazon.com/acm/latest/userguide/import-certificate.html)
332 in the I<AWS Certificate Manager User Guide>.
333  
334 ACM does not provide managed renewal
335 (https://docs.aws.amazon.com/acm/latest/userguide/acm-renewal.html) for
336 certificates that you import.
337  
338 Note the following guidelines when importing third party certificates:
339  
340 =over
341  
342 =item *
343  
344 You must enter the private key that matches the certificate you are
345 importing.
346  
347 =item *
348  
349 The private key must be unencrypted. You cannot import a private key
350 that is protected by a password or a passphrase.
351  
352 =item *
353  
354 The private key must be no larger than 5 KB (5,120 bytes).
355  
356 =item *
357  
358 If the certificate you are importing is not self-signed, you must enter
359 its certificate chain.
360  
361 =item *
362  
363 If a certificate chain is included, the issuer must be the subject of
364 one of the certificates in the chain.
365  
366 =item *
367  
368 The certificate, private key, and certificate chain must be
369 PEM-encoded.
370  
371 =item *
372  
373 The current time must be between the C<Not Before> and C<Not After>
374 certificate fields.
375  
376 =item *
377  
378 The C<Issuer> field must not be empty.
379  
380 =item *
381  
382 The OCSP authority URL, if present, must not exceed 1000 characters.
383  
384 =item *
385  
386 To import a new certificate, omit the C<CertificateArn> argument.
387 Include this argument only when you want to replace a previously
388 imported certificate.
389  
390 =item *
391  
392 When you import a certificate by using the CLI, you must specify the
393 certificate, the certificate chain, and the private key by their file
394 names preceded by C<fileb://>. For example, you can specify a
395 certificate saved in the C<C:\temp> folder as
396 C<fileb://C:\temp\certificate_to_import.pem>. If you are making an HTTP
397 or HTTPS Query request, include these arguments as BLOBs.
398  
399 =item *
400  
401 When you import a certificate by using an SDK, you must specify the
402 certificate, the certificate chain, and the private key files in the
403 manner required by the programming language you're using.
404  
405 =item *
406  
407 The cryptographic algorithm of an imported certificate must match the
408 algorithm of the signing CA. For example, if the signing CA key type is
409 RSA, then the certificate key type must also be RSA.
410  
411 =back
412  
413 This operation returns the Amazon Resource Name (ARN)
414 (https://docs.aws.amazon.com/general/latest/gr/aws-arns-and-namespaces.html)
415 of the imported certificate.
416  
417  
418 =head2 ListCertificates
419  
420 =over
421  
422 =item [CertificateStatuses => ArrayRef[Str|Undef]]
423  
424 =item [Includes => L<Paws::ACM::Filters>]
425  
426 =item [MaxItems => Int]
427  
428 =item [NextToken => Str]
429  
430  
431 =back
432  
433 Each argument is described in detail in: L<Paws::ACM::ListCertificates>
434  
435 Returns: a L<Paws::ACM::ListCertificatesResponse> instance
436  
437 Retrieves a list of certificate ARNs and domain names. You can request
438 that only certificates that match a specific status be listed. You can
439 also filter by specific attributes of the certificate. Default
440 filtering returns only C<RSA_2048> certificates. For more information,
441 see Filters.
442  
443  
444 =head2 ListTagsForCertificate
445  
446 =over
447  
448 =item CertificateArn => Str
449  
450  
451 =back
452  
453 Each argument is described in detail in: L<Paws::ACM::ListTagsForCertificate>
454  
455 Returns: a L<Paws::ACM::ListTagsForCertificateResponse> instance
456  
457 Lists the tags that have been applied to the ACM certificate. Use the
458 certificate's Amazon Resource Name (ARN) to specify the certificate. To
459 add a tag to an ACM certificate, use the AddTagsToCertificate action.
460 To delete a tag, use the RemoveTagsFromCertificate action.
461  
462  
463 =head2 PutAccountConfiguration
464  
465 =over
466  
467 =item IdempotencyToken => Str
468  
469 =item [ExpiryEvents => L<Paws::ACM::ExpiryEventsConfiguration>]
470  
471  
472 =back
473  
474 Each argument is described in detail in: L<Paws::ACM::PutAccountConfiguration>
475  
476 Returns: nothing
477  
478 Adds or modifies account-level configurations in ACM.
479  
480 The supported configuration option is C<DaysBeforeExpiry>. This option
481 specifies the number of days prior to certificate expiration when ACM
482 starts generating C<EventBridge> events. ACM sends one event per day
483 per certificate until the certificate expires. By default, accounts
484 receive events starting 45 days before certificate expiration.
485  
486  
487 =head2 RemoveTagsFromCertificate
488  
489 =over
490  
491 =item CertificateArn => Str
492  
493 =item Tags => ArrayRef[L<Paws::ACM::Tag>]
494  
495  
496 =back
497  
498 Each argument is described in detail in: L<Paws::ACM::RemoveTagsFromCertificate>
499  
500 Returns: nothing
501  
502 Remove one or more tags from an ACM certificate. A tag consists of a
503 key-value pair. If you do not specify the value portion of the tag when
504 calling this function, the tag will be removed regardless of value. If
505 you specify a value, the tag is removed only if it is associated with
506 the specified value.
507  
508 To add tags to a certificate, use the AddTagsToCertificate action. To
509 view all of the tags that have been applied to a specific ACM
510 certificate, use the ListTagsForCertificate action.
511  
512  
513 =head2 RenewCertificate
514  
515 =over
516  
517 =item CertificateArn => Str
518  
519  
520 =back
521  
522 Each argument is described in detail in: L<Paws::ACM::RenewCertificate>
523  
524 Returns: nothing
525  
526 Renews an eligible ACM certificate. At this time, only exported private
527 certificates can be renewed with this operation. In order to renew your
528 ACM PCA certificates with ACM, you must first grant the ACM service
529 principal permission to do so
530 (https://docs.aws.amazon.com/acm-pca/latest/userguide/PcaPermissions.html).
531 For more information, see Testing Managed Renewal
532 (https://docs.aws.amazon.com/acm/latest/userguide/manual-renewal.html)
533 in the ACM User Guide.
534  
535  
536 =head2 RequestCertificate
537  
538 =over
539  
540 =item DomainName => Str
541  
542 =item [CertificateAuthorityArn => Str]
543  
544 =item [DomainValidationOptions => ArrayRef[L<Paws::ACM::DomainValidationOption>]]
545  
546 =item [IdempotencyToken => Str]
547  
548 =item [Options => L<Paws::ACM::CertificateOptions>]
549  
550 =item [SubjectAlternativeNames => ArrayRef[Str|Undef]]
551  
552 =item [Tags => ArrayRef[L<Paws::ACM::Tag>]]
553  
554 =item [ValidationMethod => Str]
555  
556  
557 =back
558  
559 Each argument is described in detail in: L<Paws::ACM::RequestCertificate>
560  
561 Returns: a L<Paws::ACM::RequestCertificateResponse> instance
562  
563 Requests an ACM certificate for use with other AWS services. To request
564 an ACM certificate, you must specify a fully qualified domain name
565 (FQDN) in the C<DomainName> parameter. You can also specify additional
566 FQDNs in the C<SubjectAlternativeNames> parameter.
567  
568 If you are requesting a private certificate, domain validation is not
569 required. If you are requesting a public certificate, each domain name
570 that you specify must be validated to verify that you own or control
571 the domain. You can use DNS validation
572 (https://docs.aws.amazon.com/acm/latest/userguide/gs-acm-validate-dns.html)
573 or email validation
574 (https://docs.aws.amazon.com/acm/latest/userguide/gs-acm-validate-email.html).
575 We recommend that you use DNS validation. ACM issues public
576 certificates after receiving approval from the domain owner.
577  
578  
579 =head2 ResendValidationEmail
580  
581 =over
582  
583 =item CertificateArn => Str
584  
585 =item Domain => Str
586  
587 =item ValidationDomain => Str
588  
589  
590 =back
591  
592 Each argument is described in detail in: L<Paws::ACM::ResendValidationEmail>
593  
594 Returns: nothing
595  
596 Resends the email that requests domain ownership validation. The domain
597 owner or an authorized representative must approve the ACM certificate
598 before it can be issued. The certificate can be approved by clicking a
599 link in the mail to navigate to the Amazon certificate approval website
600 and then clicking B<I Approve>. However, the validation email can be
601 blocked by spam filters. Therefore, if you do not receive the original
602 mail, you can request that the mail be resent within 72 hours of
603 requesting the ACM certificate. If more than 72 hours have elapsed
604 since your original request or since your last attempt to resend
605 validation mail, you must request a new certificate. For more
606 information about setting up your contact email addresses, see
607 Configure Email for your Domain
608 (https://docs.aws.amazon.com/acm/latest/userguide/setup-email.html).
609  
610  
611 =head2 UpdateCertificateOptions
612  
613 =over
614  
615 =item CertificateArn => Str
616  
617 =item Options => L<Paws::ACM::CertificateOptions>
618  
619  
620 =back
621  
622 Each argument is described in detail in: L<Paws::ACM::UpdateCertificateOptions>
623  
624 Returns: nothing
625  
626 Updates a certificate. Currently, you can use this function to specify
627 whether to opt in to or out of recording your certificate in a
628 certificate transparency log. For more information, see Opting Out of
629 Certificate Transparency Logging
630 (https://docs.aws.amazon.com/acm/latest/userguide/acm-bestpractices.html#best-practices-transparency).
631  
632  
633  
634  
635 =head1 PAGINATORS
636  
637 Paginator methods are helpers that repetively call methods that return partial results
638  
639 =head2 ListAllCertificates(sub { },[CertificateStatuses => ArrayRef[Str|Undef], Includes => L<Paws::ACM::Filters>, MaxItems => Int, NextToken => Str])
640  
641 =head2 ListAllCertificates([CertificateStatuses => ArrayRef[Str|Undef], Includes => L<Paws::ACM::Filters>, MaxItems => Int, NextToken => Str])
642  
643  
644 If passed a sub as first parameter, it will call the sub for each element found in :
645  
646 - CertificateSummaryList, passing the object as the first parameter, and the string 'CertificateSummaryList' as the second parameter
647  
648 If not, it will return a a L<Paws::ACM::ListCertificatesResponse> instance with all the C<param>s; from all the responses. Please take into account that this mode can potentially consume vasts ammounts of memory.
649  
650  
651  
652  
653  
654 =head1 SEE ALSO
655  
656 This service class forms part of L<Paws>
657  
658 =head1 BUGS and CONTRIBUTIONS
659  
660 The source code is located here: L<https://github.com/pplu/aws-sdk-perl>
661  
662 Please report bugs to: L<https://github.com/pplu/aws-sdk-perl/issues>
663  
664 =cut
665