Skip to main content

RETRACTED ARTICLE: Blockchain managed federated learning for a secure IoT framework

This article was retracted on 13 May 2024

This article has been updated


In this work, we present a blockchain-based federated learning (FL) framework that aims achieving high system efficiency while simultaneously addressing issues relating to data sparsity and the disclosure of private information. It is more efficient to build a number of smaller clusters rather than one big cluster for multiple networks. Blockchain-based FL is carried out in each cluster, with the model changes being compiled at the end of the process. Following that, the accumulated updates are swapped across the clusters, which, in practise, improves the updates that are accessible for each cluster. When compared to the extensive interactions that take place in blockchain-based FL, cluster-based FL only sends a limited number of aggregated updates across a substantial distance. This is in contrast to the extensive interactions that take place in blockchain-based FL. In order to conduct an analysis of our system, we have implemented the prototypes of both cluster and blockchain-based FL models. The findings of the experiments show that cluster-based FL model raise the accuracy goes upto 72.6%, and goes down to 11%. The loss goes upto 3.6 and goes down to 0.8. In addition, cluster-based FL model has the potential to hasten the convergence of the model, provided that the same quantity of data is input into it. The reason for this is due to the fact that during a training cycle, cluster-based FL model combines the computational resources of many different clusters.

1 Introduction

Internet of Things (IoT) is the name given to the new network that is being created as a result of a growing number of medical devices communicating to one another in the current day [1]. It is anticipated that cloud-based Internet of Things would contribute to an advantageous machine learning model by consolidating the data acquired in a variety of devices [2, 3].

It is feasible to utilize federated learning (FL) as a solution to this issue [4], which makes it possible to train on the device itself without transferring the data anyplace else. This makes it viable to use FL as a solution to the problem. However, the conventional FL system is insecure because to its reliance on a lone server for managing model updates and training operations coordination. This makes the traditional FL framework susceptible to security breaches. Because of this, there is a chance that the centralized server won't perform well, and thus leaves the framework vulnerable. The blockchain technology that is capable of working in conjunction with it, is on the horizon [5]. The usage of a blockchain makes it feasible to provide decentralized control over the aggregation of model update information as well as safe operation orchestration [6].

In this study, we combine blockchain technology with fuzzy logic to develop a new kind of logic known as blockchain-based fuzzy logic. Because of the emphasis placed on system design and algorithm optimisation [7], a major problem associated with data sparsity in a blockchain-based FL cluster [8] is not taken into consideration. As an example, when an IoT network goes into service for the very first time, it is only capable of holding very few data samples due to its early level of development. A further consideration is that if there are just a few IoT devices in a network, it will use the blockchain-based cluster to gather sufficient data in an excessive amount of time.

The quality of the data samples may be improved in an easy manner by expanding the size of a blockchain-based FL cluster in such a way that it incorporates the maximum number of devices that are technically possible. It's possible that these devices are spread out over a number of different networks, some of which are quite far from one another. As a direct consequence of this, the network delay that exists between devices has the potential to be very substantial. On the other hand, the blockchain technology that is now being used in the cluster necessitates consistent communications all over the network in order to accomplish the goal of reaching a consensus. It is possible that both the efficiency of establishing a consensus and the efficiency of the system that corresponds to it are quite subpar when seen in their whole. This is due to the fact that communications with a high latency and frequency are the reason. In addition to this, a blockchain-based FL cluster has the requirement that any modifications made to the models must be broadcast across the FL cluster. According to the results that Wang et al. came to, it is possible to partially reassemble the private data by making use of the model's most recent changes [9]. Since a result of this, the possibility of data privacy leakage grows proportionally with the size of the cluster's scope. This is especially true when the cluster is formed across more than one network, since this multiplies the number of networks that are involved.

In addition, the aggregated updates hide the precise changes that are applied to each node, which helps to secure the privacy of the data more effectively [10].

Inter-cluster and intra-cluster protocols have been proposed to exchange cross-cluster models in a safe manner. The single-chain consensus and the cross-chain consensus are two types of sub-protocols that are used in both intra-cluster and inter-cluster, respectively. While intra-cluster is simple and straightforward, making it easy to grasp, it is inefficient as a system and may be regarded the foundation of inter-cluster. The intra-cluster mechanism is suggested as a means of making the system more efficient. In particular, intra-cluster will regularly pick a cluster representative to carry out model aggregation, which will ultimately result in a reduction in the number of occasions when sluggish cross-chain agreement is reached.

In a nutshell, the following are the most significant contributions we've made:

We highlight the challenge that is presented by the currently available blockchain-based FL model solutions, which are referred to as the issue of data sparsity and the problem of poor efficiency combined with privacy leakage. We suggest the use of cluster-based FL model as a solution to this problem. Cluster-based FL model prototypes, i.e., inter-cluster and intra-cluster are built, and comprehensive tests are carried out to establish the technology's practicability and effectiveness.

1.1 Motivation

Within the framework of IoT-based cloud network the blockchain-based FL is often taken into account within a constrained amount of space. The use of blockchain in a cloud network, needs all of the equipment are located in close proximity to one another and are linked by a LAN (Local Area Network) that is capable of fast speeds is an example that is often used.

