Enter sha256 binary sum in report files 45/47345/1
authorlhinds <lhinds@redhat.com>
Thu, 16 Nov 2017 14:34:54 +0000 (14:34 +0000)
committerlhinds <lhinds@redhat.com>
Thu, 16 Nov 2017 14:34:54 +0000 (14:34 +0000)
JIRA: RELENG-317

Change-Id: If1a0c1e911e2d9c9684c29379707550133146020
Signed-off-by: lhinds <lhinds@redhat.com>
anteater/src/patch_scan.py
anteater/src/project_scan.py

index 133b0ff..3097d00 100644 (file)
@@ -102,6 +102,9 @@ def scan_patch(project, patch_file, binary_list, file_audit_list,
                     as gate_report:
                 gate_report.write('Non Whitelisted Binary file: {0}\n'.
                                   format(patch_file))
+                gate_report.write('Submit patch with the following hash: {0}\n'.
+                                  format(hasher.hexdigest()))
+
     else:
         # Check file names / extensions
         if file_audit_list.search(patch_file) and not \
index 9bb3539..3a04a83 100644 (file)
@@ -111,6 +111,9 @@ def scan_file(project_dir, project, binary_list, file_audit_list,
                               "a") as gate_report:
                             gate_report.write('Non Whitelisted Binary: {0}\n'.
                                               format(full_path))
+                            gate_report.write(
+                                'Submit patch with the following hash: {0}\n'.
+                                format(hasher.hexdigest()))
 
             else:
                 if not items.endswith(tuple(file_ignore)):