gdpr-compliance
GDPR compliance planning including lawful bases, data subject rights, DPIA, and implementation patterns
What this skill does
# GDPR Compliance Planning
Comprehensive guidance for General Data Protection Regulation compliance before development begins.
## When to Use This Skill
- Planning systems that process EU residents' personal data
- Designing consent management and preference centers
- Implementing data subject rights (access, erasure, portability)
- Conducting Data Protection Impact Assessments (DPIA)
- Defining data processing agreements and controller/processor relationships
## GDPR Fundamentals
### The 7 Principles
| Principle | Description | Implementation Focus |
|-----------|-------------|---------------------|
| **Lawfulness, Fairness, Transparency** | Valid legal basis, fair processing, clear privacy notices | Consent flows, privacy policies |
| **Purpose Limitation** | Collect for specified, explicit purposes | Purpose tracking, use restriction |
| **Data Minimization** | Adequate, relevant, limited to purpose | Field-level justification |
| **Accuracy** | Keep data accurate and up to date | Update mechanisms, verification |
| **Storage Limitation** | Keep only as long as necessary | Retention policies, auto-deletion |
| **Integrity and Confidentiality** | Appropriate security measures | Encryption, access control |
| **Accountability** | Demonstrate compliance | Audit logs, documentation |
### Lawful Bases for Processing
```text
1. Consent - Freely given, specific, informed, unambiguous
2. Contract - Necessary for contract performance
3. Legal Obligation - Required by law
4. Vital Interests - Protect someone's life
5. Public Task - Official authority/public interest
6. Legitimate Interest - Balanced against data subject rights
```
**Legitimate Interest Assessment (LIA):**
1. Purpose test: Is there a legitimate interest?
2. Necessity test: Is processing necessary for that interest?
3. Balancing test: Do subject's interests override?
## Data Subject Rights Implementation
### Rights Checklist
| Right | Description | Response Time | Implementation |
|-------|-------------|---------------|----------------|
| Access | Copy of personal data | 1 month | Export endpoint |
| Rectification | Correct inaccurate data | 1 month | Update endpoint |
| Erasure ("Right to be Forgotten") | Delete personal data | 1 month | Deletion pipeline |
| Restrict Processing | Limit use of data | 1 month | Processing flags |
| Data Portability | Machine-readable export | 1 month | JSON/CSV export |
| Object | Stop processing | Without undue delay | Opt-out mechanism |
| Automated Decision-Making | Human review of decisions | Varies | Review queue |
### .NET Implementation Patterns
```csharp
// Data Subject Request Handling
public interface IDataSubjectRequestHandler
{
Task<DataExport> HandleAccessRequest(Guid subjectId, CancellationToken ct);
Task HandleErasureRequest(Guid subjectId, ErasureScope scope, CancellationToken ct);
Task<PortableData> HandlePortabilityRequest(Guid subjectId, string format, CancellationToken ct);
}
public class DataSubjectRequestService : IDataSubjectRequestHandler
{
private readonly IPersonalDataLocator _dataLocator;
private readonly IAuditLogger _auditLogger;
private readonly TimeProvider _timeProvider;
public async Task<DataExport> HandleAccessRequest(Guid subjectId, CancellationToken ct)
{
await _auditLogger.LogRequestReceived(subjectId, "Access", _timeProvider.GetUtcNow());
var locations = await _dataLocator.LocateAllPersonalData(subjectId, ct);
var export = new DataExport
{
SubjectId = subjectId,
GeneratedAt = _timeProvider.GetUtcNow(),
Categories = new List<DataCategory>()
};
foreach (var location in locations)
{
var data = await location.ExtractData(ct);
export.Categories.Add(new DataCategory
{
Name = location.CategoryName,
Purpose = location.ProcessingPurpose,
LawfulBasis = location.LawfulBasis,
RetentionPeriod = location.RetentionPolicy,
Data = data
});
}
await _auditLogger.LogRequestCompleted(subjectId, "Access", _timeProvider.GetUtcNow());
return export;
}
public async Task HandleErasureRequest(Guid subjectId, ErasureScope scope, CancellationToken ct)
{
// Check for legal holds or retention requirements
var blocks = await CheckErasureBlocks(subjectId, ct);
if (blocks.Any())
{
throw new ErasureBlockedException(blocks);
}
var locations = await _dataLocator.LocateAllPersonalData(subjectId, ct);
foreach (var location in locations)
{
if (scope.IncludesCategory(location.CategoryName))
{
// Soft delete with scheduled hard delete
await location.MarkForDeletion(_timeProvider.GetUtcNow().AddDays(30), ct);
}
}
await _auditLogger.LogErasureInitiated(subjectId, scope, _timeProvider.GetUtcNow());
}
}
```
### Consent Management
```csharp
// Consent tracking with granular purposes
public class ConsentRecord
{
public Guid SubjectId { get; init; }
public string Purpose { get; init; } = string.Empty;
public bool IsGranted { get; init; }
public DateTimeOffset Timestamp { get; init; }
public string ConsentMechanism { get; init; } = string.Empty; // e.g., "WebForm", "API"
public string ConsentVersion { get; init; } = string.Empty; // Version of consent text
public string? WithdrawalTimestamp { get; set; }
}
public interface IConsentManager
{
Task RecordConsent(ConsentRecord consent, CancellationToken ct);
Task WithdrawConsent(Guid subjectId, string purpose, CancellationToken ct);
Task<bool> HasValidConsent(Guid subjectId, string purpose, CancellationToken ct);
Task<IReadOnlyList<ConsentRecord>> GetConsentHistory(Guid subjectId, CancellationToken ct);
}
public class GdprConsentManager : IConsentManager
{
private readonly IConsentRepository _repository;
private readonly IEventPublisher _events;
public async Task<bool> HasValidConsent(Guid subjectId, string purpose, CancellationToken ct)
{
var latest = await _repository.GetLatestConsent(subjectId, purpose, ct);
if (latest is null)
return false;
if (latest.WithdrawalTimestamp is not null)
return false;
// Check if consent version is still current
var currentVersion = await _repository.GetCurrentConsentVersion(purpose, ct);
if (latest.ConsentVersion != currentVersion)
{
// Consent was given under old terms - needs re-consent
return false;
}
return latest.IsGranted;
}
}
```
## Data Protection Impact Assessment (DPIA)
### When DPIA is Required
DPIA is mandatory when processing is likely to result in high risk:
- Systematic and extensive profiling with significant effects
- Large-scale processing of special category data
- Systematic monitoring of public areas
- New technologies with unknown privacy impact
- Automated decision-making with legal/similar effects
- Large-scale processing of children's data
### DPIA Template Structure
```markdown
## 1. Description of Processing
- Nature: What will you do with the data?
- Scope: How much data, how many subjects, geographic area?
- Context: Internal/external factors affecting expectations?
- Purpose: What are you trying to achieve?
## 2. Necessity and Proportionality
- Lawful basis and justification
- Purpose limitation assessment
- Data minimization measures
- Data quality approach
- Storage limitation policy
## 3. Risk Assessment
### Risks to Individuals
| Risk | Likelihood | Severity | Score | Mitigation |
|------|------------|----------|-------|------------|
| Unauthorized access | Medium | High | 6 | Encryption, MFA |
| Data breach | Low | Critical | 4 | Monitoring, IR plan |
| Inaccurate profiling | Medium | MedRelated in General
modeling-omnistudio-epc-catalog
IncludedSalesforce Industries CME EPC product-modeling skill for Product2-based catalog creation. Use when creating EPC products, configuring product attributes, building offer bundles with Product Child Items, or reviewing EPC DataPack JSON metadata for product catalog changes. TRIGGER when: user creates or updates Product2 EPC records, AttributeAssignment payloads, AttributeMetadata/AttributeDefaultValues, Offer bundles, or ProductChildItem relationships. DO NOT TRIGGER when: designing OmniScripts/FlexCards/Integration Procedures (use building-omnistudio-omniscript, building-omnistudio-flexcard, or building-omnistudio-integration-procedure), implementing Apex business logic (use generating-apex), or troubleshooting deployment pipelines (use deploying-metadata).
relationship-science-coach
IncludedUse this skill for direct, practical adult relationship coaching: couples conflict, repair, trust, marriage, dating, flirting, attachment patterns, emotional connection, sex, desire differences, eroticism, kink negotiation, affection, love languages, breakups, and long-term passion. Draw on Gottman, EFT and Hold Me Tight, attachment science, modern sex research, Perel, Nagoski, Kerner, Schnarch, Love and Stosny, and flexible love-language tools. Be concrete and low-hedge. Redirect only for imminent danger, abuse, coercive control, minors, non-consent, self-harm, stalking, or medical/legal/psychiatric decisions.
building-sf-integrations
IncludedSalesforce integration architecture and runtime plumbing with 120-point scoring. Use this skill to set up Named Credentials, External Credentials, External Services, REST/SOAP callout patterns, Platform Events, and Change Data Capture. TRIGGER when: user sets up Named Credentials, External Services, REST/SOAP callouts, Platform Events, CDC, or touches .namedCredential-meta.xml files. DO NOT TRIGGER when: Connected App/OAuth config (use configuring-connected-apps), Apex-only logic (use generating-apex), or data import/export (use handling-sf-data).
venue-templates
IncludedAccess comprehensive LaTeX templates, formatting requirements, and submission guidelines for major scientific publication venues (Nature, Science, PLOS, IEEE, ACM), academic conferences (NeurIPS, ICML, CVPR, CHI), research posters, and grant proposals (NSF, NIH, DOE, DARPA). This skill should be used when preparing manuscripts for journal submission, conference papers, research posters, or grant proposals and need venue-specific formatting requirements and templates.
let-fate-decide
IncludedDraws the 12 Houses of the Zodiac Tarot spread to inject entropy into planning when prompts are vague, ambiguous, or casually delegated. Interprets the spread to guide next steps. Use when the user says 'let fate decide', 'YOLO', 'whatever', 'idk', or other nonchalant phrases, makes Yu-Gi-Oh references, or when you are about to arbitrarily pick between multiple reasonable approaches. Prefer over ask-questions-if-underspecified when the user's tone is casual or playful rather than precision-seeking.
net-ops
IncludedCross-platform network troubleshooting (Windows, macOS, Linux) via local or remote shell. Use for: DNS broken, can't resolve hostnames, nslookup/dig works but apps fail, NRPT, WFP, scutil, /etc/resolver, systemd-resolved, /etc/resolv.conf, NetworkManager, VPN DNS leak residue (ProtonVPN/Mullvad/WireGuard/AnyConnect), AV/firewall blocking DNS or DoH, Tailscale DNS interaction, intermittent connectivity, remote diagnostics over SSH.