2using System.Collections.Generic;
3using System.Threading.Tasks;
51 private readonly DateTime? expires =
null;
53 private readonly
string type =
null;
54 private readonly
string value =
null;
55 private readonly
bool? wildcard =
null;
60 foreach (KeyValuePair<string, object> P
in Obj)
65 if (!Enum.TryParse(P.Value as
string, out
this.status))
66 throw new ArgumentException(
"Invalid ACME authorization status: " + P.Value.ToString(),
"status");
70 if (
XML.
TryParse(P.Value as
string, out DateTime TP))
73 throw new ArgumentException(
"Invalid date and time value.",
"expires");
77 if (P.Value is IEnumerable<KeyValuePair<string, object>> Obj2)
79 foreach (KeyValuePair<string, object> P2
in Obj2)
84 this.type = P2.Value as string;
88 this.value = P2.Value as string;
96 if (P.Value is Array A2)
98 List<AcmeChallenge>
Challenges =
new List<AcmeChallenge>();
100 foreach (
object Obj3
in A2)
102 if (Obj3 is IEnumerable<KeyValuePair<string, object>> Obj4)
114 throw new ArgumentException(
"Invalid boolean value.",
"wildcard");
123 public string Type => this.type;
156 public Task<AcmeAuthorization>
Poll()
Helps with parsing of commong data types.
static bool TryParse(string s, out double Value)
Tries to decode a string encoded double.
Helps with common XML-related tasks.
static bool TryParse(string s, out DateTime Value)
Tries to decode a string encoded DateTime.
Represents an ACME authorization.
Task< AcmeAuthorization > Poll()
Gets the current state of the order.
string Value
The identifier itself.
Task< AcmeAuthorization > Deactivate()
Deactivates the authorization.
AcmeChallenge[] Challenges
For pending authorizations, the challenges that the client can fulfill in order to prove possession o...
bool? Wildcard
For authorizations created as a result of a newOrder request containing a DNS identifier with a value...
string Type
The type of identifier.
AcmeAuthorizationStatus Status
The status of this authorization.
DateTime? Expires
The timestamp after which the server will consider this authorization invalid
Base class of all ACME challenges.
Implements an ACME client for the generation of certificates using ACME-compliant certificate servers...
async Task< AcmeAuthorization > DeactivateAuthorization(Uri AccountLocation, Uri AuthorizationLocation)
Deactivates an authorization.
async Task< AcmeAuthorization > GetAuthorization(Uri AccountLocation, Uri AuthorizationLocation)
Gets the state of an authorization.
AcmeClient Client
ACME client.
Abstract base class for all ACME resources.
Uri Location
Location of resource.
Uri AccountLocation
Account location.
AcmeAuthorizationStatus
ACME Authorization status enumeration