/privacy-by-design-skills:implementing-secure-multi-party-computationfrom privacy-by-design-skills
Implements secure multi-party computation for privacy-preserving analytics across organizations. Covers secret sharing, garbled circuits, frameworks MP-SPDZ and CrypTen, and GDPR alignment.
Ships in privacy-by-design-skills. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
Secure Multi-Party Computation (SMPC) enables multiple parties to jointly compute a function over their combined inputs while keeping each party's individual input private. No party learns anything beyond the output of the computation and what can be inferred from their own input and the output.
SMPC supports GDPR Article 5(1)(c) data minimization by eliminating the need to centralize data, Article 25(1) data protection by design by building privacy into the computation architecture, and Article 26 joint controller arrangements by enabling collaborative analytics without data sharing.
Shamir's Secret Sharing (1979) splits a secret value into n shares such that any t shares can reconstruct the secret (threshold t-out-of-n), but fewer than t shares reveal no information.
Properties:
Application: Splitting personal data across multiple servers such that no single server (or coalition below threshold) can reconstruct the data.
Yao's Garbled Circuits (1986) enable two-party computation. One party (the garbler) encrypts a boolean circuit; the other party (the evaluator) evaluates the encrypted circuit without learning intermediate values.
Properties:
Oblivious Transfer (OT) is a protocol where a sender has multiple messages and a receiver selects one message to receive, without the sender learning which message was selected and without the receiver learning the other messages.
Role in SMPC: OT is the foundational building block for garbled circuit evaluation and is used for input wire labels in Yao's protocol.
| Framework | Protocol | Language | Security Model | Best For |
|---|---|---|---|---|
| MP-SPDZ | Multiple (SPDZ, MASCOT, semi-honest, malicious) | Python-like DSL | Semi-honest and malicious | Research and prototyping with multiple security models |
| CrypTen | Secret sharing (2-party and 3-party) | Python (PyTorch) | Semi-honest | ML inference and training on shared data |
| MOTION | GMW, BMR, arithmetic/boolean sharing | C++ | Semi-honest | High-performance 2+ party computation |
| ABY/ABY3 | Arithmetic, Boolean, Yao sharing | C++ | Semi-honest (2-party ABY, 3-party ABY3) | Mixed-protocol computation (switching between share types) |
| Sharemind | Additive secret sharing (3-party) | SecreC (DSL) | Semi-honest (honest majority) | Enterprise deployment with managed infrastructure |
| Protocol | Security Model | Parties | Preprocessing | Online Performance |
|---|---|---|---|---|
| SPDZ/MASCOT | Malicious (dishonest majority) | 2+ | Heavy (OT-based) | Fast online phase |
| Semi2k | Semi-honest (dishonest majority) | 2+ | Moderate | Fast |
| Shamir | Semi-honest (honest majority) | 3+ | Light | Very fast |
| Rep3 | Semi-honest (honest majority) | 3 | None | Very fast |
| MASCOT | Malicious (dishonest majority) | 2+ | OT-based | Moderate |
| Yao's GC | Semi-honest | 2 | Garbling | Fast evaluation |
┌─────────────────────────────────────────────────────────────┐
│ SMPC Computation Coordinator │
│ (orchestrates protocol execution) │
└──────┬─────────────────┬─────────────────┬──────────────────┘
│ │ │
┌──────▼──────┐ ┌───────▼──────┐ ┌──────▼──────┐
│ Party A │ │ Party B │ │ Party C │
│ (Bank) │ │ (Insurer) │ │ (Retailer) │
│ │ │ │ │ │
│ Input: x_A │ │ Input: x_B │ │ Input: x_C │
│ Share: [x_A]│ │ Share: [x_B] │ │ Share: [x_C]│
│ │ │ │ │ │
│ Compute on │ │ Compute on │ │ Compute on │
│ local share │ │ local share │ │ local share │
└──────┬──────┘ └───────┬──────┘ └──────┬──────┘
│ │ │
└────────────────►│◄────────────────┘
│
┌──────▼──────┐
│ Output: │
│ f(x_A,x_B, │
│ x_C) │
│ (revealed │
│ to all) │
└─────────────┘
Each party learns ONLY the final output f(x_A, x_B, x_C),
NOT the individual inputs of other parties.
Two parties determine which records they have in common without revealing records unique to either party.
Use case: A bank and an insurer identify shared customers for a joint risk assessment without revealing their full customer lists.
| Step | Action | Privacy Guarantee |
|---|---|---|
| 1 | Each party hashes their customer identifiers with a shared key | Individual identifiers not revealed |
| 2 | Parties engage in PSI protocol (DH-based or OT-based) | Only intersection elements revealed |
| 3 | For matched records, proceed with joint computation on shared data | Non-matched records remain private |
Multiple parties compute aggregate statistics (sum, mean, count) over their combined data without revealing individual contributions.
Use case: Three regional offices of Prism Data Systems AG compute total headcount and average salary without revealing per-office figures.
Multiple parties jointly train a machine learning model using SMPC to protect training data during the process.
Use case: Using CrypTen, two hospitals jointly train a logistic regression model on encrypted patient features.
| Factor | Impact | Mitigation |
|---|---|---|
| Network latency | SMPC is communication-intensive; high latency increases total time | Co-locate computation nodes; use constant-round protocols (Yao) for WAN |
| Data size | Communication scales with input size | Pre-aggregate locally where possible; use sketching |
| Circuit complexity | Deeper circuits require more communication rounds (for GMW) | Optimize circuit depth; use Yao for constant rounds |
| Number of parties | More parties = more communication pairs | Use 3-party protocols with honest majority for efficiency |
| Security model | Malicious security is 10-100x slower than semi-honest | Use semi-honest for trusted consortium members; reserve malicious for adversarial settings |
What SKILL.md sets; muted values are Claude Code's defaults
npx claudepluginhub mukul975/privacy-data-protection-skills --plugin privacy-by-design-skills2 plugins in one repository ship this exact skill · first indexed Jul 7, 2026
13 skills in this plugin
/applying-privacy-design-patternsSystematic application of the eight privacy design patterns per Hoepman: minimize, hide, separate, abstract, inform, control, enforce, and demonstrate. Covers pattern selection methodology per processing activity, mapping to GDPR principles, and practical implementation guidance for privacy-by-design system architecture./automating-storage-limitation-controlsAutomated enforcement of GDPR Article 5(1)(e) storage limitation principle. Covers TTL-based deletion, retention policy engines, archival workflows, legal hold exemptions, and lifecycle automation. Includes technical implementation patterns for automated data expiry and defensible deletion across distributed systems./building-purpose-limitation-enforcementTechnical enforcement of GDPR Article 5(1)(b) purpose limitation principle. Covers purpose-tagged data stores, access control per purpose, Article 6(4) compatibility assessment factors, and system design for preventing purpose creep. Includes purpose binding architecture and compatibility test implementation./conducting-linddun-threat-modelingComplete guide to LINDDUN privacy threat modeling methodology covering seven threat categories: Linking, Identifying, Non-repudiation, Detecting, Data Disclosure, Unawareness, and Non-compliance. Includes DFD-based analysis, threat tree catalogs, mitigation mapping to privacy design patterns, and step-by-step process./designing-federated-learning-architectureArchitecture guide for GDPR-compliant federated learning systems. Covers horizontal and vertical FL, aggregation strategies (FedAvg, FedProx), communication efficiency, secure aggregation, and differential privacy integration. Includes privacy guarantees analysis and deployment patterns for cross-organizational ML without data sharing./designing-privacy-preserving-analyticsDesign privacy-preserving analytics systems using differential privacy, k-anonymity, l-diversity, and t-closeness. Covers privacy budget allocation with epsilon tracking, references Google DP library, OpenDP, and Apple PPML. Includes Python differential privacy implementation for GDPR-compliant statistical analysis.Other plugins' skills for the same job