diff --git a/HIRS_AttestationCAPortal/src/main/java/hirs/attestationca/portal/page/controllers/ReferenceManifestDetailsPageController.java b/HIRS_AttestationCAPortal/src/main/java/hirs/attestationca/portal/page/controllers/ReferenceManifestDetailsPageController.java index 65298a58..41ac09ed 100644 --- a/HIRS_AttestationCAPortal/src/main/java/hirs/attestationca/portal/page/controllers/ReferenceManifestDetailsPageController.java +++ b/HIRS_AttestationCAPortal/src/main/java/hirs/attestationca/portal/page/controllers/ReferenceManifestDetailsPageController.java @@ -24,7 +24,6 @@ import java.util.HashMap; import java.util.LinkedList; import java.util.List; import java.util.ArrayList; -import java.util.Map; import java.util.Set; import java.util.UUID; @@ -324,6 +323,20 @@ public class ReferenceManifestDetailsPageController data.put("associatedRim", support.getAssociatedRim()); data.put("rimType", support.getRimType()); data.put("tagId", support.getTagId()); + boolean crtm = false; + boolean bootManager = false; + boolean osLoader = false; + boolean osKernel = false; + boolean acpiTables = false; + boolean smbiosTables = false; + boolean gptTable = false; + boolean bootOrder = false; + boolean defaultBootDevice = false; + boolean secureBoot = false; + boolean pk = false; + boolean kek = false; + boolean sigDb = false; + boolean forbiddenDbx = false; TCGEventLog logProcessor = new TCGEventLog(support.getRimBytes()); LinkedList tpmPcrEvents = new LinkedList<>(); @@ -343,6 +356,61 @@ public class ReferenceManifestDetailsPageController data.put("events", logProcessor.getEventList()); } + String contentStr; + for (TpmPcrEvent tpe : logProcessor.getEventList()) { + contentStr = tpe.getEventContentStr(); + // check for specific events + if (contentStr.contains("CRTM")) { + crtm = true; + } else if (contentStr.contains("shimx64.efi") + || contentStr.contains("bootmgfw.efi")) { + bootManager = true; + } else if (contentStr.contains("grubx64.efi") + || contentStr.contains("winload.efi")) { + osLoader = true; + } else if (contentStr.contains("vmlinuz") + || contentStr.contains("ntoskrnl.exe")) { + osKernel = true; + } else if (contentStr.contains("ACPI")) { + acpiTables = true; + } else if (contentStr.contains("SMBIOS")) { + smbiosTables = true; + } else if (contentStr.contains("GPT")) { + gptTable = true; + } else if (contentStr.contains("BootOrder")) { + bootOrder = true; + } else if (contentStr.contains("Boot0000")) { + defaultBootDevice = true; + } else if (contentStr.contains("variable named PK")) { + pk = true; + } else if (contentStr.contains("variable named KEK")) { + kek = true; + } else if (contentStr.contains("variable named db")) { + if (contentStr.contains("dbx")) { + forbiddenDbx = true; + } else { + sigDb = true; + } + } else if (contentStr.contains("Secure Boot is enabled")) { + secureBoot = true; + } + } + + data.put("crtm", crtm); + data.put("bootManager", bootManager); + data.put("osLoader", osLoader); + data.put("osKernel", osKernel); + data.put("acpiTables", acpiTables); + data.put("smbiosTables", smbiosTables); + data.put("gptTable", gptTable); + data.put("bootOrder", bootOrder); + data.put("defaultBootDevice", defaultBootDevice); + data.put("secureBoot", secureBoot); + data.put("pk", pk); + data.put("kek", kek); + data.put("sigDb", sigDb); + data.put("forbiddenDbx", forbiddenDbx); + return data; } @@ -407,10 +475,6 @@ public class ReferenceManifestDetailsPageController data.put("supportEvents", supportEvents); data.put("livelogEvents", livelogEvents); - for (Map.Entry entry : data.entrySet()) { - LOGGER.error(String.format("%s -> %s", entry.getKey(), - String.valueOf(entry.getValue()))); - } return data; } } diff --git a/HIRS_AttestationCAPortal/src/main/webapp/WEB-INF/jsp/rim-details.jsp b/HIRS_AttestationCAPortal/src/main/webapp/WEB-INF/jsp/rim-details.jsp index 558dcb44..ecdd813d 100644 --- a/HIRS_AttestationCAPortal/src/main/webapp/WEB-INF/jsp/rim-details.jsp +++ b/HIRS_AttestationCAPortal/src/main/webapp/WEB-INF/jsp/rim-details.jsp @@ -17,13 +17,13 @@ - - - - - - -
+ + + + + + +
@@ -41,297 +41,437 @@
-
-
- - - - - - - - - - - - - - - - - +
+ +
+ +
+
+ +
+
+
Event #PCR IndexEvent TypeDigestEvent Content
+ + + + + + + + + + + + + + + + - + - - - - - - - - - - -
Event #PCR IndexEvent TypeDigestEvent Content
${count}PCR${event.getPcrIndex()}${event.getEventTypeStr()}${event.getEventDigestStr()}
${event.getEventContentStr()}
-
-
${initialData.events.size()} entries
- - -
-
-
Base/Support
-
- - - - - - -
+ ${count} + PCR${event.getPcrIndex()} + ${event.getEventTypeStr()} + ${event.getEventDigestStr()} +
${event.getEventContentStr()}
+ + + + + + +
+
${initialData.events.size()} entries
+ + +
+
+
Base/Support
+
+ + + + + +
-
-
-
-
Support
- - -
-
-
Event#:
-
${sEvent.getEventNumber()}
-
-
-
PCR Index:
-
${sEvent.getPcrIndex()}
-
-
-
Digest:
-
${sEvent.getEventDigestStr()}
-
-
-
Content:
-
${sEvent.getEventContentStr()}
-
+
+
+
+
+
Support
+ + +
+
+
Event#:
+
${sEvent.getEventNumber()}
+
+
+
PCR Index:
+
${sEvent.getPcrIndex()}
- - -
-
-
Client Log
- - -
-
-
Event#:
-
${lEvent.getEventNumber()}
-
-
-
PCR Index:
-
${lEvent.getPcrIndex()}
-
-
-
Digest:
-
${lEvent.getEventDigestStr()}
-
-
-
Content:
-
${lEvent.getEventContentStr()}
-
+
+
Digest:
+
${sEvent.getEventDigestStr()}
- - +
+
Content:
+
${sEvent.getEventContentStr()}
+
+
+
+
+
+
+
Client Log
+ + +
+
+
Event#:
+
${lEvent.getEventNumber()}
+
+
+
PCR Index:
+
${lEvent.getPcrIndex()}
+
+
+
Digest:
+
${lEvent.getEventDigestStr()}
+
+
+
Content:
+
${lEvent.getEventContentStr()}
+
+
+
+
+
+
+
+ + +
+
Software Identity
+
+
SWID Name: ${initialData.swidName}
+
SWID Version: ${initialData.swidVersion}
+
SWID Tag ID: ${initialData.swidTagId}
+
SWID Tag Version: ${initialData.swidTagVersion}
+ +
SWID Corpus: 
-
+ + +
SWID Patch:  +
+
+ +
SWID Supplemental:  +
+
- - -
-
Software Identity
-
-
SWID Name: ${initialData.swidName}
-
SWID Version: ${initialData.swidVersion}
-
SWID Tag ID: ${initialData.swidTagId}
-
SWID Tag Version: ${initialData.swidTagVersion}
- -
SWID Corpus:  -
-
- -
SWID Patch:  -
-
- -
SWID Supplemental:  -
-
-
+
+
+
Entity
+
+
Entity Name: ${initialData.entityName}
+ +
Entity Reg ID: ${initialData.entityRegId}
+
+
Entity Role: ${initialData.entityRole}
+
Entity Thumbprint: ${initialData.entityThumbprint}
-
-
Entity
-
-
Entity Name: ${initialData.entityName}
- -
Entity Reg ID: ${initialData.entityRegId}
-
-
Entity Role: ${initialData.entityRole}
-
Entity Thumbprint: ${initialData.entityThumbprint}
-
+
+
+
Link
+ -
-
Link
- -
-
-
Meta
- +
+
Meta
+ + +
Payload Type: ${initialData.payloadType}
+
+
Binding Spec: ${initialData.bindingSpec}
+
Binding Spec Version: ${initialData.bindingSpecVersion}
+ +
PC URI Global: ${initialData.pcUriGlobal}
+
+ +
PC URI Local: ${initialData.pcUriLocal}
+
+
Rim Link Hash: ${initialData.rimLinkHash}
-
-
Payload/Support RIM(s)
-
-
- -
-
- -
- -
- -
-
-
- - - - ${resource.getName()} - - - - - - - - - - - ${resource.getName()} - - - -
- - -
- File Size: - ${resource.getSize()}
- Hash: - ${resource.getHashValue()}
- - RIM Format: - ${resource.getRimFormat()}
-
- - RIM Type: - ${resource.getRimType()}
-
- - URI Global: - ${resource.getRimUriGlobal()}
-
- -
- -
-
- -
-
- ${pcrValue.key} - ${pcrValue.value} -
+
+
+
Payload/Support RIM(s)
+
+
+ +
+
+ +
+ +
+ +
+
+
+ + + + ${resource.getName()} + + + + + + + + + + + ${resource.getName()} + + + +
+ + +
+ File Size: + ${resource.getSize()}
+ Hash: + ${resource.getHashValue()}
+ + RIM Format: + ${resource.getRimFormat()}
+
+ + RIM Type: + ${resource.getRimType()}
+
+ + URI Global: + ${resource.getRimUriGlobal()}
+
+ +
+ +
+
+ +
+
+ ${pcrValue.key} + ${pcrValue.value}
- -
+
+
-
-
-
- -
Support RIM file named ${resource.getName()} was not imported via the Reference Integrity Manifest page.
-
-
-
-
-
-
-
-
+
+ +
+ + +
Support RIM file named ${resource.getName()} was not imported via the Reference Integrity Manifest page.
+
+ +
+
+ +
+ +
-
-
-
Signature
-
-
Validity:  +
+
+
Signature
+
+
Validity:  @@ -340,35 +480,41 @@ - -
-
- + +
+ -
- + +
+
+
Subject Key Identifier: ${initialData.skID}
-
-
+
- - -
+
+ +
+