ask
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
shimunn 2019-09-18 00:33:18 +02:00
parent 80c100d584
commit d3eb44852b
Signed by: shimun
GPG Key ID: E81D8382DC2F971B
2 changed files with 3 additions and 3 deletions

View File

@ -27,7 +27,7 @@ impl Into<Config> for EnvConfig {
device: self.device.into(),
mapper_name: self.mapper_name,
password_helper: PasswordHelper::Script(self.password_helper),
input_salt: if PathBuf::from(&self.salt).exists() {
input_salt: if PathBuf::from(&self.salt).exists() && &self.salt != "Ask" {
InputSalt::File {
path: self.salt.into(),
}
@ -135,7 +135,7 @@ pub enum PasswordHelper {
impl Default for PasswordHelper {
fn default() -> Self {
PasswordHelper::Script("plymouth ask-for-password".into())
PasswordHelper::Script("/usr/bin/systemd-ask-password --no-tty 'Please enter second factor for LUKS disk encryption!'".into())
}
}

View File

@ -105,7 +105,7 @@ fn main() -> Fido2LuksResult<()> {
}
} else {
match args.first().map(|s| s.as_ref()).unwrap() {
"addkey" => add_key_to_luks(&Config::load_default_location()?).map(|_| ()),
"addkey" => add_key_to_luks(&conf).map(|_| ()),
"setup" => setup(),
"open" if args.get(1).map(|a| &*a == "-e").unwrap_or(false) => open(
&envy::prefixed("FIDO2LUKS_")