We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 46327a4 commit 1a79570Copy full SHA for 1a79570
crates/mcp/oauth/token.rs
@@ -57,8 +57,8 @@ pub struct TokenResponse {
57
58
/// Generate an opaque refresh token.
59
fn generate_refresh_token() -> String {
60
- use rand::Rng as _;
61
- let bytes: [u8; 32] = rand::rng().random();
+ let mut bytes = [0u8; 32];
+ rand::fill(&mut bytes);
62
base64::engine::general_purpose::URL_SAFE_NO_PAD.encode(bytes)
63
}
64
0 commit comments