However, the blockchain-based system could have certain problems since it was intended for a restricted amount of area. To begin, there is a possibility that there are not enough dataset samples to obtain a reasonable model in such a constrained area. This is particularly the case when the IoT devices have only been in operation for a short period of time. In this respect, the newly developed technologies are required to go through a protracted time in which they are unable to reap the advantages of the machine learning technology. To find a solution to the problem, a region that lacked adequate data would look to other regions for more data to augment their own. Second, when it comes to a job involving machine learning, having more data often results in a more accurate model. Because there may be numerous locations containing the data, each of which may have a feature space or sample space that is comparable to the others, these areas have the potential to collaborate in order to produce a model that is superior than any that is specific to a single area.

The problems described above encourage academics to use data from a variety of sources. A straightforward answer is to create a large blockchain-based FL cluster that acts as a collection point for several devices that are scattered over numerous locations or cluster. There are two distinct kinds of device communication that might take place inside a cluster: intra-cluster and inter-cluster.

The first method is carried out by means of a LAN (Local Area Network) that operates at a fast speed inside a cluster, while the second method is backed by a WAN (Wide Area Network) that operates at a slow pace across clusters.

For the blockchain technology to be used in the cloud network system, the devices that make up the network must be spread out throughout the clusters. It is possible that the FL process will go more slowly as a consequence of the lengthy delay that may be caused by communication between different nodes. Consequently, it seems to be impracticable to construct a broad blockchain-based FL cluster spanning a number of different nodes.

To our good fortune, maybe there is another way for us to investigate this matter. Because the blockchain-based FL framework is more applicable to a limited space, for the purpose of providing high efficiency, one possible course of action would be to implement blockchain-based FL in each network on its own and then trade blockchain-based FL models across the various networks. When seen from this angle, the long-latency communications that occur between networks might experience a significant amount of margin reduction.

2 Related work

Several research have been conducted to investigate the feasibility of a successful collaboration between FL and blockchain technology. The issue of sparse data is addressed in almost none of these publications, despite the fact that many papers focus on the integration of systems or the optimisation of algorithms. On the other hand, the immediate deployment of existing cross-chain technology to unite a large number of FL clusters is now thwarted due to inefficiencies or problems with centralization. Because of the decentralized nature of blockchain technology and the traceability it offers, there has been a lot of consideration given to incorporating it into FL.

BFL is used in a broad range of applications, such as the Internet of Things (IoT), the Internet of Vehicles (IoV), and Mobile Edge Computing [11], with the ultimate goal of enhancing resiliency [12], while also protecting privacy [10].

To be more specific, Bao et al. [12], Kim et al. [13], and Pokhrel et al. [14] all suggest designs that, if implemented, would make it feasible to carry out FL in a manner that is truly distributed. Kim et al. have made the recommendation that devices that collect a greater quantity of data should also contribute the compensatory mechanism to the global model. This provides an additional incentive for data-rich devices to upload even more of their data. However, none of these methods solves the fundamental issue, which is that any device that is part of a cluster is only able to access a tiny portion of the total data that is accessible.

In order to ensure that users' personal information is protected during data exchanges in the IoT network, Lu et al. [15] combined the FL tasks with the consensus computing activities. However, they only consider optimizing the method and do not take into account the possibility that a FL cluster may have an issue with data being sparse. In summary, each and every previous piece of research has tested the idea that the data contained inside a cluster is all that is necessary to construct an accurate model.

In addition, there have been ongoing attempts made to group together all of the blockchain's nodes, after which they will be arranged as a single chain. It is possible that the nodes will be dispersed over a vast region, which will cause an increase in the amount of work for the communications infrastructure of the network.

A number of cross-chain solutions [16] have been offered in order to facilitate the information exchange that occurs across various implementations of blockchain technology. This collection of technologies may be classified in a number of different ways [17], the most frequent of which are the notary, sidechain/relay, and hash-locking categories.

In recent years, academics have made a number of strides forward in fields relevant to the development of cutting-edge technologies, such as blockchain, smart networks, the Internet of Things, and software-defined networks.

The concept of a smart distribution network was introduced and studied in Kazmi et al.'s study [18], which was conducted within the context of the smart-grid paradigm. They put an increased emphasis on the procedures that were connected with implementation and were included into the planning model for the intelligent distribution network. Separately, Huang et al. [19] suggested an architecture for intelligent networks that would combine intelligent operations that were made possible by artificial intelligence, were driven by vast volumes of wireless data, and were made easier by network function virtualization. This architecture for intelligent networks would be used in intelligent networks. The Quality-of-Service (QoS) objective was also accomplished since the authors made it possible for mobile users to connect to the network that offered the highest possible level of service at a cost that was within their financial means.

Takenaka et al. [20], on the other hand, presented an illustration of a smart network and researched the use of IoT data in industrial environments. In order to achieve goals such as mass customisation or the development of new services, the need of having a suitable data format and analytical techniques was emphasized in this article. In recent research [21], Chakrabarty and colleagues developed a blueprint for the creation of safe and efficient smart cities. Notaries are required to cooperate with one another to guarantee that each stage in the notarization process is carried out accurately [22, 23]. On the other side, growing centralization brings forth a whole new challenge.

