Skip to content

Commit

Permalink
Prompt for password only if / when we're signing w/ the openssl ca.
Browse files Browse the repository at this point in the history
  • Loading branch information
flihp committed Mar 27, 2024
1 parent b8c878e commit dcc2623
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions dice-mfg/src/main.rs
Original file line number Diff line number Diff line change
Expand Up @@ -284,6 +284,7 @@ fn generate_cert(
) -> Result<()> {
match ca {
CertificateAuthority::Openssl(cfg) => {
passwd_to_env()?;
let cfg = OpensslCaOpts::try_from(cfg)?;
let cert_signer = CertSignerBuilder::new(cfg.ca_root)
.set_auth_id(auth_id)
Expand Down Expand Up @@ -373,7 +374,6 @@ fn main() -> Result<()> {
require_release_policy,
ca,
} => {
passwd_to_env()?;
let mut driver = driver.unwrap();

driver.ping()?;
Expand Down Expand Up @@ -448,10 +448,7 @@ fn main() -> Result<()> {
cert_out,
csr_in,
ca,
} => {
passwd_to_env()?;
generate_cert(auth_id, &csr_in, &cert_out, ca)
}
} => generate_cert(auth_id, &csr_in, &cert_out, ca),
Command::DumpLogEntries { auth_id } => {
passwd_to_env()?;
let index = dice_mfg::get_log_entries(auth_id)?;
Expand Down

0 comments on commit dcc2623

Please sign in to comment.