Changed RP logs to only error when RKP only
This error occurs when there are no attestation keys to give
and is not a true error. In meeting it was decided that the
RKP keys being empty is fine and the only time to warn when
we are on an RKP only device.
Test: Run and tested using `atest keystore2_test` for Rust test and CTS test with `atest CtsKeystoreTestCases`
Bug: 241924261
Change-Id: I234493522ac59babad1a5dd315d7070eab9da3b9
diff --git a/keystore2/src/remote_provisioning.rs b/keystore2/src/remote_provisioning.rs
index cf76bb2..00fb572 100644
--- a/keystore2/src/remote_provisioning.rs
+++ b/keystore2/src/remote_provisioning.rs
@@ -153,13 +153,11 @@
} else {
match get_rem_prov_attest_key(key.domain, caller_uid, db, &self.km_uuid) {
Err(e) => {
- log::error!(
- "In get_remote_provisioning_key_and_certs: Error occurred: {:?}",
- e
- );
if self.is_rkp_only() {
+ log::error!("Error occurred: {:?}", e);
return Err(e);
}
+ log::warn!("Error occurred: {:?}", e);
log_rkp_error_stats(
MetricsRkpError::FALL_BACK_DURING_HYBRID,
&self.security_level,