@@ -115,21 +115,23 @@ def version_0_22_0(self, line, test):
115
115
if json_path .get ("first_commit" ):
116
116
title = f"Secret(s) Found in Repository with Commit ID { json_path ['first_commit' ]['commit_metadata' ]['commit_id' ]} "
117
117
filepath = json_path ["first_commit" ]["blob_path" ]
118
- description = f"Secret found of type: { rule_name } \n " \
119
- f"Rule Text ID: '{ rule_text_id } ' \n " \
120
- f"Committer Name: { json_path ['first_commit' ]['commit_metadata' ]['committer_name' ]} \n " \
121
- f"Committer Email: { json_path ['first_commit' ]['commit_metadata' ]['committer_email' ]} \n " \
122
- f"Commit ID: { json_path ['first_commit' ]['commit_metadata' ]['commit_id' ]} \n " \
123
- f"Location: { filepath } line #{ line_num } \n " \
118
+ description = ( f"Secret found of type: { rule_name } \n "
119
+ f"Rule Text ID: '{ rule_text_id } ' \n "
120
+ f"Committer Name: { json_path ['first_commit' ]['commit_metadata' ]['committer_name' ]} \n "
121
+ f"Committer Email: { json_path ['first_commit' ]['commit_metadata' ]['committer_email' ]} \n "
122
+ f"Commit ID: { json_path ['first_commit' ]['commit_metadata' ]['commit_id' ]} \n "
123
+ f"Location: { filepath } line #{ line_num } \n "
124
124
f"Line #{ line_num } \n "
125
+ )
125
126
# scanned wihout git history
126
127
else :
127
128
title = "Secret(s) Found in Repository"
128
129
filepath = json_path ["path" ]
129
- description = f"Secret found of type: { rule_name } \n " \
130
- f"Rule Text ID: '{ rule_text_id } ' \n " \
131
- f"Location: { filepath } line #{ line_num } \n " \
130
+ description = ( f"Secret found of type: { rule_name } \n "
131
+ f"Rule Text ID: '{ rule_text_id } ' \n "
132
+ f"Location: { filepath } line #{ line_num } \n "
132
133
f"Line #{ line_num } \n "
134
+ )
133
135
# Internal de-duplication
134
136
key = hashlib .md5 ((filepath + "|" + rule_text_id + "|" + str (line_num )).encode ("utf-8" )).hexdigest ()
135
137
0 commit comments