Frontend and Desktop audit fixes (#5840)

This commit is contained in:
ConnorYoh
2026-03-02 15:44:05 +00:00
committed by GitHub
parent e9148437f6
commit afda066579
4 changed files with 524 additions and 601 deletions
+4 -4
View File
@@ -6,8 +6,8 @@ use tauri_plugin_store::StoreExt;
use tiny_http::{Response, Server};
use sha2::{Sha256, Digest};
use base64::{Engine as _, engine::general_purpose::URL_SAFE_NO_PAD};
use rand::{thread_rng, Rng};
use rand::distributions::Alphanumeric;
use rand::Rng;
use rand::distr::Alphanumeric;
const STORE_FILE: &str = "connection.json";
const USER_INFO_KEY: &str = "user_info";
@@ -524,8 +524,8 @@ pub async fn login(
/// Generate PKCE code_verifier (random 43-128 character string)
fn generate_code_verifier() -> String {
thread_rng()
.sample_iter(&Alphanumeric)
rand::rng()
.sample_iter(Alphanumeric)
.take(128)
.map(char::from)
.collect()