[Forensics-changes] [yara] 138/407: Fix comparisons.

Hilko Bengen bengen at moszumanska.debian.org
Sat Jul 1 10:28:18 UTC 2017


This is an automated email from the git hooks/post-receive script.

bengen pushed a commit to annotated tag v3.3.0
in repository yara.

commit a6f3e43962e00c20a4b4913cce503dcdd1feea42
Author: Wesley Shields <wxs at atarininja.org>
Date:   Sun Oct 19 21:46:48 2014 -0400

    Fix comparisons.
---
 libyara/modules/pe.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/libyara/modules/pe.c b/libyara/modules/pe.c
index f54ab3f..bad28e1 100644
--- a/libyara/modules/pe.c
+++ b/libyara/modules/pe.c
@@ -2388,8 +2388,8 @@ void pe_parse_certificates(
   // included).
   //
   while (struct_fits_in_pe(pe, win_cert, WIN_CERTIFICATE) &&
-         (uint8_t *) win_cert + sizeof(WIN_CERTIFICATE) < eod &&
-         (uint8_t *) win_cert->Certificate + win_cert->Length - 8 < eod)
+         (uint8_t *) win_cert + sizeof(WIN_CERTIFICATE) <= eod &&
+         (uint8_t *) win_cert->Certificate + win_cert->Length - 8 <= eod)
   {
     // Don't support legacy revision for now.
     // Make sure type is PKCS#7 too.

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/forensics/yara.git



More information about the forensics-changes mailing list