In this paper, we present the need of an integrated framework for safeguarding the privacy of users while simultaneously optimising the partitioning of applications, the allocation of resources, and the placement of service caches. The aforementioned issues, however, involve variable delays that are sensitive, and as a result, the issue of overall optimisation is highly tough.

Deep learning [9] and blockchain technology [10] have attracted a lot of attention from edge computing specialists in recent years. When it comes to making judgements in real time for things like autonomous resource allocation and robotics, wireless communication networks (4G and VANET) significantly depend on deep learning. Inside the widely dispersed edge nodes, blockchain offers reliable connectivity and administration of computing, communication, and storage resources [10]. This provides a strong impetus for the urgent investigation of a unique scheduling strategy that is supported by deep learning and blockchain technology. In addition, FL [14, 15], and [11] (federated learning) is regarded as a valuable resource for the purpose of training deep learning agents in a manner that is decentralized. This is due to the fact that FL is capable of preventing unauthorised access to sensitive information at all stages of the training process.

In example, the status of the various chains would be inconsistent in the event if the notaries did not operate as expected or behaved maliciously. The sidechain and relay method makes it possible for one chain to watch the operations taking place on another chain and do the actions that are appropriate in response. Before any of the other chains will acknowledge it as valid, every action in a chain has to get approval from the consensus. Because reaching agreement often involves a significant amount of delay, this drastically lowers the efficiency of the activities that take place across chains. The hash-locking system allows for cross-chain atomic actions to be performed without depending on any third-party organizations or individuals.

3 Proposed method

When linked with machine learning (ML) technology in cloud IoT networks, Blockchain technology plays an increasingly essential role related to the security in the network. The traditional machine learning technique, on the other hand, calls for the acquisition of data from a wide variety of devices. This might result in a major breach of privacy in the IoT situation, in which the data in question is very privacy-sensitive.

In order for the researchers to protect the consumers' privacy without compromising their experience, they need to take into consideration the federated learning (FL) technology. The objective of FL is to carry out machine learning in a distributed manner, without first bringing all of the data together as a centralized repository [4]. FL starts the process by asking that each node carry out a local training job throughout each round of the process. After this, FL combines the model alterations in order to get it ready for the subsequent round of training. This is achieved by the use of a procedure that moves forward one round at a time. There is a centralized server in the architecture of FL that is used to coordinate the training activities and aggregate the model updates. This is the design that is utilized by default. Additionally, the model is stored on this server. On the other side, this leads in various difficulties that are linked with centralization, such as single-point failure and hostile behavior. Centralization is related with these issues because it increases the likelihood of their occurring.

The distributed ledger technology (blockchain) is being implemented into FL [10] as a solution to the problems caused by centralized servers. Blockchain technology, which originated with Bitcoin [24], is anticipated to facilitate peer-to-peer collaboration in a manner that is independent of centralized authority [5]. Through the use of the consensus method, the coordination of training activities and the accumulation of model updates may be carried out in a decentralized manner using the blockchain system [25]. Since the blockchain may be conceived of as a tamper-proof record, it is less likely that a peer would act irrationally because of its presence. In addition, since the model modifications that are recorded on the blockchain are both auditable and traceable, this will discourage them from engaging in such activity. The following is one way that the blockchain technology-based FL may be modeled. Let's say that blockchain technology-based FL is being used in cloud IoT network, and that each of the devices in the network is part of a cluster. In the following, the word 'node' will be used interchangeably with 'device' while referring to IoT cloud network, and the term 'cluster' will be used when referring to devices. Let's say that the training dataset is split up across \(N\) nodes that \((i=\mathrm{1,2}\dots .N)\) in a blockchain technology-based FL cluster, and that each node \({n}_{i}\) has \({s}_{i}\) samples of its own.

When training a distributed model, the gradients from all of the working nodes first need to be aggregated into a single value before they can be utilized to make adjustments to the model weights. On the other hand, it's possible that the gradients coming from the various worker nodes won't be in sync with one another because of network latency and other variables. Because of this, the weights of the model can end up being changed in a way that is incompatible with the gradient as a whole. Due to stochastic gradient descent (SGD) and the utilization of mini-batches, the gradients that are computed by each worker node have a possibility of being noisy. When these gradients with their inherent noise are added together, the final gradient can have an even higher level of inherent noise. Because of this, the weights of the model could end up being updated in a way that is inconsistent with the actual gradient of the data. There is a possibility that the magnitudes of the gradients computed by each worker node will vary. This is because of a number of factors, including the fact that various worker nodes will have varying data distributions. Because of this, the model weights might end up being changed in a way that gives preference to the gradients coming from the worker nodes that provide the biggest magnitudes.

The goal of the training for node \({n}_{i}\) is to minimise \({f}_{i}(w)\), which is defined as follows:

