mirror of
https://github.com/t8y2/dbx.git
synced 2026-10-30 08:20:33 +00:00
修复:避免在连接导出和日志中泄露敏感信息 / avoid leaking connection credentials in exports and logs (#16)
* fix: redact ssh password from connection exports * test: cover redacted connection targets * fix: avoid logging connection credentials * fix(redis): support stream value preview
This commit is contained in:
@@ -459,7 +459,7 @@ export const useConnectionStore = defineStore("connection", () => {
|
||||
const { writeTextFile } = await import("@tauri-apps/plugin-fs");
|
||||
const path = await save({ filters: [{ name: "JSON", extensions: ["json"] }], defaultPath: "dbx-connections.json" });
|
||||
if (!path) return;
|
||||
const data = connections.value.map((c) => ({ ...c, password: "" }));
|
||||
const data = connections.value.map((c) => ({ ...c, password: "", ssh_password: "" }));
|
||||
await writeTextFile(path, JSON.stringify(data, null, 2));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user