移除SSH密钥入口并固定密码认证

This commit is contained in:
xuans committed 2026-10-02 06:58:22 +08:00
1 parent fb1e36313b
commit 626de357ba
5 files changed
+3 -7

No files matched your search

@@ -518,7 +518,6 @@ export function useDashboard() {
address: serverForm.value.address,
port: Number(serverForm.value.port),
username: serverForm.value.username,
auth_method: "password",
host_key_fingerprint: serverForm.value.host_key_fingerprint,
certificate_path: serverForm.value.certificate_path,
private_key_path: serverForm.value.private_key_path,
@@ -328,8 +328,8 @@ test("部署服务器仅使用密码认证且不暴露私钥管理入口", async
state.serverForm.value.host_key_fingerprint = "SHA256:test";
await state.saveServer();
const payload = JSON.parse(requests.at(-1).body);
assert.equal(payload.auth_method, "password");
assert.equal(payload.password, "test-password");
assert.equal("auth_method" in payload, false);
assert.equal("private_key_ref" in payload, false);
});