Cybersecurity Data Privacy Impact Assessment Tool

Cybersecurity & Data Privacy Impact Assessment

Evaluate the privacy risks of a new project, system, or process.

Describe the Project

Scope of Data Processing

Identify Privacy & Security Risks

DPIA Report & Mitigation Plan

Disclaimer: This generated report is for internal assessment purposes only and does not constitute legal advice. The findings should be reviewed and validated by a qualified Data Protection Officer or legal counsel.

No specific high-risk items were flagged based on your responses.

`; } outputDiv.innerHTML = tableHTML; } function getCheckedValues(name) { return Array.from(document.querySelectorAll(`input[name="${name}"]:checked`)).map(cb => cb.value).join(', ') || 'None selected'; } function downloadPdf() { const { jsPDF } = window.jspdf; const doc = new jsPDF(); // --- Gather all data from inputs --- const projectName = document.getElementById('projectName').value || 'N/A'; const projectOwner = document.getElementById('projectOwner').value || 'N/A'; const projectDesc = document.getElementById('projectDesc').value || 'N/A'; const dataCats = getCheckedValues('dataCategory'); const lawfulBasis = document.getElementById('lawfulBasis').value || 'N/A'; const thirdParties = document.getElementById('thirdParties').value || 'None'; const summaryTitle = document.querySelector('#report-summary h3').textContent; const summaryText = document.querySelector('#report-summary p').textContent; const addWrappedText = (text, x, y, options) => { const { maxWidth, font, size, style, color } = { maxWidth: 180, font: 'helvetica', size: 10, style: 'normal', color: [0,0,0], ...options }; doc.setFont(font, style); doc.setFontSize(size); doc.setTextColor(...color); const splitText = doc.splitTextToSize(text, maxWidth); doc.text(splitText, x, y); return y + (splitText.length * (size * 0.4)); // Return new Y position }; let yPos = 22; yPos = addWrappedText('Cybersecurity & Data Privacy Impact Assessment', 14, yPos, {size: 18, style: 'bold'}); yPos += 8; doc.autoTable({ startY: yPos, body: [ ['Project Name', projectName], ['Project Owner / Dept', projectOwner], ['Project Description', projectDesc], ['Data Categories Processed', dataCats], ['Lawful Basis', lawfulBasis], ['Third-Party Sharing', thirdParties], ], theme: 'grid', headStyles: { fillColor: [241, 245, 249], textColor: [51, 65, 85], fontStyle: 'bold' }, columnStyles: { 0: { fontStyle: 'bold', cellWidth: 50 } }, }); yPos = doc.autoTable.previous.finalY + 10; let riskColor = [0,0,0]; if (summaryTitle.includes('High')) riskColor = [220, 38, 38]; else if (summaryTitle.includes('Medium')) riskColor = [245, 158, 11]; yPos = addWrappedText(summaryTitle, 14, yPos, { size: 12, style: 'bold', color: riskColor }); yPos = addWrappedText(summaryText, 14, yPos + 2); yPos += 5; const reportTable = document.getElementById('report-table'); if(reportTable) { addWrappedText('Identified Risks & Mitigation Measures', 14, yPos, { size: 12, style: 'bold' }); doc.autoTable({ html: '#report-table', startY: yPos + 5, theme: 'grid', headStyles: { fillColor: [241, 245, 249], textColor: [51, 65, 85] }, styles: { cellPadding: 3, fontSize: 9, cellWidth: 'wrap' }, columnStyles: { 1: { cellWidth: 90 } } }); } const pageCount = doc.internal.getNumberOfPages(); const disclaimer = 'Disclaimer: This generated report is for internal assessment purposes only and does not constitute legal advice. The findings should be reviewed and validated by a qualified Data Protection Officer or legal counsel.'; for(let i = 1; i <= pageCount; i++) { doc.setPage(i); addWrappedText(disclaimer, 14, doc.internal.pageSize.height - 15, {size: 8, color: [150,150,150]}); } doc.save('DPIA_Report.pdf'); } // --- EVENT LISTENERS --- tabs.forEach((tab, index) => tab.addEventListener('click', () => switchTab(index))); nextBtn.addEventListener('click', () => currentTab < tabs.length - 1 && switchTab(currentTab + 1)); prevBtn.addEventListener('click', () => currentTab > 0 && switchTab(currentTab - 1)); document.getElementById('downloadPdfBtn').addEventListener('click', downloadPdf); // --- INITIALIZATION --- createDataCategoryCheckboxes(); createRiskChecklist(); updateTabs(); });
Scroll to Top