Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This patch convers the measurement OID to be BER encoded. I used the following diff to generate the DER encoded data ```diff diff --git a/src/main.rs b/src/main.rs index 181ca0f..077ecc3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -8,6 +8,8 @@ //! (which is generated from here) or the README //! +use asn1_rs::oid; +use asn1_rs::ToDer; use async_std::task; use clap::{Parser, Subcommand}; use futures::future::join_all; @@ -629,6 +631,10 @@ fn init_logger() { #[async_std::main] async fn main() -> Result<(), ()> { init_logger(); + + let oid = oid!(1.3.6.1.4.1.5127); + panic!("OID: {:x?}", oid.to_der_vec()); + let cli = Args::parse(); let cntx_ptr = spdm::initialise_spdm_context(); ``` As DER is a subset of BER [1] we can use the DER output directly. 1: openssl/openssl#7751 (comment) Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
- Loading branch information