Skip to content

Commit

Permalink
Fix Edge CA and module cert CSRs to use version 0 (v1) instead of non…
Browse files Browse the repository at this point in the history
…-existent version 2 (v3). (#4904)

v3 is correct for certificates (`X509`) but not for CSRs (`X509Req`).
  • Loading branch information
arsing authored Apr 27, 2021
1 parent 8155604 commit a88f820
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 21 deletions.
40 changes: 20 additions & 20 deletions edgelet/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion edgelet/edgelet-http-workload/src/server/cert/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -209,7 +209,7 @@ fn create_csr(
) -> std::result::Result<Vec<u8>, ErrorStack> {
let mut csr = openssl::x509::X509Req::builder()?;

csr.set_version(2)?;
csr.set_version(0)?;

let mut subject_name = openssl::x509::X509Name::builder()?;
subject_name.append_entry_by_text("CN", props.common_name())?;
Expand Down

0 comments on commit a88f820

Please sign in to comment.