Skip to content

Commit

Permalink
Use MessageDigest.isEquals method when comparing signatures in NTLMEn…
Browse files Browse the repository at this point in the history
…gineImpl

Signed-off-by: Andrea Cosentino <[email protected]>
  • Loading branch information
oscerd committed Jan 25, 2024
1 parent 4f8f34f commit 3788d97
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -926,7 +926,7 @@ private boolean validateSignature( final byte[] signature, final byte[] message
// log.info( "SSSSS validateSignature("+seqNumber+")\n"
// + " received: " + DebugUtil.dump( signature ) + "\n"
// + " computed: " + DebugUtil.dump( computedSignature ) );
return Arrays.equals( signature, computedSignature );
return MessageDigest.isEqual( signature, computedSignature );
}

public byte[] signAndEncryptMessage( final byte[] cleartextMessage ) throws NTLMEngineException
Expand Down

0 comments on commit 3788d97

Please sign in to comment.