Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions rust-crates/libraries/dcap-rs/src/types/collateral.rs
Original file line number Diff line number Diff line change
Expand Up @@ -128,9 +128,9 @@ impl Collateral {
CollateralSol::abi_decode_params(encoded)?;

let mut pem_chain = String::new();
let tcb_pem = Pem::new(String::from("CERTIFICATE"), chain_bytes[0].to_vec().clone());
let tcb_pem = Pem::new(String::from("CERTIFICATE"), chain_bytes[0].to_vec());

let root_pem = Pem::new(String::from("CERTIFICATE"), chain_bytes[1].to_vec().clone());
let root_pem = Pem::new(String::from("CERTIFICATE"), chain_bytes[1].to_vec());

pem_chain.push_str(&encode(&tcb_pem));
pem_chain.push_str(&encode(&root_pem));
Expand Down
2 changes: 1 addition & 1 deletion rust-crates/libraries/dcap-rs/src/types/tcb_info.rs
Original file line number Diff line number Diff line change
Expand Up @@ -516,7 +516,7 @@ impl TcbStatus {

let matched_tcb_level = match_tdx_tcb(td_report, tcb_info, index)?;
tdx_tcb_status = matched_tcb_level.tcb_status;
advisory_ids = matched_tcb_level.advisory_ids.clone().unwrap_or_default();
advisory_ids = matched_tcb_level.advisory_ids.unwrap_or_default();
}

// Return the final status determination as a tuple
Expand Down
22 changes: 11 additions & 11 deletions rust-crates/libraries/qpl/src/collaterals/helper.rs
Original file line number Diff line number Diff line change
Expand Up @@ -410,7 +410,7 @@ pub fn sgx_ql_get_quote_config<P: Provider>(
let req_url = format!(
"{}/sgx/certification/{}/pckcert",
pccs_url,
collateral_version.clone(),
collateral_version,
);
let rt = tokio::runtime::Builder::new_current_thread()
.enable_all()
Expand Down Expand Up @@ -595,7 +595,7 @@ pub fn sgx_ql_get_quote_verification_collateral<P: Provider>(
pck_crl,
tcb_info_str,
enclave_id,
collateral_version.clone(),
collateral_version,
enclave_identity_str,
enclave_identity_issuer_chains_str,
all_verification_collateral,
Expand All @@ -613,7 +613,7 @@ pub fn sgx_ql_get_quote_verification_collateral<P: Provider>(
let req_url = format!(
"{}/sgx/certification/{}/pckcrl?ca={}",
pccs_url,
collateral_version.clone(),
collateral_version,
pck_ca.clone()
);
let rt = tokio::runtime::Builder::new_current_thread()
Expand Down Expand Up @@ -678,7 +678,7 @@ pub fn sgx_ql_get_quote_verification_collateral<P: Provider>(
let req_url = format!(
"{}/sgx/certification/{}/tcb?fmspc={}",
pccs_url,
collateral_version.clone(),
collateral_version,
fmspc
);
println!("req_url: {:?}", req_url);
Expand Down Expand Up @@ -770,7 +770,7 @@ pub fn sgx_ql_get_quote_verification_collateral<P: Provider>(
pck_crl.as_str(),
tcb_info_str.as_str(),
enclave_id,
collateral_version.clone(),
collateral_version,
qe_identity_str.as_str(),
enclave_identity_issuer_chains_str.as_str(),
all_verification_collateral,
Expand Down Expand Up @@ -913,7 +913,7 @@ pub fn tdx_ql_get_quote_verification_collateral<P: Provider>(
pck_crl,
tcb_info_str,
enclave_id,
collateral_version.clone(),
collateral_version,
enclave_identity_str,
enclave_identity_issuer_chains_str,
all_verification_collateral,
Expand All @@ -931,7 +931,7 @@ pub fn tdx_ql_get_quote_verification_collateral<P: Provider>(
let req_url = format!(
"{}/sgx/certification/{}/pckcrl?ca={}",
pccs_url,
collateral_version.clone(),
collateral_version,
pck_ca.clone()
);
let rt = tokio::runtime::Builder::new_current_thread()
Expand Down Expand Up @@ -996,7 +996,7 @@ pub fn tdx_ql_get_quote_verification_collateral<P: Provider>(
let req_url = format!(
"{}/tdx/certification/{}/tcb?fmspc={}",
pccs_url,
collateral_version.clone(),
collateral_version,
fmspc
);
println!("req_url: {:?}", req_url);
Expand Down Expand Up @@ -1087,7 +1087,7 @@ pub fn tdx_ql_get_quote_verification_collateral<P: Provider>(
pck_crl.as_str(),
tcb_info_str.as_str(),
enclave_id,
collateral_version.clone(),
collateral_version,
qe_identity_str.as_str(),
enclave_identity_issuer_chains_str.as_str(),
all_verification_collateral,
Expand Down Expand Up @@ -1175,7 +1175,7 @@ pub fn sgx_ql_get_qve_identity<P: Provider>(
provider,
network,
EnclaveID::QVE,
collateral_version.clone(),
collateral_version,
&qve_identity_str,
&issuer_chains_str,
None,
Expand Down Expand Up @@ -1230,7 +1230,7 @@ pub fn sgx_ql_get_qve_identity<P: Provider>(
provider,
network,
EnclaveID::QVE,
collateral_version.clone(),
collateral_version,
&qve_identity_str,
&issuer_chains_str,
None,
Expand Down
Loading