# Pia Dpia Workflow

> Use when a new feature, vendor, or data flow needs a privacy impact assessment or a data protection impact assessment. Covers screening for high risk processing, describing flows and legal bases, assessing necessity and proportionality, consulting stakeholders, and tracking mitigations to closure. Use when launching profiling, large scale monitoring, or new special category data processing.

- Skill: `mizazhaider-ceh/pia-dpia-workflow` (Agent Skill)
- Install (CLI): `npx get-skill add mizazhaider-ceh/pia-dpia-workflow`
- Raw SKILL.md: https://api.skillmd.com/api/skills/mizazhaider-ceh/pia-dpia-workflow/raw
- Safety review: pending
- Works with: Claude Code, Claude.ai, OpenAI Codex
- Category: Productivity
- Author: mizazhaider-ceh (https://skillmd.com/u/mizazhaider-ceh)
- Updated: 2026-11-22
- Page: https://skillmd.com/skills/mizazhaider-ceh/pia-dpia-workflow

---


A privacy impact assessment (PIA) is the structured write-up of what a
change does with personal data, what could go wrong, and what stops it
going wrong. A data protection impact assessment (DPIA) is the formal
version required by GDPR Article 35 for high risk processing. The
workflow is the same either way - screen, describe, assess, mitigate,
sign off, and revisit. The most common failure is writing the
assessment after launch to justify a decision already made. Run it
while the design can still change.

## Quick Workflow

1. Screen the change for high risk triggers - systematic profiling,
   large scale special category data, systematic public monitoring,
   new technology, or matching across datasets.
2. Describe the processing precisely - data flows, categories of data
   and people, purposes, legal bases, recipients, retention, and
   cross-border transfers.
3. Assess necessity and proportionality - is each element of the
   processing needed for the purpose, and is there a less intrusive
   way to reach the same result.
4. Identify risks to people (not just to the company) and score each
   by likelihood and severity before mitigation.
5. Assign mitigations with owners and due dates, and re-score the
   residual risk after each one.
6. Consult the data protection officer, and where the impact is high,
   the people affected or their representatives.
7. Get a written sign-off before launch, and set the review trigger -
   a scope change, a new recipient, or at most one year out.
8. If residual risk stays high after mitigation, seek prior
   consultation with the supervisory authority before processing.

## 1. Screening - decide whether a DPIA is required

Screening is a short checklist, answered honestly, kept on file even
when the answer is no DPIA needed. A "no" without a record is
indistinguishable from never having screened.

```python
#!/usr/bin/env python3
"""DPIA screening - any YES on a high risk trigger means a DPIA is required."""
TRIGGERS = [
    ("systematic and extensive profiling with significant effects", False),
    ("large scale processing of special category data", True),
    ("systematic monitoring of a publicly accessible area", False),
    ("new technology with untested privacy impact", False),
    ("matching or combining datasets from multiple sources", True),
    ("processing data about vulnerable people at scale", False),
    ("innovative use of biometric or location data", False),
]
required = any(hit for _, hit in TRIGGERS)
for label, hit in TRIGGERS:
    print(f"{'YES' if hit else 'no '} - {label}")
print()
print("DPIA required:", "YES" if required else "NO - record this screening and the reasons")
```

## 2. Data flow description - the assessment's foundation

An assessment built on a vague flow diagram is fiction. Map every hop
the data takes, including vendors, subprocessors, logs, and backups,
and confirm each hop with the team that owns it.

```markdown
# Data flow record - template

| Hop | From | To | Data categories | Purpose | Legal basis | Retention |
| --- | --- | --- | --- | --- | --- | --- |
| 1 | User device | App backend | Email, device id | Account creation | Contract | Life of account |
| 2 | App backend | Analytics vendor | Pseudonymous id, events | Product improvement | Legitimate interests | 13 months |
| 3 | App backend | Log store | IP address, request path | Security monitoring | Legitimate interests | 30 days |
| 4 | App backend | Backup store | Full database copy | Disaster recovery | Contract | 90 days |

Rules - every recipient gets a row, including internal teams.
A hop with no legal basis or no retention is an open finding, not a draft.
```

## 3. Risk register - score before and after mitigation

Score risk to the people affected, not reputational risk to the
company. A breach that exposes health data is severe even if the press
never notices, and a minor leak affecting millions is high risk even
if each record looks harmless.

```python
#!/usr/bin/env python3
"""Risk register - likelihood and severity scored 1 to 5, risk is the product."""
RISKS = [
    # (risk, likelihood, severity, mitigation)
    ("Analytics vendor re-identifies pseudonymous users", 3, 4,
     "Contract ban on re-identification plus quarterly vendor audit"),
    ("Support tool exposes health notes to all agents", 2, 5,
     "Role based access plus field level redaction in the support UI"),
    ("Location history retained beyond stated 24 hours", 4, 3,
     "Automated deletion job with a weekly retention check"),
]
for risk, likelihood, severity, mitigation in RISKS:
    before = likelihood * severity
    verdict = "ACCEPTABLE" if before <= 6 else "MITIGATE BEFORE LAUNCH"
    print(f"Risk: {risk}")
    print(f"  score before mitigation: {likelihood} x {severity} = {before} -> {verdict}")
    print(f"  mitigation: {mitigation}")
    print("  Re-score after the mitigation lands and record the residual score.")
```

## 4. Sign-off and review triggers

```markdown
# DPIA sign-off - template

- Assessment owner: (name, team)
- Data protection officer consulted: (date, advice given, advice followed or reasons not)
- People affected consulted: (method and date, or why consultation was not appropriate)
- Residual risks above the acceptable threshold: (list, or "none")
- Prior consultation with the supervisory authority needed: (yes or no, with reasons)
- Approved for launch by: (name, date)
- Review triggers: scope change, new recipient, new data category,
  incident involving this processing, or 12 months, whichever comes first.
```

## Edge cases

- A vendor change can trigger a fresh assessment even when your own
  code did not change, because the recipient, jurisdiction, or
  subprocessor list changed with it.
- Legitimate interests needs a balancing test on file, not just the
  label. If the test is missing, the legal basis is unproven.
- Assessments for AI features must cover training data provenance,
  inference outputs that reveal personal data, and human review of
  automated decisions, not just the input form.
- Small pilots are not exempt. A pilot processing real personal data
  at small scale still needs screening, and its results often decide
  a full rollout, so assess before the pilot, not after.
- If stakeholders or the data protection officer disagree with the
  sign-off, record the disagreement and the resolution. A unanimous
  document nobody believed is worse than a contested one that was
  actually debated.

## Key references

- GDPR Article 35 - data protection impact assessment
- GDPR Article 36 - prior consultation with the supervisory authority
- GDPR Article 37 to 39 - data protection officer duties and consultation
- WP248 guidelines on data protection impact assessment (Article 29 Working Party)
- Parent skill privacy-impact-assessment - assessment foundations

