This work proposes a novel privacy-preserving cyberattack detection framework for blockchain-based Internet-of-Things (IoT) systems. In our approach, artificial intelligence (AI)-driven detection modules are strategically deployed at blockchain nodes to identify real-time attacks, ensuring high accuracy and minimal delay. To achieve this efficiency, the model training is conducted by a cloud service provider (CSP). Accordingly, blockchain nodes send their data to the CSP for training, but to safeguard privacy, the data is encrypted using homomorphic encryption (HE) before transmission. This encryption method allows the CSP to perform computations directly on encrypted data without the need for decryption, preserving data privacy throughout the learning process. To handle the substantial volume of encrypted data, we introduce an innovative packing algorithm in a Single-Instruction-Multiple-Data (SIMD) manner, enabling efficient training on HE-encrypted data. Building on this, we develop a novel deep neural network training algorithm optimized for encrypted data. We further propose a privacy-preserving distributed learning approach based on the FedAvg algorithm, which parallelizes the training across multiple workers, significantly improving computation time. Upon completion, the CSP distributes the trained model to the blockchain nodes, enabling them to perform real-time, privacy-preserved detection. Our simulation results demonstrate that our proposed method can not only mitigate the training time but also achieve detection accuracy that is approximately identical to the approach without encryption, with a gap of around 0.01%. Additionally, our real implementations on various blockchain consensus algorithms and hardware configurations show that our proposed framework can also be effectively adapted to real-world systems.
翻译:本研究提出了一种新颖的隐私保护网络攻击检测框架,适用于基于区块链的物联网系统。在该方法中,由人工智能驱动的检测模块被策略性地部署于区块链节点,以实现对实时攻击的高精度识别与最小延迟检测。为达成此效率目标,模型训练由云服务提供商执行。相应地,区块链节点将数据发送至云服务提供商进行训练;为保护隐私,数据在传输前使用同态加密技术进行加密。该加密方法使得云服务提供商能够直接在加密数据上执行计算而无需解密,从而在整个学习过程中保障数据隐私。为处理海量加密数据,我们引入了一种创新的单指令多数据流打包算法,实现对同态加密数据的高效训练。在此基础上,我们开发了一种专为加密数据优化的新型深度神经网络训练算法。我们进一步提出了一种基于FedAvg算法的隐私保护分布式学习方法,通过在多工作节点间并行化训练,显著提升了计算效率。训练完成后,云服务提供商将训练好的模型分发给区块链节点,使其能够执行实时且隐私保护的攻击检测。仿真结果表明,我们提出的方法不仅能有效减少训练时间,其检测精度与未加密方案近乎一致,差距仅为约0.01%。此外,我们在多种区块链共识算法与硬件配置上的实际部署验证了该框架能够有效适配现实系统。