Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

manifest: Update the manifest to include some more details #61

Merged
merged 4 commits into from
Mar 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,9 @@ use which::which;

fn main() {
println!("cargo:rerun-if-changed=wrapper.h");
println!("cargo:rerun-if-changed=manifest/manifest.in.cbor");
println!("cargo:rerun-if-changed=certs/device.der");
println!("cargo:rerun-if-changed=certs/immutable.der");

// cargo:rustc-link-lib doesn't seem to support start-group/end-group
// so we manually pass the arguments
Expand Down
74 changes: 68 additions & 6 deletions manifest/manifest.in.cbor
Original file line number Diff line number Diff line change
@@ -1,6 +1,68 @@
570(
{0: [571({0: {0: [[{0: {0: 111(h'3170332E362E312E342E312E352E32310037'),
1: "Western Digital Test"}},[{1: {12: [1, 2]}, 2: [554("base64_key_X")]}]]]}})],
1: [{0: 32("https://refs.example.com/path/to/reference.corim")},
{0: 32("https://rim-revoke.example.com/path/to/revocation.xcorim")}]}
)
/ spdm-toc / 570( {
/ tagged-evidence / 0: [
571( {
/ ce.ev-triples / 0: {
/ ce.membership-triples / 0: [
[
/ environment-map / {
/ class / 0: {
/ class-id / 0:
/ tagged-oid-type / 111(h'3170332E362E312E342E312E352E32310037'), / 1.3.6.1.4.1.5127 /
/ vendor / 1: "Western Digital Test"
}
},
[
/ measurement-map / {
/ mval / 1: {
/ name / 11: "ROM",
/ spdm-indirect / 12: {
/ index / 0: [1]
}
},
/ authorised-by / 2: [
/ tagged-pkix-base64-key-type / 554("base64_key_X")
]
}
],
[
/ measurement-map / {
/ mval / 1: {
/ name / 11: "Firmware",
/ spdm-indirect / 12: {
/ index / 0: [2]
}
},
/ authorised-by / 2: [
/ tagged-pkix-base64-key-type / 554("base64_key_X")
]
}
],
[
/ measurement-map / {
/ mval / 1: {
/ svn / 1: / tagged-svn / 552(7),
/ spdm-indirect / 12: {
/ index / 0: [16]
}
},
/ authorised-by / 2: [
/ tagged-pkix-base64-key-type / 554("base64_key_X")
]
}
]
]
]
}
} )
],
/ rim-locators / 1: [
/ corim-locator-map / {
/ ** link to reference manifest ** /
0: 32("https://refs.example.com/path/to/reference.corim")
},
/ corim-locator-map / {
/ ** link to manifest revocation list ** /
0: 32("https://rim-revoke.example.com/path/to/revocation.xcorim")
}
]
} )
2 changes: 1 addition & 1 deletion src/libspdm/spdm.rs
Original file line number Diff line number Diff line change
Expand Up @@ -277,7 +277,7 @@ pub const LIBSPDM_MAX_SPDM_MSG_SIZE: u32 = 0x2000;

const OPAQUE_SIZE: usize = 0;

const LIBSPDM_MEASUREMENT_BLOCK_HASH_NUMBER: u32 = 4;
const LIBSPDM_MEASUREMENT_BLOCK_HASH_NUMBER: u32 = 2;
const LIBSPDM_MEASUREMENT_BLOCK_NUMBER: u8 =
LIBSPDM_MEASUREMENT_BLOCK_HASH_NUMBER as u8 + 1 + 1 + 1;

Expand Down