aboutsummaryrefslogtreecommitdiffstats
path: root/src/config.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/config.rs')
-rw-r--r--src/config.rs8
1 files changed, 8 insertions, 0 deletions
diff --git a/src/config.rs b/src/config.rs
index 23ef765..baa855b 100644
--- a/src/config.rs
+++ b/src/config.rs
@@ -12,6 +12,7 @@ pub struct Config {
pub lock_timeout: u64,
#[serde(default = "default_pinentry")]
pub pinentry: String,
+ pub client_cert_path: Option<String>,
// backcompat, no longer generated in new configs
#[serde(skip_serializing)]
pub device_id: Option<String>,
@@ -25,6 +26,7 @@ impl Default for Config {
identity_url: None,
lock_timeout: default_lock_timeout(),
pinentry: default_pinentry(),
+ client_cert_path: None,
device_id: None,
}
}
@@ -149,6 +151,12 @@ impl Config {
}
#[must_use]
+ pub fn client_cert_path(&self) -> String {
+ self.client_cert_path.clone()
+ .unwrap_or_else(|| "".to_string())
+ }
+
+ #[must_use]
pub fn server_name(&self) -> String {
self.base_url
.clone()