]> git.proxmox.com Git - proxmox-backup.git/commitdiff
api2/config/remote: remove password from read_remote
authorDominik Csapak <d.csapak@proxmox.com>
Fri, 22 May 2020 12:51:43 +0000 (14:51 +0200)
committerDietmar Maurer <dietmar@proxmox.com>
Tue, 26 May 2020 06:49:12 +0000 (08:49 +0200)
Signed-off-by: Dominik Csapak <d.csapak@proxmox.com>
src/api2/config/remote.rs

index 731c4df63f74580ee7d3e692c6f2cfd9f310591a..8f17455dd8835f256ad78a041a1afe594574da2e 100644 (file)
@@ -131,6 +131,7 @@ pub fn read_remote(
 ) -> Result<Value, Error> {
     let (config, digest) = remote::config()?;
     let mut data = config.lookup_json("remote", &name)?;
+    data.as_object_mut().unwrap().remove("password");
     rpcenv["digest"] = proxmox::tools::digest_to_hex(&digest).into();
     Ok(data)
 }