diff --git a/CHANGELOG.md b/CHANGELOG.md index 137d5a9..1200712 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -7,3 +7,6 @@ Bugfix - Fix for custom fields in enrollment 1.0.2 Handle change to Sectigo API Revocation call + +1.0.3 +Fix for JSON serialization of revocation diff --git a/sectigo-scm-caplugin/Client/SectigoClient.cs b/sectigo-scm-caplugin/Client/SectigoClient.cs index da9463c..faefc14 100644 --- a/sectigo-scm-caplugin/Client/SectigoClient.cs +++ b/sectigo-scm-caplugin/Client/SectigoClient.cs @@ -142,12 +142,12 @@ public async Task> PageCertificates(int position = 0, int size public async Task RevokeSslCertificateById(int sslId, int revcode, string revreason) { - JObject o = JObject.FromObject(new + var data = new { reasonCode = revcode, reason = revreason - }); - var response = await RestClient.PostAsJsonAsync($"api/ssl/v1/revoke/{sslId}", o); + }; + var response = await RestClient.PostAsJsonAsync($"api/ssl/v1/revoke/{sslId}", data); if (response.IsSuccessStatusCode) { return true;