(
remote_uri: String,
cert_pem: String,
key_pem: String,
pccs_url: Option<String>,
)
| 94 | } |
| 95 | |
| 96 | pub fn new_mtls( |
| 97 | remote_uri: String, |
| 98 | cert_pem: String, |
| 99 | key_pem: String, |
| 100 | pccs_url: Option<String>, |
| 101 | ) -> Result<Self> { |
| 102 | RaClientConfig::builder() |
| 103 | .tls_no_check(true) |
| 104 | .tls_built_in_root_certs(false) |
| 105 | .remote_uri(remote_uri) |
| 106 | .tls_client_cert(cert_pem) |
| 107 | .tls_client_key(key_pem) |
| 108 | .maybe_pccs_url(pccs_url) |
| 109 | .build() |
| 110 | .into_client() |
| 111 | .context("failed to create client") |
| 112 | } |
| 113 | |
| 114 | async fn try_validate_attestation(&self, response: &Response) -> Result<()> { |
| 115 | let Some(validator) = &self.cert_validator else { |
nothing calls this directly
no test coverage detected