Skip to content

Commit 368bf00

Browse files
committed
Update pycatfile.py
1 parent d1faef6 commit 368bf00

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

pycatfile.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9559,7 +9559,7 @@ def CatFileValidate(infile, fmttype="auto", filestart=0,
95599559
VerbosePrintOut(outfname)
95609560
VerbosePrintOut("Record Number " + str(il) + "; File ID " + str(fid) + "; iNode Number " + str(finode))
95619561

9562-
if(outfcs == infcs):
9562+
if(hmac.compare_digest(infcs, outfcs)):
95639563
if(verbose):
95649564
VerbosePrintOut("File Header Checksum Passed at offset " + str(outfhstart))
95659565
VerbosePrintOut("'" + outfcs + "' == " + "'" + infcs + "'")
@@ -9571,7 +9571,7 @@ def CatFileValidate(infile, fmttype="auto", filestart=0,
95719571
VerbosePrintOut("'" + outfcs + "' != " + "'" + infcs + "'")
95729572

95739573
if(outfjsonsize > 0):
9574-
if(outfjsonchecksum == injsonfcs):
9574+
if(hmac.compare_digest(injsonfcs, outfjsonchecksum)):
95759575
if(verbose):
95769576
VerbosePrintOut("File JSON Data Checksum Passed at offset " + str(outfjstart))
95779577
VerbosePrintOut("'" + outfjsonchecksum + "' == " + "'" + injsonfcs + "'")

0 commit comments

Comments
 (0)