Skip to content

Commit 39a3a31

Browse files
Copilotkvinwang
andauthored
feat(kms): warn at startup when self-authorization is disabled
Agent-Logs-Url: https://github.com/Dstack-TEE/dstack/sessions/45dd268c-01c8-4e86-bd8f-978cbb70dff7 Co-authored-by: kvinwang <6442159+kvinwang@users.noreply.github.com>
1 parent 0e325c1 commit 39a3a31

1 file changed

Lines changed: 4 additions & 1 deletion

File tree

kms/src/main_service.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ use ra_tls::{
2626
use scale::Decode;
2727
use sha2::Digest;
2828
use tokio::sync::OnceCell;
29-
use tracing::info;
29+
use tracing::{info, warn};
3030
use upgrade_authority::{build_boot_info, local_kms_boot_info, BootInfo};
3131

3232
use crate::{
@@ -76,6 +76,9 @@ impl KmsState {
7676
config.image.download_timeout,
7777
config.pccs_url.clone(),
7878
);
79+
if !config.enforce_self_authorization {
80+
warn!("self-authorization is disabled; trusted RPCs will not be gated by KMS self-attestation - do not use in production TEE deployments");
81+
}
7982
Ok(Self {
8083
inner: Arc::new(KmsStateInner {
8184
config,

0 commit comments

Comments
 (0)