Skip to content
Snippets Groups Projects
Commit 424d1e0b authored by Jean-Michel Picod's avatar Jean-Michel Picod
Browse files

Rename "today" to "now" to reflects resolution is seconds.

parent 035609ec
No related branches found
No related tags found
No related merge requests found
...@@ -64,9 +64,9 @@ fn main() { ...@@ -64,9 +64,9 @@ fn main() {
.public_key() .public_key()
.unwrap() .unwrap()
.public_eq(&PKey::from_ec_key(pkey).unwrap())); .public_eq(&PKey::from_ec_key(pkey).unwrap()));
let today = asn1::Asn1Time::days_from_now(0).unwrap(); let now = asn1::Asn1Time::days_from_now(0).unwrap();
assert!(cert.not_after() > today); assert!(cert.not_after() > now);
assert!(cert.not_before() <= today); assert!(cert.not_before() <= now);
let mut cert_bin_file = File::create(&cert_bin_path).unwrap(); let mut cert_bin_file = File::create(&cert_bin_path).unwrap();
cert_bin_file.write_all(&cert.to_der().unwrap()).unwrap(); cert_bin_file.write_all(&cert.to_der().unwrap()).unwrap();
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment