Skip to content

Commit f47a5e8

Browse files
committed
x509-cert: fixup dependencies versions
1 parent f59dddc commit f47a5e8

File tree

2 files changed

+4
-5
lines changed

2 files changed

+4
-5
lines changed

x509-cert/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ rust-version = "1.65"
1717
[dependencies]
1818
const-oid = { version = "0.9.2", features = ["db"] } # TODO: path = "../const-oid"
1919
der = { version = "0.7.3", features = ["alloc", "derive", "flagset", "oid"], path = "../der" }
20-
spki = { version = "0.7", path = "../spki", features = ["alloc"] }
20+
spki = { version = "0.7.1", path = "../spki", features = ["alloc"] }
2121

2222
# optional dependencies
2323
arbitrary = { version = "1.2", features = ["derive"], optional = true }

x509-cert/src/builder.rs

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -260,6 +260,7 @@ impl From<CertificateVersion> for Version {
260260
/// use x509_cert::name::Name;
261261
/// use x509_cert::serial_number::SerialNumber;
262262
/// use x509_cert::time::Validity;
263+
/// use std::str::FromStr;
263264
///
264265
/// # const RSA_2048_DER: &[u8] = include_bytes!("../tests/examples/rsa2048-pub.der");
265266
/// # const RSA_2048_PRIV_DER: &[u8] = include_bytes!("../tests/examples/rsa2048-priv.der");
@@ -281,10 +282,8 @@ impl From<CertificateVersion> for Version {
281282
/// let serial_number = SerialNumber::from(42u32);
282283
/// let validity = Validity::from_now(Duration::new(5, 0)).unwrap();
283284
/// let profile = Profile::Root;
284-
/// let subject =
285-
/// Name::encode_from_string("CN=World domination corporation,O=World domination Inc,C=US")
286-
/// .unwrap();
287-
/// let subject = Name::from_der(&subject).unwrap();
285+
/// let subject = Name::from_str("CN=World domination corporation,O=World domination Inc,C=US").unwrap();
286+
///
288287
/// let pub_key = SubjectPublicKeyInfoOwned::try_from(RSA_2048_DER).expect("get rsa pub key");
289288
///
290289
/// let mut signer = rsa_signer();

0 commit comments

Comments
 (0)