$${f}_{i}\left(w\right) =\frac{1}{{n}_{i}}\sum_{m=1}^{{n}_{i}}\mathcal{L}\left({x}_{i}\left(m\right),{y}_{i}\left(m\right),w\right)$$

where \(\left({x}_{i}\left(m\right),{y}_{i}\left(m\right)\right)\) is the sample indexed by \(m\) in node \({n}_{i}\) k and \(\mathcal{L}\left({x}_{i}\left(m\right),{y}_{i}\left(m\right),w\right)\) is the loss function that has to be used in order to create a prediction based on this sample. In circumstances in which the learning model is known as a deep learning model, and the method used is gradient descent is especially used in order to reduce the total amount of model loss. The steps involved in the computation are as stated below:

$${w}_{t+1}\leftarrow {w}_{t}-\eta \nabla {f}_{i}\left({w}_{t}\right)$$

in where \(t\) and \(\eta\) are the number of steps in gradient descent and the learning rate of that descent respectively. The gradients \(\nabla {f}_{i}\left({w}_{t}\right)\) are computed for the function \({f}_{i}\left({w}_{t}\right)\).

On the basis of the model updates obtained from single-node learning, blockchain technology based FL makes an effort to aggregate all of the model updates received from the many nodes that make up the cluster. The following is its intended training goal function \({G}_{train}\left(w\right)= \sum_{i=1}^{N}\frac{{n}_{i}}{M}\,{f}_{i}\left(w\right) ,\) where \(M\) refers to the total number of samples in the training dataset.

A gradient aggregation strategy is offered as a means of determining the value of \(w\) that will result in the lowest possible value for the training objective function \({G}_{train}(w)\). This value will be determined by calculating which value of w will result in the lowest possible value. To be more specific, when employing this method, each node supplies its very own local gradient, and the other nodes subsequently aggregate the gradients in order to construct a new model:

$${w}_{t+1}\leftarrow {w}_{t}-\eta \sum_{i=1}^{N}\frac{{n}_{i}}{M}{f}_{i}\left({w}_{t}\right)$$

3.1 Cluster-based FL design

We present a cluster-based FL framework, which links different blockchain-based FL clusters in order to construct a learning model. This is done in order to solve the challenges posed by blockchain-based FL data sparsity as well as its high latency connection. The comprehensive system overview of cluster-based FL uses the example of two networks as a basis for discussion. To be more explicit, one instance of blockchain-based FL is run at each cluster, and the cluster that each network devices comprise is made up of all the devices in that cluster. At the conclusion of each training cycle in FL, the most recent model changes are distributed across all of the clusters. After that, we go on to developing further the structure of the cluster-based FL framework. Consensus may be reached either quickly or put off till later. In the cluster-based FL model that is proposed, we combine the model updates (such as gradients in a deep learning model) from many blockchain-based FL clusters into a single set. This allows us to make use of more data features and produce a more accurate model. It is anticipated that the cluster-based FL model would acquire equivalent model performance in comparison to that of the blockchain-based FL model, which is composed of all of the nodes across clusters; nevertheless, it may operate more efficiently. The mathematical model of cluster-based FL model, which is based on the blockchain-based FL model.

Imagine that there are \({C}_{b}\) blockchain-based FL clusters, and that each of these clusters \({C}_{b}\) has a training dataset that consists of \({n}_{b}\) samples, where \(b=\mathrm{1,2},\dots ,M\) are the number of clusters. Following this, we will construct the cluster-based FL model in order to link the M blockchain-based FL clusters. The overall training goal of cluster-based FL is seen from the perspective of the cluster as a whole. Blockchain-based FL is more secure than traditional FL because it uses cryptography to protect the data and the model. This makes it more difficult for attackers to steal or tamper with the data or the model. Blockchain-based FL is more privacy-preserving than traditional FL because it uses a decentralized network to train the model. This means that the data never leaves the clusters, which protects the privacy of the data. Blockchain-based FL is more trustworthy than traditional FL because all transactions are public and verifiable. This helps track training progress and ensures independence. Blockchain-based FL is more scalable than classical FL since it trains models utilizing data from several clusters. This lets models be trained on larger datasets, which may boost efficiency.

Blockchain-based FL implementation is tough. Blockchain-based FL is harder to implement than regular FL since it requires blockchain technology. It might be challenging to install and keep up with blockchain technology due to its complexity. Because of the added cost of implementing blockchain technology, blockchain-based FL may be more expensive than conventional FL. Costs associated with implementing and maintaining a blockchain system might be high. The scalability of blockchain-based FL is an open question, as it has not yet been tested on significant datasets or large numbers of clusters. The method known as gradient descent is also utilized in order to ascertain the value of w that yields the best results. The blockchain-based FL used in each cluster during each stage of the gradient descent process is responsible for determining \(w\).\(w\) is then sent between clusters, and the results are tallied by each cluster separately after they have been transferred.

The aggregated updates in cluster-based FL are represented as

$${w}_{t+1}\leftarrow {w}_{t}-\eta \sum_{i=1}^{N}\frac{{n}_{i}}{M}\sum_{i=1}^{N}\frac{{n}_{i}}{M}\nabla {f}_{i}\left({w}_{t}\right)$$

