remotes: save passwords as base64

to avoid having arbitrary characters in the config (e.g. newlines)
note that this breaks existings configs

Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
This commit is contained in:
Dominik Csapak authored and Dietmar Maurer committed 2020-05-26 12:38:06 +02:00
1 parent 1a0d3d11d2
commit de4db62c57
2 files changed
+6 -2

No files matched your search

+1
View File
@@ -60,6 +60,7 @@ pub struct Remote {
pub host: String,
pub userid: String,
#[serde(skip_serializing_if="String::is_empty")]
#[serde(with = "proxmox::tools::serde::string_as_base64")]
pub password: String,
#[serde(skip_serializing_if="Option::is_none")]
pub fingerprint: Option<String>,