2.11. アテステーションの検証
Red Hat build of Trustee から特定のリソースを取得するテスト Pod を作成することで、アテステーションプロセスを検証できます。
重要
この手順は、アテステーションが機能していることを確認する例です。データはメモリーダンプを使用してキャプチャーされる可能性があるため、機密データを標準 I/O に書き込まないでください。メモリーに書き込まれたデータのみが暗号化されます。
手順
test-pod.yamlマニフェストファイルを作成します。apiVersion: v1 kind: Pod metadata: name: ocp-cc-pod labels: app: ocp-cc-pod annotations: io.katacontainers.config.hypervisor.cc_init_data: <initdata_string>1 spec: runtimeClassName: kata-cc containers: - name: skr-openshift image: registry.access.redhat.com/ubi9/ubi:latest command: - sleep - "36000" securityContext: privileged: false seccompProfile: type: RuntimeDefault metadata: name: coco-test-pod labels: app: coco-test-pod annotations: io.katacontainers.config.hypervisor.cc_init_data: <initdata_string>2 spec: runtimeClassName: kata-cc containers: - name: test-container image: registry.access.redhat.com/ubi9/ubi:9.3 command: - sleep - "36000" securityContext: privileged: false seccompProfile: type: RuntimeDefault以下のコマンドを実行して Pod を作成します。
$ oc create -f test-pod.yaml次のコマンドを実行して、Pod にログインします。
$ oc exec -it ocp-cc-pod -- bash次のコマンドを実行して、Red Hat build of Trustee リソースを取得します。
$ curl http://127.0.0.1:8006/cdh/resource/default/attestation-status/status出力例
success #/