MCPcopy Create free account
hub / github.com/Dstack-TEE/dstack / get_meta

Method get_meta

kms/src/main_service.rs:386–408  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

384 }
385
386 async fn get_meta(self) -> Result<GetMetaResponse> {
387 let bootstrap_info = fs::read_to_string(self.state.config.bootstrap_info())
388 .ok()
389 .and_then(|s| serde_json::from_str(&s).ok());
390 let info = self.state.config.auth_api.get_info().await?;
391 Ok(GetMetaResponse {
392 ca_cert: self.state.inner.root_ca.pem_cert.clone(),
393 allow_any_upgrade: self.state.inner.config.auth_api.is_dev(),
394 k256_pubkey: self
395 .state
396 .inner
397 .k256_key
398 .verifying_key()
399 .to_sec1_bytes()
400 .to_vec(),
401 bootstrap_info,
402 is_dev: self.state.config.auth_api.is_dev(),
403 kms_contract_address: info.kms_contract_address,
404 chain_id: info.chain_id,
405 gateway_app_id: info.gateway_app_id,
406 app_auth_implementation: info.app_implementation,
407 })
408 }
409
410 async fn get_kms_key(self, request: GetKmsKeyRequest) -> Result<KmsKeyResponse> {
411 self.ensure_self_allowed()

Callers 1

get_root_caMethod · 0.45

Calls 5

bootstrap_infoMethod · 0.80
cloneMethod · 0.80
is_devMethod · 0.80
to_vecMethod · 0.80
get_infoMethod · 0.45

Tested by

no test coverage detected