Go to main content

Oracle® ZFS Storage Appliance RESTful API 설명서, 릴리스 OS8.8.x

인쇄 보기 종료

업데이트 날짜: 2021년 8월
 
 

키 또는 인증서 업로드

CA에서 서명된 인증서가 수신되면 다음 명령을 사용하여 인증서를 업로드합니다. Content-Type 헤더에 다음 값 중 하나를 지정합니다.

application/pkix-cert
application/x-x509-ca-cert
application/x-x509-user-cert
application/x-pem-file

요청 예:

POST /api/setting/v2/certificates/system HTTP/1.1
Host: alice.example.com:215
Authorization: Basic Tm8gcGVla2luZyE=
Content-Type: application/x-pem-file

-----BEGIN CERTIFICATE-----
MIIDdTCCAl2gAwIBAgICH5cwDQYJKoZIhvcNAQELBQAwazELMAkGA1UEBhMCdXMx
...
cgfvd1NUEvSdlb2+cjRBd9uSdtLfv7H5BKTKEdOXikv9+f150MytMEo4ABt0pEyp
/KwtRsdIxmzAjmNqfQPR6eAHVfQ/CGwh6Q==
-----END CERTIFICATE-----

결과 예:

HTTP/1.1 200 OK
Date: Tue, 11 May 2021 18:04:22 GMT
Content-Type: application/json; charset=utf-8
X-Zfssa-Api-Version: 2.0
X-Zfssa-Setting-Api: 2.0
Location: /api/setting/v2/certificates/system/system-cert3-uuid
Content-Length: 987

{
    "certificate": {
        "uuid": "system-cert3-uuid",
        "type": "cert",
        "data": {
            "subject": [
                {
                    "countryName": "US"
                },
                {
                    "stateOrProvinceName": "CA"
                },
                {
                    "localityName": "Exampleton"
                },
                {
                    "organizationName": "Example Corp, Inc"
                },
                {
                    "commonName": "alice.example.com"
                }
            ],
            "issuer": [
                {
                    "countryName": "US"
                },
                {
                    "stateOrProvinceName": "AK"
                },
                {
                    "localityName": "Trustville"
                },
                {
                    "organizationName": "Totally Trustworthy Certificates, Inc"
                },
                {
                    "commonName": "Most Trusted Certificate"
                }
            ],
            "serialNumber": "64",
            "validity": {
                "notBefore": "20210520T21:08:27",
                "notAfter": "20220520T21:08:27"
            },
            "extensions": {
                "basicConstraints": {
                    "value": [
                        {
                            "CA": false
                        }
                    ]
                },
                "subjectKeyIdentifier": {
                    "value": "subjectKeyIdentifier"
                },
                "authorityKeyIdentifier": {
                    "value": [
                        {
                            "keyid": "authorityKeyIdentifier"
                        }
                    ]
                },
                "subjectAltName": {
                    "value": [
                        {
                            "DNS": "alice.example.com"
                        },
                        {
                            "IP": "alice.example.com-ipaddr"
                        }
                    ]
                }
            }
        },
        "sha1fingerprint": "sha1fingerprint",
        "href": "/api/setting/v2/certificates/system/system-cert3-uuid"
    }
}