From: Maximiliano Sandoval <m.sandoval@proxmox.com>
To: pbs-devel@lists.proxmox.com
Subject: [PATCH backup v4 3/4] client: rename password to blob
Date: Mon, 6 Jul 2026 10:02:43 +0200 [thread overview]
Message-ID: <20260706080246.108256-4-m.sandoval@proxmox.com> (raw)
In-Reply-To: <20260706080246.108256-1-m.sandoval@proxmox.com>
This is a Vec<u8> and not yet the password in its unicode form.
Signed-off-by: Maximiliano Sandoval <m.sandoval@proxmox.com>
---
pbs-client/src/tools/mod.rs | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/pbs-client/src/tools/mod.rs b/pbs-client/src/tools/mod.rs
index ca64b239e..d99215c44 100644
--- a/pbs-client/src/tools/mod.rs
+++ b/pbs-client/src/tools/mod.rs
@@ -169,8 +169,8 @@ fn get_secret_from_env(base_name: &str) -> Result<Option<String>, Error> {
fn get_secret_impl(env_variable: &str, credential_name: &str) -> Result<Option<String>, Error> {
if let Some(password) = get_secret_from_env(env_variable)? {
Ok(Some(password))
- } else if let Some(password) = get_credential(credential_name)? {
- String::from_utf8(password)
+ } else if let Some(blob) = get_credential(credential_name)? {
+ String::from_utf8(blob)
.map(Option::Some)
.map_err(|_err| format_err!("credential {credential_name} is not utf8 encoded"))
} else {
--
2.47.3
next prev parent reply other threads:[~2026-07-06 8:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-06 8:02 [PATCH backup v4 0/4] fix #7054: client: remove trailing newlines from credentials Maximiliano Sandoval
2026-07-06 8:02 ` [PATCH backup v4 1/4] " Maximiliano Sandoval
2026-07-06 8:02 ` [PATCH backup v4 2/4] docs: client: document further password constrains Maximiliano Sandoval
2026-07-06 8:02 ` Maximiliano Sandoval [this message]
2026-07-06 8:02 ` [PATCH backup v4 4/4] client: Rename get_secret_impl method Maximiliano Sandoval
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20260706080246.108256-4-m.sandoval@proxmox.com \
--to=m.sandoval@proxmox.com \
--cc=pbs-devel@lists.proxmox.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.