Decode the allowlisted summary fields.
(&self)
| 232 | |
| 233 | /// Decode the allowlisted summary fields. |
| 234 | pub fn summary(&self) -> Result<BindingAttestationSummary, BindingAttestationError> { |
| 235 | postcard::from_bytes::<BindingAttestationSummary>( |
| 236 | &self.summary_bytes[ATTESTATION_SUMMARY_MAGIC.len()..], |
| 237 | ) |
| 238 | .map_err(|error| BindingAttestationError::Malformed { |
| 239 | reason: error.to_string(), |
| 240 | }) |
| 241 | } |
| 242 | |
| 243 | /// Canonical signed summary bytes as they enter the Git tree. |
| 244 | pub fn encode(&self) -> Vec<u8> { |