How user-ozayr/securing_federated_learning_systems works
This repository is a federated-learning security research prototype: Flower simulations compare MTD, poisoning attacks, plaintext aggregation, and MP-SPDZ SPDZ2k secure aggregation. The main workflow is configure an experiment, select clients, train and optionally poison local updates, aggregate them, then record and analyze results. README.md documents the secure-round protocol and research capabilities; sampled source and the SOURCE INDEX support selected internal links. Several experiment and MTD modules were not sampled, so their detailed call relationships are omitted.
Main entry points: flower_simulation.py Flower coordinator · mp_spdz.py SPDZ2k coordinator · config.py Config loading · byzantine.py Poisoning attacks
Components 24
Experiment orchestration
- Config loading
src/fl_security/config.py
Federated learning
- Flower coordinator
src/fl_security/federated/flower_simulation.py - Datasets and partitions
src/fl_security/federated/dataset.py - Model and training
src/fl_security/federated/model.py - FedAvg aggregation
src/fl_security/federated/aggregation.py
Security defences
- Poisoning attacks
src/fl_security/attacks/byzantine.py - Backdoor attack
src/fl_security/attacks/backdoor.py - MTD selection
src/fl_security/mtd/controller.py - MTD randomness
src/fl_security/mtd/randomness.py - Plaintext robust baseline
src/fl_security/federated/robust_aggregation.py
Secure aggregation
- SPDZ2k coordinator
src/fl_security/smpc/mp_spdz.py - Party control service
src/fl_security/smpc/mp_spdz_party_service.py - Fixed-point encoding
src/fl_security/smpc/fixed_point.py - Secure norm defence
src/fl_security/smpc/robust.py - Local party launcher
src/fl_security/smpc/local_demo.py
Evaluation and analysis
- MPC validation
src/fl_security/smpc/validation.py - Gradient inversion study
src/fl_security/experiments/leakage.py - Experiment analysis
src/fl_security/experiments/analysis.py - Statistical evaluation
src/fl_security/evaluation/statistics.py - Run metrics
src/fl_security/evaluation/metrics.py - Experiment results
src/fl_security/logging/experiment_logger.py
Other components
- Research user
- Federated clients
- MP-SPDZ parties
Connections 27
- Research user → Config loading: configures
README.md - Research user → Flower coordinator: runs experiment
README.md - Config loading → Flower coordinator: configures
src/fl_security/federated/flower_simulation.py - Flower coordinator → Datasets and partitions: loads data
src/fl_security/federated/flower_simulation.py - Flower coordinator → Model and training: uses model
src/fl_security/federated/flower_simulation.py - Flower coordinator → MTD selection: selects cohort
README.md - MTD selection → MTD randomness: derives stream
src/fl_security/mtd/controller.py - Flower coordinator → Poisoning attacks: applies poisoning
src/fl_security/federated/flower_simulation.py - Poisoning attacks → Backdoor attack: uses attack
src/fl_security/attacks/byzantine.py - Federated clients → Flower coordinator: trains locally
README.md - Flower coordinator → FedAvg aggregation: aggregates plaintext
README.md - Flower coordinator → Plaintext robust baseline: runs baseline
src/fl_security/federated/flower_simulation.py - Flower coordinator → SPDZ2k coordinator: starts secure round
README.md - SPDZ2k coordinator → Party control service: controls parties
src/fl_security/smpc/mp_spdz.py - SPDZ2k coordinator → Fixed-point encoding: encodes inputs
src/fl_security/smpc/mp_spdz.py - SPDZ2k coordinator → Secure norm defence: uses defence spec
src/fl_security/smpc/mp_spdz.py - Federated clients → MP-SPDZ parties: sends private inputs
README.md - MP-SPDZ parties → SPDZ2k coordinator: returns aggregate
README.md - Research user → Local party launcher: starts local demo
README.md - Local party launcher → Party control service: starts services
src/fl_security/smpc/local_demo.py - Research user → MPC validation: validates MPC
README.md - Research user → Gradient inversion study: runs leakage study
README.md - Gradient inversion study → Flower coordinator: compares updates
src/fl_security/experiments/leakage.py - Research user → Experiment analysis: analyzes runs
README.md - Flower coordinator → Run metrics: records metrics
src/fl_security/federated/flower_simulation.py - Flower coordinator → Experiment results: writes results
src/fl_security/federated/flower_simulation.py - Experiment analysis → Statistical evaluation: computes statistics
src/fl_security/experiments/analysis.py