Skip to content

Commit

Permalink
Merge pull request #755 from wurstbrot/patch-1
Browse files Browse the repository at this point in the history
An automated closed finding should be marked as mitigated
  • Loading branch information
aaronweaver committed Oct 2, 2018
2 parents a2f3198 + d385afc commit 511084c
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions dojo/api_v2/serializers.py
Expand Up @@ -590,6 +590,10 @@ def save(self):
test__engagement__product=test.engagement.product,
active=True):
old_finding.active = False
old_finding.mitigated = datetime.datetime.combine(
test.target_start,
timezone.now().time())
old_finding.mitigated_by = self.context['request'].user
old_finding.notes.create(author=self.context['request'].user,
entry="This finding has been automatically closed"
" as it is not present anymore in recent scans.")
Expand Down

0 comments on commit 511084c

Please sign in to comment.