DeepRing: Protecting Deep Neural Network With Blockchain.

Akhil Goel, Akshay Agarwal, Mayank Vatsa, Richa Singh, Nalini K. RathaWorkshops @ CVPR 2019 · DOI

Abstract

DeepRing is a novel architecture that integrates blockchain technology directly into Deep Neural Networks (DNNs) to protect them from adversarial attacks. By treating each network layer as a cryptographic block, the system can detect and automatically recover from unauthorized tampering with model parameters or inputs. This paper presents the design of DeepRing, its cryptographic mechanisms, and an evaluation of its resilience against parameter tampering and adversarial inputs.

Introduction

As deep learning moves into critical infrastructure—including medical diagnosis, autonomous drones, and financial systems—the security of these models becomes paramount. Currently, Deep Neural Networks (DNNs) are largely "black boxes" that are highly vulnerable to two main types of attacks:

  1. Input Manipulation: Crafting "adversarial examples" that look normal to humans but trick the AI.
  2. Parameter Tampering: Maliciously altering the weights or architecture of a deployed model to cause it to fail or behave predictably for an attacker.

Standard models have no internal mechanism to verify their own integrity. If a single weight in a million-parameter model is changed, the model has no way of knowing it has been compromised. DeepRing addresses this by integrating a blockchain-based monitoring layer to ensure model integrity.

Overview of adversarial attack vectors on a standard neural network and the integration of blockchain for mitigation.

The DeepRing Architecture

The authors propose DeepRing, which reimagines a Convolutional Neural Network (CNN) as a decentralized, linked chain of blocks. This architecture introduces several key components:

  • Layer-as-a-Block: Each layer of the CNN is encapsulated into a "block" containing its weights, biases, and activation functions, along with cryptographic metadata (hashes and keys).
  • The Ouroboros Block: This is a special, trusted "start and end" block. It acts as the gateway for queries and monitors the "authenticity" of the entire ring.
  • Transitive Hashing: Each block’s hash is a function of its own parameters and the hash of the previous block. This creates a "brittle" chain; if a single parameter in Layer 2 is changed, the hashes for every subsequent layer will fail to match.
  • Randomized Execution: To thwart "white-box" attacks, DeepRing stores blocks in a random order. An attacker cannot easily trace the gradient flow because they don't know which block represents which functional layer.
  • Dual-Key Encryption: The system uses a mix of Symmetric (AES) and Asymmetric cryptography. Each layer encrypts its output, and only the "authorized" next layer possesses the key to decrypt and process that data.
The DeepRing architecture transforms a standard DNN into a decentralized chain of cryptographic blocks.

Experimental Evaluation and Results

DeepRing was evaluated using three standard computer vision benchmarks: MNIST, CIFAR-10, and Tiny-ImageNet. Tests were conducted on both a standard VGG-19 architecture and a custom 5-layer dense neural network.

Resilience to Tampering

In standard VGG-19 models, a targeted parameter attack using a logistic importance parameter ($p$) dropped accuracy on CIFAR-10 from 83.89% to 63.18%. DeepRing, operating in its "Tracking Mode," detected the tampering and restored the model to its original 83.89% accuracy. The system achieved 100% accuracy in detecting perturbations at the block input level.

Performance Impact

Under normal (non-attack) conditions, the cryptographic overhead did not degrade the classification accuracy of the underlying models; they performed exactly as well as their non-blockchain counterparts. However, the computational complexity and latency are increased due to hashing and encryption operations at every layer.

Conclusion and Future Work

DeepRing introduces the concept of "Self-Healing AI" and accountability via consensus to the internal operations of a neural network. By randomizing the sequence of blocks, the probability of an attacker correctly guessing the model's structure decreases factorially (e.g., $1/10!$ for a 10-layer model). Future work will focus on making these cryptographic protocols more efficient to allow for real-time deployment on edge devices and scaling the "ring" structure to extremely deep architectures like ResNet or Transformers.

Summary updated

BibTeX
@inproceedings{goel2019deepring,
  author = {Akhil Goel and Akshay Agarwal and Mayank Vatsa and Richa Singh and Nalini K. Ratha},
  title = {{DeepRing: Protecting Deep Neural Network With Blockchain.}},
  booktitle = {Workshops @ CVPR},
  year = {2019},
  doi = {10.1109/cvprw.2019.00341},
}
Figure