where the numbers \({n}_{i}\) and \(M\) represent the total number of nodes that are present in all of the clusters combined \(({C}_{i})\) and the number of nodes that are found in each individual cluster, respectively. In addition, the value of \(N\) represents the total number of samples that were applied to each of the different clusters. As a result, we come to the realization that the gradient descent procedure utilized by the blockchain-based FL framework is identical to the one utilized by the cluster-based FL model.

3.2 The proposed model architecture

The cluster-based gradient aggregation between two networks as an overview of cluster-based FL. In order to carry out FL, a permissioned blockchain system is constructed in each cluster, which is formed when Internet of Things (IoT) devices in a cloud network come together to form a node.

  • The gradients that are accumulated in network B are those that have been transferred from network A, where they were first produced. In a way that is more tangible, the on-device training that is undertaken in order to generate a local model update (also referred to as FL training) is carried out by every device and node that is part of network A.

  • The updated gradients of the model are then broadcast throughout the network, where they are finally recorded on the blockchain ledger by means of the intra-chain consensus for FL (sometimes referred to as the FL consensus).

  • During the process of reaching a consensus, the gradients from each of the several devices are added together. In point of fact, each of the aforementioned three processes goes through one cycle of blockchain-based FL in network A.

  • After then, the accumulated updates are sent from network A to network B through a process known as "gradient exchange." After the device at network B has downloaded the updates, it will perform a twofold validation against the downloaded updates.

3.3 Data transaction structures

Because the data structures associated with machine learning are equivalent to those found in the traditional one, our primary emphasis will be placed on the structures that are important to the blockchain system. In cluster-based FL, there are primarily four distinct transaction structures, each of which corresponds to a different consensus aim. These transaction structures are referred to as gradient transactions, confirmation transactions, application transactions, and reward/punishment transactions.

After the conclusion of the on-device, local training, which includes the gradient updates, every device will then provide the gradient transaction. It is crucial to note that the aggregated gradients are stored in a separate transaction from the original gradients that were supplied by the devices. You may find this data in the aggregated gradients exchange. You can tell by looking closely at the red area of the emblem. The confirmation transaction, which can be used for either the acceptance or reception consensus, is recommended by the block packager. Both agreements are achieved via the utilisation of the transaction. This means that a confirmation-type transaction may contain either the gradients or the receipts.

There are two distinct processes that make up the mechanism that is used to arrive to a FL consensus inside a cluster [26]. These two sub-protocols are referred to by their respective names, which are the intra-cluster chain consensus and the inter-cluster chain consensus, respectively.

The Two-Phase Commit (2PC) protocol was developed in response to the Two-Phase Commit (2PC) protocol that is widely used in the database industry [27]. This protocol allows for the secure transfer of data between two clusters. The intra-cluster chain protocol is a cross between the conventional single-chain consensus and the 2PC approach. Both of these methods are used to reach consensus. This is as a result of the speedy operation of participating nodes after they have received the revised model as a result of employing this protocol. This has come about due to the fact that this protocol has been used. The explanation for this is that they have got the most recent version of the model. It illustrates the steps that need to be finished in order to finish the intra-cluster chain method.

In addition, the 2PC procedure can be broken down into two distinct steps, which are respectively known as the "prepare" stage and the "merge/discard" stage. Both of these stages are denoted by their respective names. During the phase that is referred to as "prepare," the single-chain consensus for each cluster is utilized in order to evaluate the appropriateness of the model modifications that have been conveyed from one cluster to another. In order to be more specific, each device will check the adjustments that have been received on the local dataset, and then decide whether or not to delete them, erase them entirely, or combine them with the dataset that was received from the distant cluster. In the event that this does not take place, the modifications that were made locally and the changes that were received will not be integrated. In this respect, the cluster will remove the updates that have been received, and only the changes that have been made locally will be put into the subsequent round of training that will take place.

3.4 Cluster chain protocol

Although it seems that in cluster-based FL framework the intra-chain consensus is functional, this approach faces the significant obstacle of having a poor level of system efficiency. In order to complete one cycle of intra-cluster chain protocol, each cluster must first reach three different local consensuses. One of the three consensus processes is in charge of collecting the updates that are sent by the various nodes that are part of a cluster, while the other two are responsible for the data interchange that occurs across different clusters. Since attaining agreement on the blockchain takes so much time, a cluster-based FL architecture with inter-chain consensus may have a very low degree of system efficiency. This is especially true when there are a large number of nodes to consider. One approach that has been suggested to address this concern is the "inter-cluster chain." It might be a choice among several. In this tactic, representatives are chosen to speak for each group, and a system is set up to both reward and penalise them based on their performance.

