This repository contains the source code and experimental data for the research paper: "Enabling Zero-Touch Certificate Management in Modular Plants through Overlay Networks".
This project investigates whether Overlay Networks (ONs) can provide a lightweight, deterministic addressing and routing substrate inside modular plants (specifically "Production Gray Boxes") to enable zero-touch certificate management. The code implements three structured overlay topologies suitable for Operational Technology (OT) environments:
- Chord (Ring-based)
- Kademlia (Tree-based/XOR metric)
- CAN (Content Addressable Network / Space-based)
The implementation focuses on resource efficiency and feasibility within automation systems, utilizing Beremiz (Soft-PLC) for the nodes and Siemens TIA Portal for the orchestration interface.
The code is designed for a specific hardware demonstrator setup described in the associated paper:
- Nodes: 5x Raspberry Pi 4B units running Ubuntu 22.04.5 LTS.
- Orchestrator: 1x Siemens S7-1500 PLC.
- Network: Star topology via a managed Ethernet switch.
- Communication: Modbus TCP is used for communication between nodes and the PLC.
- Runtime: Beremiz (Python-based IEC 61131-3 Soft-PLC).
- Middleware: Node-RED (handling S7 and Modbus-TCP translation).
- Engineering: Siemens TIA Portal V18.
This directory contains the Beremiz projects for the three supported overlay algorithms.
- Variants:
- Naive (e.g., Chord_N1): Uses conservative timing margins (2s timer delays, 500ms cyclic tasks) to ensure stability without acknowledgement messages.
- Optimized (e.g., Chord_N1_opt): Features reduced timing margins (1s timer, 250ms cyclic tasks) and proximity-aware NodeID assignment to demonstrate performance headroom.
- Subdirectories:
- Chord / Chord optimised: Ring topology implementation.
- Kademlia / Kademlia optimised: Tree topology using XOR metrics.
- CAN / CAN optimised: d-dimensional coordinate space implementation.
Contains the flow definitions for routing messages between the PLC and the Soft-PLC nodes.
- CAN_NodeRED.json
- Chord_NodeRED.json
- Kad_NodeRED.json
Contains the orchestration logic for the Siemens S7-1500.
- P2P.zap18: Archived TIA Portal V18 project file.
Contains validation data regarding the join/leave procedures and resource impact.
- RawData: Logs from the experimental runs.
- Scenarios: Excel files and scripts used to calculate recovery times and state durations.
- 5x Raspberry Pis configured with Beremiz and Node-RED.
- 1x Siemens S7-1500 PLC connected to the network.
- Engineering PC with TIA Portal V18.
Perform this step on each of the 5 Raspberry Pi nodes.
- Navigate to the Beremiz directory and launch the IDE:
cd Beremiz/beremiz/
python3 Beremiz.py- Open the specific Project File corresponding to the node number and algorithm (e.g., Chord_N1).
- Build & Connect:
- Click "Build project in build folder".
- Click the Green Plug icon to connect to the local PLC runtime.
- Click the Yellow Arrow to transfer the code.
- Click the Running Man icon to start the execution.
- Access Raspberry Pi 1 (physically located as the uppermost unit on the IRS demonstrator).
- Start Node-RED.
- Import and select the JSON flow corresponding to the network being tested (e.g., Chord_NodeRED.json).
- Verification: Check if all nodes are online. On the physical demonstrator, a green light below the node indicates valid data transfer.
- Open P2P.zap18 in TIA Portal V18.
- Connect to the physical S7-1500 PLC.
- State Check:
- Inspect the Data Blocks (DBs) responsible for "Bootstrap" and "Leave" procedures.
- Ensure the variable State is set to 0. If not, force the value to 0.
- Ensure variables Join and Leave are set to false.
The system is controlled via the HMI connected to the PLC (or the TIA Portal HMI simulation).
- Activate Simulation: Press "Activate simulation" to enable the state display lights on the physical rig.
- Join Procedure:
- Press Join Procedure. This triggers the JoinCtrl signal in the function blocks.
- The nodes will transition through Init -> Joining -> Online states.
- Manual Operation:
- Once joined, click buttons Node 2 to Node 5 to view network details in a pop-up window.
- You may manually trigger "Join" or "Leave" signals for specific nodes to simulate churn.
- Leave Procedure:
- Press Leave Procedure to trigger the graceful exit sequence (LeaveCtrl).
If you use this code or data in your research, please cite the authors.