diff --git a/certbot/certbot/_internal/auth_handler.py b/certbot/certbot/_internal/auth_handler.py index 747520a7d..de41f7e4d 100644 --- a/certbot/certbot/_internal/auth_handler.py +++ b/certbot/certbot/_internal/auth_handler.py @@ -384,7 +384,8 @@ def challb_to_achall(challb: messages.ChallengeBody, account_key: josepy.JWK, challb=challb, domain=domain, account_key=account_key) elif isinstance(chall, challenges.DNS): return achallenges.DNS(challb=challb, domain=domain) - raise errors.Error(f"Received unsupported challenge of type: {chall.typ}") + else: + return achallenges.Other(challb=challb, domain=domain) def gen_challenge_path(challbs: List[messages.ChallengeBody], diff --git a/certbot/certbot/achallenges.py b/certbot/certbot/achallenges.py index 081fa1c46..fb2deaa70 100644 --- a/certbot/certbot/achallenges.py +++ b/certbot/certbot/achallenges.py @@ -59,3 +59,9 @@ class DNS(AnnotatedChallenge): """Client annotated "dns" ACME challenge.""" __slots__ = ('challb', 'domain') # pylint: disable=redefined-slots-in-subclass acme_type = challenges.DNS + + +class Other(AnnotatedChallenge): + """Client annotated ACME challenge of an unknown type.""" + __slots__ = ('challb', 'domain') # pylint: disable=redefined-slots-in-subclass + acme_type = challenges.Challenge