�
�S�g�i � � � d Z ddlmZ ddlZddlZddlmZ ddlmZ ddlmZ ddlm Z ddlm
Z
dd lmZ dd
lmZ ddlm
Z
ddlmZ dd
lmZ ddlZddlZddlmZ ddlmZ ddlmZ ddlmZ ddlmZ dZi dd�dd�dd�dd�dd�dd�d d!�d"d#�d$d%�d&d'�d(d)�d*d+�d,d-�d.d/�d0d1�d2d3�d4d5�d6d7d8d9d:d;d<d=d>d?� �Zi ej7 � D � �ci c] \ } }e| z |��
c}} �Zd@edAefdB�Z G dC� dDej@ e� Z! G dE� dFe!� Z" e"d(� Z# e"dG� Z$ G dH� dIejJ � Z& G dJ� dKejJ ejN � Z' G dL� dMe!� Z( e(dN� Z) e(dO� Z* e(dP� Z+ e(dQ� Z, e(dR� Z- e(dS� Z. e(dT� Z/ e(dU� Z0 G dV� dWej@ � Z1 G dX� dYejJ � Z2 G dZ� d[e2� Z3 G d\� d]ejJ � Z4 G d^� d_� Z5 ed`da�b� Z6 G dc� dae4� Z7 G dd� dee7� Z8 G df� dge7� Z9 G dh� die3� Z: G dj� dke4� Z; G dl� dme2� Z< G dn� doe4� Z= G dp� dqe=� Z> G dr� dse=� Z? G dt� due3� Z@ G dv� dwejJ � ZA G dx� dye3� ZB G dz� d{ejJ � ZC G d|� d}e4� ZD G d~� de3� ZE G d�� d�eD� ZFyc c}} w )�zACME protocol messages.� )�HashableN)�Any)�Dict)�Iterator)�List)�Mapping)�MutableMapping)�Optional)�Tuple)�Type)�TypeVar)�
challenges)�errors)�fields)�jws)�utilzurn:ietf:params:acme:error:�accountDoesNotExistz4The request specified an account that does not exist�alreadyRevokedzOThe request specified a certificate to be revoked that has already been revoked�badCSRz2The CSR is unacceptable (e.g., due to a short key)�badNoncez1The client sent an unacceptable anti-replay nonce�badPublicKeyz>The JWS was signed by a public key the server does not support�badRevocationReasonz;The revocation reason provided is not allowed by the server�badSignatureAlgorithmz@The JWS was signed with an algorithm the server does not support�caaz\Certification Authority Authorization (CAA) records forbid the CA from issuing a certificate�compoundzBSpecific error conditions are indicated in the "subproblems" array�
connectionz?The server could not connect to the client to verify the domain�dnszAThere was a problem with a DNS query during identifier validation�dnssecz4The server could not validate a DNSSEC signed domain�incorrectResponsez;Response received didn't match the challenge's requirements�invalidEmailz1The provided email for a registration was invalid�invalidContactz$The provided contact URI was invalid� malformedz!The request message was malformed�rejectedIdentifierz9The server will not issue certificates for the identifierzLThe request attempted to finalize an order that is not ready to be finalizedz,There were too many requests of a given typez(The server experienced an internal errorz=The server experienced a TLS error during domain verificationz)The client lacks sufficient authorizationz@A contact URL for an account used an unsupported protocol schemez*The server could not resolve a domain namez'An identifier is of an unsupported typez,The server requires external account binding) �
orderNotReady�rateLimited�serverInternal�tls�unauthorized�unsupportedContact�unknownHost�unsupportedIdentifier�externalAccountRequired�err�returnc �` � t | t � r| j �t | j v S y)z#Check if argument is an ACME error.F)�
isinstance�Error�typ�ERROR_PREFIX)r- s �}/build/snapcraft-certbot-29b1212f749eeba2f1dece1adfe9a83a/parts/certbot/install/lib/python3.12/site-packages/acme/messages.py�
is_acme_errorr5 A s' |