mirror of
https://github.com/yogeshojha/rengine.git
synced 2026-09-20 08:47:43 +02:00
Added Target Domain as foreign key
This commit is contained in:
@@ -272,6 +272,7 @@ def doScan(domain_id, scan_history_id, scan_type, engine_type):
|
||||
scanned = ScannedHost()
|
||||
scanned.subdomain = subdomain.rstrip('\n')
|
||||
scanned.scan_history = task
|
||||
scanned.target_domain = domain
|
||||
scanned.save()
|
||||
else:
|
||||
only_subdomain_file = open(
|
||||
|
||||
@@ -33,6 +33,7 @@ class ScannedHost(models.Model):
|
||||
directory_json = JSONField(null=True)
|
||||
checked = models.BooleanField(null=True, blank=True, default=False)
|
||||
discovered_date = models.DateTimeField(blank=True, null=True)
|
||||
target_domain = models.ForeignKey(Domain, on_delete=models.CASCADE, null=True, blank=True)
|
||||
|
||||
def __str__(self):
|
||||
return str(self.subdomain)
|
||||
|
||||
Reference in New Issue
Block a user