diff options
author | Sergey Poznyakoff <gray@gnu.org> | 2020-07-15 09:27:07 +0200 |
---|---|---|
committer | Sergey Poznyakoff <gray@gnu.org> | 2020-07-15 10:31:34 +0300 |
commit | 02065984894e3f78ee702ba0b4618f048bb5dcf6 (patch) | |
tree | e38891f247e20ed37dc562953339c13379605870 | |
parent | d2438466196e1567f29d5fac81c26e5a0332897b (diff) | |
download | acmeman-02065984894e3f78ee702ba0b4618f048bb5dcf6.tar.gz acmeman-02065984894e3f78ee702ba0b4618f048bb5dcf6.tar.bz2 |
Improve error reporting. Version 3.06v3.06
-rw-r--r-- | Changes | 4 | ||||
-rw-r--r-- | lib/App/Acmeman.pm | 10 |
2 files changed, 12 insertions, 2 deletions
@@ -1,6 +1,10 @@ +3.06 2020-06-15 + + - Improve error reporting + 3.05 2020-06-14 - Fix manifest 3.04 2020-06-14 diff --git a/lib/App/Acmeman.pm b/lib/App/Acmeman.pm index 84e1dda..65aac4f 100644 --- a/lib/App/Acmeman.pm +++ b/lib/App/Acmeman.pm @@ -21,13 +21,13 @@ use App::Acmeman::Config; use App::Acmeman::Domain qw(:files); use Data::Dumper; use Text::ParseWords; use App::Acmeman::Log qw(:all :sysexits); use feature 'state'; -our $VERSION = '3.05'; +our $VERSION = '3.06'; my $progdescr = "manages ACME certificates"; my $letsencrypt_root_cert_url = 'https://letsencrypt.org/certs/lets-encrypt-x3-cross-signed.pem'; @@ -554,13 +554,19 @@ sub register_domain_certificate { my $ret; while (($ret = $acme->poll_authorization($authz)) eq 'pending') { sleep 1 } if ($ret ne 'valid') { - error("$domain: can't renew certificate: authorization: $ret"); + my $text = "authorization $ret"; + if (my ($ch) = grep { $_->type() eq 'http-01' } $authz->challenges()) { + if (my $err = $ch->error()) { + $text .= ': ' . $err->to_string; + } + } + error("$domain: can't renew certificate: $text"); return 0; } } my $csr = $self->make_csr($domain, $key_size); |