Inter-cluster chains will often choose a leader in each cluster to ease the administration and coordination of learning on a global as well as a local scale. This is done in order to meet the needs of the inter-cluster chains. This specific individual serves in the capacity of a liaison, acting to facilitate communication between the various organizations. The term "this is done with the intention of" derives from the fact that the action is being made with the purpose of mitigating the negative impacts of making an excessive number of decisions by unanimous vote. This is where the phrase "this is done with the intention of" comes from. The Inter-cluster chain protocol advises that the representative take out a mortgage on part of their assets and develop a reward and punishment system that is suited to the representative's habits in order to dissuade the representative from engaging in malicious activity. This is done in order to prevent the representative from engaging in malicious behavior. This is done in the hope of reducing the likelihood of the representative engaging in deceptive or harmful behavior. This is done with the hopes of discouraging the representative from behaving in a manner that is not acceptable.

In contrast, a cluster-based FL round in intra-cluster chain does contain both the intra-chain consensus as well as the inter-chain consensus in its protocol. However, a round in cluster chain protocol does not include either. Instead, it is the responsibility of the representative to collect and organize all of the most recent updates that have been sent from the many nodes that comprise this cluster. In addition, it is responsible for deciding whether the changes from the remote cluster should be merged or discarded. It is anticipated that the overall system efficiency of cluster-based FL with Intra-cluster chain would be significantly enhanced as a result of the elimination of wasteful consensus in a round.

The 'commit/rollback' phase is the one that the system moves on to after the 'prepare' phase, which is the phase in which agreement was reached. During this phase, the results of the consensus are relayed to the remote cluster, and modifications are made if necessary. If adjustments are required, this step concludes with those adjustments being made. Operations that were finished during the previous cycle are committed, and a new cycle begins if the results of consensus polls conducted on both the local and remote clusters indicate that it is likely that an acceptance will take place. A new cycle begins if the results of consensus polls indicate that it is likely that an acceptance will take place. In the event that this hypothetical scenario was to play out, the activities that were performed during the cycle before it would be reversed, and each and every one of the processes that were performed during the cycle before it would be rendered null and void. It is necessary to underline that the rollback does not imply a split in the blockchain, as this point cannot be emphasized, and it is important to note that this does not mean that the blockchain has been split. Only the transactions that brought about changes during the cycle before it is removed from the blockchain ledger, but all of the actions that brought about those transactions are still recorded as having taken place. This ensures that the integrity of the blockchain is maintained.

4 Results and discussion

In order to determine how well our framework works, we have implemented correspondingly mechanisms that have been proposed for intra-cluster protocol. The intra-cluster protocol is superior than inter-cluster protocol and the majority of our tests are performed on intra-cluster protocol.

In our studies, each computer serves as a node or device. The nodes are spread over two networks (A and B), each of which considered to have either 10/20 or 30 nodes. The blockchain system that has been implemented is a permissioned blockchain. We use the learning task, which is a need that often arises in the context of cloud IoT network The evaluation of cluster-based FL is carried out by including the performance of the model, the speed of convergence, and the latency of the system.

In this part of the article, we will compare the performance of the model using intra-cluster protocol. When it comes to blockchain-based FL, we create clusters of varying sizes, with nodes 10, 20 and 30. The results of the experiments are shown in Figs. 1, 2, 3 and 4. It includes the accuracy and the loss of the measurements for the model performance (Figs. 1, 2) and convergence speed performance (Figs. 3, 4). The x-axis represents the round number, and the y-axis represents the testing result (either accuracy or loss).

Fig. 1
figure 1

Model performance in terms of accuracy

Fig. 2
figure 2

Model performance in terms of loss

Fig. 3
figure 3

Convergence speed performance in terms of accuracy

Fig. 4
figure 4

Convergence speed performance in terms of loss

When compared to blockchain-based FL with 20 nodes, it is not difficult to determine that the performance of the model may be enhanced by cluster-based FL by a significant margin.

To be more explicit, the accuracy goes upto 72.6%, and goes down to 11%. The loss goes upto 3.6 and goes down to 0.8. The fact that cluster-based FL is able to use the information stored in several racks to develop a more accurate model is the primary contributor to the development of this advancement. In addition, we can see that the performance of the cluster-based FL model and the blockchain-based FL model with 30 nodes are quite similar to one another if we compare the two. In other words, cluster-based FL model is equivalent to blockchain-based FL model of the same size when compared side by side.

We compared the dataset that was used in the cluster-based FL framework to the dataset that was used in a single blockchain-based FL model in order to test the hypothesis that the cluster-based FL framework may be able to accelerate model convergence. This allowed us to determine whether or not the hypothesis was true. Because of this, we were able to demonstrate the capabilities of the FL framework that is built on clusters and either confirm or refute our initial assumptions. The dataset is dispersed in a random fashion across the nodes of each system, including the nodes themselves.

As can be shown in Figs. 1, 2, 3 and 4, during an extensive training period, the cluster and blockchain-based FL is capable of bringing the model to an accuracy and loss that is comparable to one another. However, it takes blockchain-based FL over 200 rounds to attain model convergence, but the time required by cluster-based FL model is around 170 rounds, which is comparable to the time required by blockchain-based FL with 30 nodes. In conclusion, the cluster-based FL has the potential to hasten the model's convergence in comparison to the blockchain-based FL’s limited size. The reason for this is because cluster-based FL combines the work done by numerous networks, which results in an increase in the total amount of processing power available to the model.

