Hi everyone, I hope someone has played around with the new API and tried to upload a ssl certificate and key. I used the following Post request via self-written perl code:
POST https://test-lb1a.boreus.de/axapi/v3/file/ssl-cert
Authorization: A10 e12409be89bd30926fceea3c52d6c3
Content-Length: 2777
Content-Type: multipart/form-data; boundary=xYzZY
--xYzZY
Content-Disposition: form-data; name="json"; filename="json"
Content-Type: application/json
{ "ssl-cert": { "file": "wildcard.boreus.de.2016", "file-handle": "file", "action": "import" } }
--xYzZY
Content-Disposition: form-data; name="file"; filename="file"
Content-Type: text/plain
-----BEGIN CERTIFICATE-----
xxxxxx
-----END CERTIFICATE-----
--xYzZY--
But I get the following error when executing:
Client-SSL-Warning: Peer certificate not verified
{
"response": {
"status": "fail",
"err": {
"code": 1023524874,
"from": "JSON",
"msg": "Failed to handle json field \"file-handle\". JSON field cannot be handled. It might be undefined or disabled by other fields.",
"location": "ssl-cert.file-handle"
}
}
}
Now I’m confused, as to me it seems I did as mentioned in the docs.