이 엔드포인트를 사용하여 주문에 대한 취약성 평가를 사용합니다.
URL의 {{order_id}}
를 주문의 ID로 바꿉니다. 계정의 주문에 대한 ID 값을 받으려면 주문 목록 엔드포인트를 사용합니다.
주문에 대한 취약성 평가를 사용으로 설정하면 검사 서비스는 자동으로 검사해야 하는 인증서의 적합한 도메인을 큐에 추가합니다. 검사가 완료되면 결과 다운로드 엔드포인트를 사용하여 평가 결과와 함께 PDF를 다운로드합니다.
curl -X PUT \
https://www.digicert.com/services/v2/vulnerability-assessment/{{order_id}}/scan \
-H 'Content-Type: application/json' \
-H 'X-DC-DEVKEY: {{api_key}}'
import requests
url = "https://www.digicert.com/services/v2/vulnerability-assessment/{{order_id}}/scan"
payload = {}
headers = {
'Content-Type': 'application/json',
'X-DC-DEVKEY': '{{api_key}}'
}
response = requests.request("PUT", url, headers=headers, data = payload)
print(response.text.encode('utf8'))
package main
import (
"fmt"
"net/http"
"io/ioutil"
)
func main() {
url := "https://www.digicert.com/services/v2/vulnerability-assessment/{{order_id}}/scan"
method := "PUT"
client := &http.Client {
}
req, err := http.NewRequest(method, url, nil)
if err != nil {
fmt.Println(err)
}
req.Header.Add("Content-Type", "application/json")
req.Header.Add("X-DC-DEVKEY", "api_key")
res, err := client.Do(req)
defer res.Body.Close()
body, err := ioutil.ReadAll(res.Body)
fmt.Println(string(body))
}
var request = require('request');
var options = {
'method': 'PUT',
'url': 'https://www.digicert.com/services/v2/vulnerability-assessment/{{order_id}}/scan',
'headers': {
'Content-Type': 'application/json',
'X-DC-DEVKEY': '{{api_key}}'
}
};
request(options, function (error, response) {
if (error) throw new Error(error);
console.log(response.body);
});
// empty
{
"errors": [
{
"code": "not_found|route",
"message": "The specified route was not found."
}
]
}
{
"errors": [
{
"code": "access_denied",
"message": "You do not have permission to manage this request."
}
]
}
{
"errors": [
{
"code": "va_not_eligible_order",
"message": "Invalid order status. Order must be issued, not revoked, expired, or pending."
}
]
}
{
"errors": [
{
"code": "va_not_eligible_product",
"message": "Invalid certificate type. Vulnerability assessment is only available for Secure Site EV and Secure Site Pro certificates."
}
]
}