fix(policy): avoid logging generated access keys (#2826)

Signed-off-by: houseme <housemecn@gmail.com>
Co-authored-by: houseme <housemecn@gmail.com>
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: loverustfs <hello@rustfs.com>
Co-authored-by: 安正超 <anzhengchao@gmail.com>
This commit is contained in:
Henry Guo
2026-05-06 20:56:27 +08:00
committed by GitHub
parent 41ba34a145
commit 4b36667ba1
+2 -2
View File
@@ -21,7 +21,7 @@ use serde_json::{Value, json};
use std::collections::HashMap;
use std::convert::TryFrom;
use time::OffsetDateTime;
use tracing::warn;
use tracing::debug;
const ACCESS_KEY_MIN_LEN: usize = 3;
const ACCESS_KEY_MAX_LEN: usize = 128;
@@ -144,7 +144,7 @@ pub fn create_new_credentials_with_metadata(
}
};
warn!("create_new_credentials_with_metadata expiration {expiration:?}, access_key: {ak}");
debug!("create_new_credentials_with_metadata expiration {expiration:?}");
let token = utils::generate_jwt(&claims, token_secret)?;