25.3. 使用 IMA 测量启用远程测试
通过 IMA 测量启用远程测试以验证系统完整性。通过从 /usr/share/ima/policies/02-keylime-remote-attestation 中部署签名的测量策略,通过对 Keylime 等工具使用 IMA 测量。
先决条件
-
签名的测量策略位于
/usr/share/ima/policies/02-keylime-remote-attestation中。
流程
部署策略:
# cp --preserve=xattr /usr/share/ima/policies/02-keylime-remote-attestation /etc/ima/ima-policy加载策略:
# echo /etc/ima/ima-policy > /sys/kernel/security/integrity/ima/policy
如果示例策略没有满足您的要求,或者您要确保只加载签名的 IMA 策略,请参阅为 UEFI 系统部署自定义签名的 IMA 策略。
验证
验证策略是否已载入:
# cat /sys/kernel/security/integrity/ima/policy