The model converges quickly in terms of rounds when using blockchain-based FL with 20 nodes, however each round takes an extremely lengthy time to complete, reducing the system's overall efficiency. In this paper, a comparison of the total system latency of the various models is made. The amount of time that has passed from the beginning of a predetermined number of training cycles is what is meant by the term "system latency." As the learning process continues, Fig. 5 evaluates and contrast the different amounts of latency shown by blockchain-based FL with 10, 20 and 3 nodes. The amount of time that has passed is shown as a function of the rounds in Fig. 5.

Fig. 5
figure 5

Comparison of time in seconds for different number of nodes in blockchain-based FL

The consensus time of cluster-based FL, which is shown in Fig. 6. In contrast, cluster-based FL significantly cuts down on the amount of cross-rack communication, which in turn leads to a reduction in the latency of the system. In addition, when the system latency of cluster-based FL for inter-cluster and intra-cluster protocol is compared, we find that intra-cluster protocol performs much better than inter-cluster protocol. This is because cluster-based FL primarily optimises the amount of time it takes to reach a consensus.

Fig. 6
figure 6

Comparison of time in seconds for different number of nodes in cluster-based FL

5 Conclusion

It is anticipated that the blockchain-based FL model would make enormous new options available for the cloud based IoT networks. However, the currently implemented blockchain-based FL systems are plagued by the issues of inefficient data processing and a lack of data availability.

In this paper, we suggest using cluster-based FL model to link the many blockchain-based FL clusters that have been created by dividing the nodes that are spread out across a vast region into several smaller clusters using blockchain-based FL. In order to improve the quality of the data samples used by each cluster, the aggregated updates are shared among the clusters. The amount of aggregated updates is modest, which results in a reduction in the communication overhead. As a result, the system's efficiency is significantly increased.

When seen from a different angle, the fact that blockchain- and cluster-based FL may enhance training outcomes by sharing model updates is counterbalanced by the possibility that doing so would place enormous demands of computation and communication on the relevant devices. In contrast, the majority of IoT devices often have limited resources and are thus unable to adequately support these demands. As future work, we may consider attempting to merge the technologies of cluster-based FL and edge computing. In future, with the help of blockchain managed federated learning, the models be trained with data acquired from Internet of Things (IoT) devices that are located in various regions in a network and can be updated constantly. Moreover, the data that is collected from Internet of Things devices has its own distinctive collection of hardware and software capabilities, which can be utilized to train models that are managed by blockchain and federated learning in future.

Availability of data and materials

There are no data available.

Change history



Federated learning


Internet of Things


Local Area Network


Wide area network


Internet of vehicles




Vehicular Ad Hoc Networks


Machine learning


