diff --git a/Cargo.lock b/Cargo.lock index 9deac7e6a..bdace1857 100644 --- a/Cargo.lock +++ b/Cargo.lock @@ -1622,7 +1622,17 @@ dependencies = [ "criterion", "regex", "serde", - "tls_codec_derive", + "tls_codec_derive 0.3.0", + "zeroize", +] + +[[package]] +name = "tls_codec" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d38a1d5fcfa859f0ec2b5e111dc903890bd7dac7f34713232bf9aa4fd7cad7b2" +dependencies = [ + "tls_codec_derive 0.4.0", "zeroize", ] @@ -1633,10 +1643,21 @@ dependencies = [ "proc-macro2", "quote", "syn", - "tls_codec", + "tls_codec 0.3.1", "trybuild", ] +[[package]] +name = "tls_codec_derive" +version = "0.4.0" +source = "registry+https://github.com/rust-lang/crates.io-index" +checksum = "d8e00e3e7a54e0f1c8834ce72ed49c8487fbd3f801d8cfe1a0ad0640382f8e15" +dependencies = [ + "proc-macro2", + "quote", + "syn", +] + [[package]] name = "toml" version = "0.7.6" @@ -1932,7 +1953,7 @@ dependencies = [ "signature", "spki", "tempfile", - "tls_codec", + "tls_codec 0.4.0", "x509-cert-test-support", ] @@ -1969,9 +1990,9 @@ dependencies = [ [[package]] name = "zeroize" -version = "1.6.0" +version = "1.7.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "2a0956f1ba7c7909bfb66c2e9e4124ab6f6482560f6628b5aaeba39207c9aad9" +checksum = "525b4ec142c6b68a2d10f01f7bbf6755599ca3f81ea53b8431b7dd348f5fdb2d" dependencies = [ "zeroize_derive", ] diff --git a/x509-cert/Cargo.toml b/x509-cert/Cargo.toml index 1d49cfee5..6c4e6313f 100644 --- a/x509-cert/Cargo.toml +++ b/x509-cert/Cargo.toml @@ -23,10 +23,9 @@ spki = { version = "0.7.2", features = ["alloc"] } arbitrary = { version = "1.3", features = ["derive"], optional = true } sha1 = { version = "0.10.0", optional = true } signature = { version = "2.1.0", features = ["rand_core"], optional = true } -# TODO: Use next version of tls_codec when a verion containing the following PR is published: -# https://github.com/RustCrypto/formats/pull/1132 -# https://github.com/RustCrypto/formats/pull/1133 -tls_codec = { path = "../tls_codec", default-features = false, features = ["derive"], optional = true } +tls_codec = { version = "0.4.0", default-features = false, features = [ + "derive", +], optional = true } [dev-dependencies] hex-literal = "0.4" diff --git a/x509-cert/src/ext/pkix/sct.rs b/x509-cert/src/ext/pkix/sct.rs index 6865884e4..41c844eef 100644 --- a/x509-cert/src/ext/pkix/sct.rs +++ b/x509-cert/src/ext/pkix/sct.rs @@ -73,7 +73,7 @@ impl SignedCertificateTimestampList { /// deserialized or if there are trailing bytes after all [SerializedSct]s /// are deserialized. pub fn parse_timestamps(&self) -> Result, Error> { - let (tls_vec, rest) = TlsByteVecU16::tls_deserialize(self.0.as_bytes())?; + let (tls_vec, rest) = TlsByteVecU16::tls_deserialize_bytes(self.0.as_bytes())?; if !rest.is_empty() { return Err(tls_codec::Error::TrailingData)?; }