Skip to content

Commit

Permalink
fix:fpgabitstreaminfo update string “Bitstream version” to "Image Inf…
Browse files Browse the repository at this point in the history
…o" (#3076)

* fix:fpgabitstreaminfo update string “Bitstream version” to "Image Info"

Signed-off-by: anandaravuri <ananda.ravuri@intel.com>
---------

Signed-off-by: anandaravuri <ananda.ravuri@intel.com>
  • Loading branch information
anandaravuri authored Jan 17, 2024
1 parent 05d88ab commit 9ba83ec
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions python/opae.admin/opae/admin/utils/verifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -202,7 +202,7 @@ def __init__(self, bits, payload):
self.content_type = bits[8]
self.cert_type = bits[9]
self.slot_num = bits[10] & 0xF
self.bitstream_version = bytearray(bits[96:128]).decode()
self.image_info = bytearray(bits[96:128]).decode()
self.sha256 = int_from_bytes(bits[16:48], byteorder="big")
self.sha384 = int_from_bytes(bits[48:96], byteorder="big")
self.calc_sha256 = int_from_bytes(
Expand Down Expand Up @@ -250,10 +250,10 @@ def print_block(self):
"\n\t\t\t{0:#0{1}x}").format(self.calc_sha384, 98))
print("\t\tMatch" if self.sha384 ==
self.calc_sha384 else "\t\tNo match")
if len(self.bitstream_version) != 0:
print("\tBitstream Version =\t\t{}".format(self.bitstream_version))
if len(self.image_info) != 0:
print("\tImage Info =\t\t{}".format(self.image_info))
else:
print("\tNo Bitstream Version")
print("\tNo Image Info")
if self.cert_type == database.BITSTREAM_TYPE_CANCEL:
print("\n\tCSK to cancel =\t{}".format(
int_from_bytes(self.payload[:4], byteorder="big")))
Expand Down

0 comments on commit 9ba83ec

Please sign in to comment.