Two-Phase Commit


  1. G.J. Joyia, R.M. Liaqat, A. Farooq, S. Rehman, Internet of medical things (IOMT): applications, benefits and future challenges in healthcare domain. J. Commun.Commun. 12(4), 240–247 (2017)

    Google Scholar 

  2. I.V. Pustokhina, D.A. Pustokhin, D. Gupta, A. Khanna, K. Shankar, G.N. Nguyen, An effective training scheme for deep neural network in edge computing enabled internet of medical things (IOMT) systems. IEEE Access 8, 107112–107123 (2020)

    Article  Google Scholar 

  3. F. Alsubaei, A. Abuhussein, S. Shiva, Security and privacy in the internet of medical things: taxonomy and risk assessment, in Proceedings of the 42nd IEEE Conference on Local Computer Networks Workshops (LCN Workshops), pp. 112–120. IEEE (2017)

  4. B. McMahan, E. Moore, D. Ramage, B.A. Arcas, Federated learning of deep networks using model averaging. corrabs/1602.05629 (2016). arXiv preprint arXiv:1602.05629 (2016)

  5. Z. Zheng, S. Xie, H. Dai, X. Chen, H. Wang, An overview of blockchain technology: Architecture, consensus, and future trends, in Proceedings of the 2017 IEEE International Congress on Big Data (BigData), pp. 557–564. IEEE (2017)

  6. M. Seliem, K. Elgazzar, Biomt: Blockchain for the internet of medical things, in Proceedings of the 2019 IEEE International Black Sea Conference on Communications and Networking (BlackSeaCom), pp. 1–4. IEEE (2019)

  7. Y. Zhao, J. Zhao, L. Jiang, R. Tan, D. Niyato, Z. Li, L. Lyu, Y. Liu, Privacy-preserving blockchain-based federated learning for iot devices. IEEE Internet Things J. 8(3), 1817–1829 (2021)

    Article  Google Scholar 

  8. S. Banou, M. Swaminathan, G.R. Muns, D. Duong, F. Kulsoom, P. Savazzi, A. Vizziello, K.R. Chowdhury, Beamforming galvanic coupling signals for iomt implantto- relay communication. IEEE Sens. J. 9(19), 8487–8501 (2018)

    Article  Google Scholar 

  9. Z. Wang, M. Song, Z. Zhang, Y. Song, Q. Wang, H. Qi, Beyond inferring class representatives: User-level privacy leakage from federated learning, in Proceedings of the 2019 IEEE Conference on Computer Communications, pp. 2512–2520. IEEE (2019)

  10. S. Awan, F. Li, B. Luo, M. Liu, Poster: A reliable and accountable privacy-preserving federated learning framework using the blockchain, in Proceedings of the 2019 ACM SIGSAC Conference on Computer and Communications Security, pp. 2561–2563 (2019)

  11. M.H. Ur Rehman, K. Salah, E. Damiani, D. Svetinovic, Towards blockchain-based reputation-aware federated learning, in Proceedings of the 2020 Conference on Computer Communications Workshops (INFOCOM), pp. 183–188. IEEE (2020)

  12. X. Bao, C. Su, Y. Xiong, W. Huang, Y. Hu, Flchain: A blockchain for auditable federated learning with trust and incentive, in Proceedings of the 5th International Conference on Big Data Computing and Communications (BIGCOM), pp. 151–159 (2019)

  13. H. Kim, J. Park, M. Bennis, S.-L. Kim, Blockchained on-device federated learning. IEEE Commun. Lett.Commun. Lett. 24(6), 1279–1283 (2019)

    Article  Google Scholar 

  14. S.R. Pokhrel, J. Choi, Federated learning with blockchain for autonomous vehicles: analysis and design challenges. IEEE Trans. Commun.Commun. 68(8), 4734–4746 (2020)

    Article  Google Scholar 

  15. Y. Lu, X. Huang, Y. Dai, S. Maharjan, Y. Zhang, Blockchain and federated learning for privacy-preserved data sharing in industrial iot. IEEE Trans. Ind. Inf. 16(6), 4177–4186 (2019)

    Article  Google Scholar 

  16. H. Jin, X. Dai, J. Xiao, Towards a novel architecture for enabling interoperability amongst multiple blockchains, in Proceedings of the IEEE 38th International Conference on Distributed Computing Systems (ICDCS), pp. 1203–1211. IEEE (2018)

  17. V. Buterin, Chain interoperability. R3 Research Paper (2016)

  18. S.A.A. Kazmi, M.K. Shahzad, A.Z. Khan, D.R. Shin, Smart distribution networks: A review of modern distribution concepts from a planning perspective. Energies 10(4), 501 (2017)

    Article  Google Scholar 

  19. Y. Huang, J. Tan, Y.-C. Liang, Wireless big data: Transforming heterogeneous networks to smart networks. J. Commun. Inf. Netw. 2(1), 19–32 (2017)

    Article  Google Scholar 

  20. T. Takenaka, Y. Yamamoto, K. Fukuda, A. Kimura, K. Ueda, Enhancing products and services using smart appliance networks. CIRP Ann. 65(1), 397–400 (2016)

    Article  Google Scholar 

  21. S. Chakrabarty, D.W. Engels, A secure IoT architecture for smart cities, in Proceedings of 13th IEEE Annual Consum. Commun. Netw. Conf. (CCNC), pp. 812–813 (2016).

  22. P.K. Sharma, J.H. Park, Blockchain based hybrid network architecture for the smart city. Future Gen. Comput. Syst. 86, 650–655 (2018)

    Article  Google Scholar 

  23. M.C. Feliciano. (2020). Analysis of Blockchain Technologies and Benchmarking of NXT and Ethereum in Emulated Network Environment.

  24. S. Nakamoto, Bitcoin: A peer-to-peer electronic cash system. Technical report, Manubot (2019)

  25. L. Bach, B. Mihaljevic, M. Zagar, Comparative analysis of blockchain consensus algorithms, in Proceedings of the 41st International Convention on Information and Communication Technology, Electronics and Microelectronics (MIPRO), pp. 1545–1550. IEEE (2018)

  26. M. Castro, B. Liskov, Practical Byzantine fault tolerance, in Proceedings of the 3rd Symposium on Operating Systems Design and Implementation (OSDI), pp. 173–186 (1999)

  27. C. Mohan, B. Lindsay, R. Obermarck, Transaction management in the r* distributed database management system. ACM Trans. Database Syst. (TODS) 11(4), 378–396 (1986)

    Article  Google Scholar 

Download references


This study was supported by the National Key Research and Development Program of China (2019YFB2102302).

Author information

Authors and Affiliations



JC conceptualized the study, and participated in writing original draft of the manuscript; JL participated in the formal analysis of the study and participated in writing original draft of the manuscript; MW contributed in data or analysis tools and CZ validated the results.

Corresponding author

Correspondence to Muhua Wei.

Ethics declarations

Competing interests

The authors have nothing to declare.

Additional information

Publisher's Note

Springer Nature remains neutral with regard to jurisdictional claims in published maps and institutional affiliations.

This article has been retracted. Please see the retraction notice for more detail:

Rights and permissions

Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit

About this article

Check for updates. Verify currency and authenticity via CrossMark

Cite this article

Chai, J., Li, J., Wei, M. et al. RETRACTED ARTICLE: Blockchain managed federated learning for a secure IoT framework. J Wireless Com Network 2023, 100 (2023).

Download citation

  • Received:

  • Accepted:

  • Published:

  • DOI: