michaelmc1618 commited on
Commit
0713ea2
·
verified ·
1 Parent(s): 182de3d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +21 -11
app.py CHANGED
@@ -65,11 +65,11 @@ def analyze_gdpr_compliance(audit_data):
65
  def generate_gdpr_report(audit_data, company_name="Company Name", system_name="System Name"):
66
  findings, recommendations = analyze_gdpr_compliance(audit_data)
67
 
68
- report_content = f"""
69
  GDPR Compliance Evaluation Report
70
 
71
  Title: GDPR Compliance Evaluation Report
72
- Date: {datetime.now().strftime('%Y-%m-%d')}
73
  Prepared by: [Your Name]
74
  For: {company_name}
75
 
@@ -81,33 +81,43 @@ def generate_gdpr_report(audit_data, company_name="Company Name", system_name="S
81
  Key Findings:
82
 
83
  System Information Analysis:
84
- {findings['system_info']}
85
 
86
  Disk Usage Analysis:
87
- {findings['disk_usage']}
88
 
89
  Network Info Analysis:
90
- {findings['network_info']}
91
 
92
  Security Measures Analysis:
93
- {findings['security_measures']}
94
 
95
  Running Processes Analysis:
96
- {findings['running_processes']}
97
 
98
  Software Inventory Analysis:
99
- {findings['software_inventory']}
100
 
101
  Recommendations:
102
- {''.join(f'- {rec}\n' for rec in recommendations)}
103
 
104
  Conclusion:
105
  The analysis shows that while {company_name} has some strong protective measures in place, there are several areas for improvement. Implementing the suggested recommendations will enhance {company_name}'s compliance with GDPR and reduce potential risks of non-compliance.
106
 
107
  References:
108
  - GDPR Regulation (EU) 2016/679
109
- - System Audit Report, {datetime.now().strftime('%Y-%m-%d')}
110
- """
 
 
 
 
 
 
 
 
 
 
111
 
112
  return report_content
113
 
 
65
  def generate_gdpr_report(audit_data, company_name="Company Name", system_name="System Name"):
66
  findings, recommendations = analyze_gdpr_compliance(audit_data)
67
 
68
+ report_content = """
69
  GDPR Compliance Evaluation Report
70
 
71
  Title: GDPR Compliance Evaluation Report
72
+ Date: {date}
73
  Prepared by: [Your Name]
74
  For: {company_name}
75
 
 
81
  Key Findings:
82
 
83
  System Information Analysis:
84
+ {system_info}
85
 
86
  Disk Usage Analysis:
87
+ {disk_usage}
88
 
89
  Network Info Analysis:
90
+ {network_info}
91
 
92
  Security Measures Analysis:
93
+ {security_measures}
94
 
95
  Running Processes Analysis:
96
+ {running_processes}
97
 
98
  Software Inventory Analysis:
99
+ {software_inventory}
100
 
101
  Recommendations:
102
+ {recommendations}
103
 
104
  Conclusion:
105
  The analysis shows that while {company_name} has some strong protective measures in place, there are several areas for improvement. Implementing the suggested recommendations will enhance {company_name}'s compliance with GDPR and reduce potential risks of non-compliance.
106
 
107
  References:
108
  - GDPR Regulation (EU) 2016/679
109
+ - System Audit Report, {date}
110
+ """.format(
111
+ date=datetime.now().strftime('%Y-%m-%d'),
112
+ company_name=company_name,
113
+ system_info=findings['system_info'],
114
+ disk_usage=findings['disk_usage'],
115
+ network_info=findings['network_info'],
116
+ security_measures=findings['security_measures'],
117
+ running_processes=findings['running_processes'],
118
+ software_inventory=findings['software_inventory'],
119
+ recommendations=''.join(f'- {rec}\n' for rec in recommendations)
120
+ )
121
 
122
  return report_content
123